Skip to content

Preserve Java commit authorship from standalone repo#1561

Merged
edburns merged 424 commits into
mainfrom
edburns/dd-3011599-preserve-authorship-at-request-of-brunoborges
Jun 3, 2026
Merged

Preserve Java commit authorship from standalone repo#1561
edburns merged 424 commits into
mainfrom
edburns/dd-3011599-preserve-authorship-at-request-of-brunoborges

Conversation

@edburns
Copy link
Copy Markdown
Collaborator

@edburns edburns commented Jun 3, 2026

At the request of @brunoborges, this PR merges the rewritten commit history from the standalone copilot-sdk-java repo into the monorepo to preserve original commit authorship on .java files.

What this does

  • Used git filter-repo on a disposable clone of the standalone repo (copilot-sdk-java) to extract only *.java files, remapped under the java/ subdirectory.
  • Merged the rewritten history into this branch with --allow-unrelated-histories.
  • Because the file content was pre-synced (the "invariant" — standalone .java files identical to monorepo), the merge produces zero file diffs.

What this means for reviewers

  • The PR diff is empty — no source files changed.
  • git log --follow on any java/**/*.java file now traces back to the original authors (Bruno Borges, Ed Burns, Mackinnon Buck, Stephen Toub, copilot-swe-agent, etc.).
  • 143 commits by @brunoborges are now part of the monorepo's history.

Verification

git log --follow --format="%h %an %s" java/src/main/java/com/github/copilot/CopilotClient.java | head -20
git log --all --author="Bruno" --oneline | wc -l  # 143

brunoborges and others added 30 commits March 3, 2026 10:35
…-actions-workflow

Fix CompactionTest timeout caused by prompt mismatch with snapshot
…see refs

Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
…umentation-and-samples

Sync docs and samples with breaking session permission API changes
…eam-repo-again

Upstream sync: session.setModel() and built-in tool override support
…ntation-for-new-methods

Document missing PR #162 CopilotSession APIs in advanced guide
… E2E test updates

Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
…eam-changes-please-work

Upstream sync: port 27 new commits from github/copilot-sdk (2026-03-05)
modified:   .github/release.yml
modified:   .github/templates/index.html
modified:   .github/workflows/deploy-site.yml
modified:   .github/workflows/notes.template
modified:   .github/workflows/publish-maven.yml
modified:   README.md
modified:   jbang-example.java
modified:   pom.xml
modified:   src/main/java/com/github/copilot/sdk/package-info.java
modified:   src/site/markdown/cookbook/error-handling.md
modified:   src/site/markdown/cookbook/managing-local-files.md
modified:   src/site/markdown/cookbook/multiple-sessions.md
modified:   src/site/markdown/cookbook/persisting-sessions.md
modified:   src/site/markdown/cookbook/pr-visualization.md
modified:   src/site/markdown/getting-started.md
modified:   src/site/markdown/index.md
modified:   src/site/site.xml

On branch edburns/dd-2785864-pre-public-non-code-changes
modified:   .github/release.yml
modified:   .github/templates/index.html
modified:   .github/workflows/deploy-site.yml
modified:   .github/workflows/notes.template
modified:   .github/workflows/publish-maven.yml
modified:   README.md
modified:   jbang-example.java
modified:   pom.xml
modified:   src/main/java/com/github/copilot/sdk/package-info.java
modified:   src/site/markdown/cookbook/error-handling.md
modified:   src/site/markdown/cookbook/managing-local-files.md
modified:   src/site/markdown/cookbook/multiple-sessions.md
modified:   src/site/markdown/cookbook/persisting-sessions.md
modified:   src/site/markdown/cookbook/pr-visualization.md
modified:   src/site/markdown/getting-started.md
modified:   src/site/markdown/index.md
modified:   src/site/site.xml

Signed-off-by: Ed Burns <edburns@microsoft.com>
Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
modified:   README.md
modified:   jbang-example.java
modified:   src/site/markdown/cookbook/error-handling.md
modified:   src/site/markdown/cookbook/managing-local-files.md
modified:   src/site/markdown/cookbook/multiple-sessions.md
modified:   src/site/markdown/cookbook/persisting-sessions.md
modified:   src/site/markdown/cookbook/pr-visualization.md

Fixed comment from @brunoborges:

> The pin snapshot version is 0.1.30, therefore all places that reference a version that is supposed to be on Maven Central, must be 0.1.29 (as if it was there already).
…pl is at 0.1.32.

modified:   README.md
modified:   jbang-example.java
modified:   pom.xml
modified:   src/site/markdown/cookbook/error-handling.md
modified:   src/site/markdown/cookbook/managing-local-files.md
modified:   src/site/markdown/cookbook/multiple-sessions.md
modified:   src/site/markdown/cookbook/persisting-sessions.md
modified:   src/site/markdown/cookbook/pr-visualization.md

no changes added to commit (use "git add" and/or "git commit -a")
…eam-changes-c4886a91-010c-45c9-8dcc-6c8f8229fe9a

docs: clarify session close vs delete semantics (upstream sync #599)
…ents, register-before-RPC

Co-authored-by: brunoborges <129743+brunoborges@users.noreply.github.com>
…itch; bump minimum Java to 21

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
…if/else instanceof

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
…eam-commits-again

[upstream-sync] Port 24 upstream commits through 9a0a1a5 (protocol v3, BYOK models, agent pre-selection, OnEvent, broadcast events)
…785864-pre-public-non-code-changes

# Conflicts:
#	README.md
#	jbang-example.java
#	pom.xml
Your branch is up to date with 'origin/edburns/dd-2785864-pre-public-non-code-changes'.

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git restore <file>..." to discard changes in working directory)
	modified:   src/main/java/com/github/copilot/sdk/package-info.java

no changes added to commit (use "git add" and/or "git commit -a")
edburns and others added 24 commits May 26, 2026 12:10
…o 1.1.0

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
Add AgentMode enum and plumb agentMode through message send
…y mode hardening from reference implementation

- Add PostToolUseFailureHookInput, PostToolUseFailureHookOutput, and PostToolUseFailureHandler
- Wire postToolUseFailure hook in SessionHooks and CopilotSession
- Add CopilotClientMode enum (EMPTY vs COPILOT_CLI)
- Add mode field to CopilotClientOptions with COPILOT_CLI default
- Add ToolSet builder class for source-qualified tool filter patterns
- Add BuiltInTools constants (ISOLATED set)
- Add Empty mode validation: requires copilotHome, requires availableTools per session
- Set toolFilterPrecedence=excluded in Empty mode for both create and resume
- Add skipCustomInstructions, customAgentsLocalOnly, coauthorEnabled, manageScheduleEnabled to SessionConfig and ResumeSessionConfig
- Add RUNTIME_INSTRUCTIONS to SystemPromptSections
- Add factory methods and feedback field to PermissionRequestResult
- Add toolFilterPrecedence to CreateSessionRequest and ResumeSessionRequest

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
…esult

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
Auto-committed by codegen-check workflow.
- CapabilitiesChangedUI now has 3 fields (elicitation, mcpApps, canvases);
  update test to pass null for the two new fields
- AssistantMessageEventData now has 16 fields (added parentToolCallId);
  update test to pass null for the new field

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…avadoc

- Update EMPTY mode error message to mention both CopilotHome and CliUrl
- Add availableTools validation in resumeSession() for EMPTY mode
- Add null-checks for hook handler return values to prevent NPE
- Fix misleading Javadoc in SessionConfig/ResumeSessionConfig for
  EMPTY-mode options that are not yet wired to the protocol
- Fix Javadoc formatting in ResumeSessionConfig clear* methods
- Update CopilotClientMode.EMPTY Javadoc to match actual validation

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
Update 8 Javadoc blocks in SessionConfig and ResumeSessionConfig that
incorrectly claimed skipCustomInstructions, customAgentsLocalOnly,
coauthorEnabled, and manageScheduleEnabled were not yet propagated
to the wire protocol. All reference implementations (Node.js, .NET, Go)
propagate these via session.options.update.
Implement updateSessionOptionsForMode() in CopilotClient to send
session.options.update RPC call after session creation and resumption,
matching the behavior of the Node.js, .NET, and Go reference
implementations. In EMPTY mode, safe defaults are applied. In
COPILOT_CLI mode, only explicitly-set fields are forwarded.

Includes 8 unit tests covering both modes and partial overrides.
When the server returns a different sessionId and a subsequent step
(e.g. updateSessionOptionsForMode) fails, the exceptionally blocks
only removed the original sessionId from the sessions map, leaving
the re-keyed entry behind as a stale/closed session.

Fix: remove both the original and the active (possibly re-keyed)
session ID in createSession/resumeSession exceptionally blocks, and
unregister the session from the registry in updateSessionOptionsForMode
before closing it.

Addresses review comments on copilot-sdk PR #1473.
…aths

Co-authored-by: edburns <75821+edburns@users.noreply.github.com>
…k-review

Add CreateSessionReKeyEntryTest for session-map re-key cleanup paths
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 3, 2026 00:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

@edburns edburns requested a review from brunoborges June 3, 2026 00:26
@edburns edburns merged commit afbebc7 into main Jun 3, 2026
15 checks passed
@edburns edburns deleted the edburns/dd-3011599-preserve-authorship-at-request-of-brunoborges branch June 3, 2026 00:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants