lex-microsoft_teams 0.6.42 → 0.6.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b320641fa223ed514787d28161d2072d039da5a34ec81ab9cfe2f4289b5403ba
4
- data.tar.gz: b13504e4b41e1ff97360a7a0cedea33989b9649798009a1f2bda16bcff312962
3
+ metadata.gz: 885ba8902681630c8c5eddf6464e8ec385768e2a7cd1762dee1253a588bc2a94
4
+ data.tar.gz: a5219d5613b3a842d88dfe11c30eb88cd3e63e4bfa249ed361054b8f63322adf
5
5
  SHA512:
6
- metadata.gz: 1064e76e545459d2e14c399b5610ede6e24fbb126a9c917806d992b6aa738e69fa27cc4ee6de50b8aec357f4fb53029c7c7f113e38d7cc720dd1c1a9f8879936
7
- data.tar.gz: dff546a2489dc75715e2355c16237f4e1ad0f0677866c1f464f35791c3747ab70b7e31b692d3602680f57434c7d0529f099191c6b59f079a07353bdc9933299b
6
+ metadata.gz: 3d919100c1defbd37a2d26c603bcdc9bf254a8c7070b862a9b70d204ba68a83d939a9465ed5514f78c3d5a24b7c240bcc7751c5250920ead71e7634e9401660b
7
+ data.tar.gz: 6890d6f1c4d24019efe5e9d36f05d31fe50629f5adb87b44c0bb86b1fc6cc52bb525dcd4128e08a163b021c7930b588fdcaf16de487aaf27c0b0a83c5abd8326
data/CHANGELOG.md CHANGED
@@ -2,6 +2,17 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.6.44] - 2026-04-23
6
+
7
+ ### Fixed
8
+ - `TokenCache#teams_auth_settings` — `settings` (from `Settings::Helper`) looks up `Legion::Settings[:extensions][:microsoft_teams]` which is empty because Teams config lives at `Legion::Settings[:microsoft_teams]`. Added fallback to `Legion::Settings[:microsoft_teams]` when `settings` returns empty, restoring tenant_id/client_id resolution for token refresh. This was the root cause of "Missing tenant_id or client_id for delegated refresh" immediately after successful OAuth login
9
+
10
+ ## [0.6.43] - 2026-04-23
11
+
12
+ ### Fixed
13
+ - `Helpers::Client#graph_connection` — added `TokenCache.instance.cached_delegated_token` fallback when no `token:` kwarg is passed and settings has no static token. Fixes "Access token is empty" errors when runners are invoked via LLM tool dispatch without an explicit token argument
14
+ - `Helpers::Client#bot_connection` — same fix using `TokenCache.instance.cached_app_token`
15
+
5
16
  ## [0.6.42] - 2026-04-23
6
17
 
7
18
  ### Fixed
@@ -12,6 +12,7 @@ module Legion
12
12
 
13
13
  def graph_connection(token: nil, api_url: 'https://graph.microsoft.com/v1.0', **_opts)
14
14
  token ||= settings&.dig(:auth, :delegated, :token)
15
+ token ||= TokenCache.instance.cached_delegated_token if defined?(TokenCache)
15
16
  Faraday.new(url: api_url) do |conn|
16
17
  conn.request :json
17
18
  conn.response :json, content_type: /\bjson$/
@@ -22,6 +23,7 @@ module Legion
22
23
 
23
24
  def bot_connection(token: nil, service_url: 'https://smba.trafficmanager.net/teams/', **_opts)
24
25
  token ||= settings&.dig(:auth, :bot, :token)
26
+ token ||= TokenCache.instance.cached_app_token if defined?(TokenCache)
25
27
  Faraday.new(url: service_url) do |conn|
26
28
  conn.request :json
27
29
  conn.response :json, content_type: /\bjson$/
@@ -394,6 +394,8 @@ module Legion
394
394
 
395
395
  def teams_auth_settings
396
396
  ms = settings
397
+ ms = Legion::Settings[:microsoft_teams] if defined?(Legion::Settings) && (ms.nil? || ms.empty?)
398
+ ms ||= {}
397
399
  auth = ms[:auth].is_a?(Hash) ? ms[:auth].dup : {}
398
400
  auth[:tenant_id] ||= ms[:tenant_id]
399
401
  auth[:client_id] ||= ms[:client_id]
@@ -3,7 +3,7 @@
3
3
  module Legion
4
4
  module Extensions
5
5
  module MicrosoftTeams
6
- VERSION = '0.6.42'
6
+ VERSION = '0.6.44'
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lex-microsoft_teams
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.42
4
+ version: 0.6.44
5
5
  platform: ruby
6
6
  authors:
7
7
  - Esity