Skip to content

Commit e1ea80c

Browse files
Fix Java spotless line-wrapping and Python import order
Apply the exact reflows spotless computed (javadoc wrapping in the e2e test and ProviderTokenArgs, and the provider.getToken call in the dispatcher), and move BearerTokenProvider to its correct alphabetical position in the python package exports after the getBearerToken rename. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 903db34 commit e1ea80c

4 files changed

Lines changed: 8 additions & 7 deletions

File tree

java/src/main/java/com/github/copilot/RpcHandlerDispatcher.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,8 @@ private void handleProviderTokenGetToken(JsonRpcClient rpc, String requestId, Js
328328
return;
329329
}
330330

331-
CompletableFuture<String> tokenFuture = provider.getToken(new ProviderTokenArgs(providerName, sessionId));
331+
CompletableFuture<String> tokenFuture = provider
332+
.getToken(new ProviderTokenArgs(providerName, sessionId));
332333
if (tokenFuture == null) {
333334
rpc.sendErrorResponse(requestIdLong, -32603,
334335
"Bearer-token provider returned null future for provider " + providerName);

java/src/main/java/com/github/copilot/rpc/ProviderTokenArgs.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ public String getProviderName() {
5151
/**
5252
* Gets the id of the session that triggered this token request.
5353
* <p>
54-
* A client-level shared callback registered for many sessions can use this
55-
* to resolve the owning session and scope token acquisition or caching per
54+
* A client-level shared callback registered for many sessions can use this to
55+
* resolve the owning session and scope token acquisition or caching per
5656
* session.
5757
*
5858
* @return the session id

java/src/test/java/com/github/copilot/ByokBearerTokenProviderE2ETest.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@
4343

4444
/**
4545
* End-to-end coverage for the experimental BYOK bearer-token-provider surface
46-
* ({@code BearerTokenProvider} on a provider config). The callback stays entirely on
47-
* the SDK/client side: the SDK keeps it off the wire, sends only the
48-
* {@code hasBearerTokenProvider} flag, and the runtime calls back over the
46+
* ({@code BearerTokenProvider} on a provider config). The callback stays
47+
* entirely on the SDK/client side: the SDK keeps it off the wire, sends only
48+
* the {@code hasBearerTokenProvider} flag, and the runtime calls back over the
4949
* session-scoped {@code providerToken.getToken} RPC before each outbound model
5050
* request.
5151
*/

python/copilot/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
AutoModeSwitchHandler,
8787
AutoModeSwitchRequest,
8888
AutoModeSwitchResponse,
89+
BearerTokenProvider,
8990
CommandContext,
9091
CommandDefinition,
9192
CopilotSession,
@@ -100,7 +101,6 @@
100101
ExitPlanModeHandler,
101102
ExitPlanModeRequest,
102103
ExitPlanModeResult,
103-
BearerTokenProvider,
104104
InfiniteSessionConfig,
105105
InputOptions,
106106
LargeToolOutputConfig,

0 commit comments

Comments
 (0)