Skip to content

Conversation

@pwnage101
Copy link
Member

@pwnage101 pwnage101 commented Dec 22, 2025

Previously, I had assumed all repos had an "origin" remote. This is a fatal assumption because several enterprise repos had been included in FORKED_REPOS on newer devstacks so they were configured without an "origin" remote. This fixes the migration script to handle the fork repo case---instead of re-writing the "origin" remote, re-point the main branch to track the "edx" remote instead of the "openedx" remote.

ENT-11240 (epic: ENT-11239)

Testing

From devstack:

$ make migrate-repo-git-to-edx
./migrate-repo-git-to-edx.sh
Updating enterprise-access ...
Old tracking remote: openedx
New tracking remote: edx

Updating enterprise-subsidy ...
Old tracking remote: openedx
New tracking remote: edx

Updating enterprise-catalog ...
Old tracking remote: openedx
New tracking remote: edx

Updating license-manager ...
Old tracking remote: openedx
New tracking remote: edx

Migration complete.

That resulted in all 4 enterprise IDA checkouts to have their main/master branches re-target the "edx" remote. Re-running the command is idempotent:

$ make migrate-repo-git-to-edx
./migrate-repo-git-to-edx.sh
Updating enterprise-access ...
Skipping enterprise-access: main branch was already configured to track edx remote.
Updating enterprise-subsidy ...
Skipping enterprise-subsidy: main branch was already configured to track edx remote.
Updating enterprise-catalog ...
Skipping enterprise-catalog: master branch was already configured to track edx remote.
Updating license-manager ...
Skipping license-manager: master branch was already configured to track edx remote.
Migration complete.

Copilot AI review requested due to automatic review settings December 22, 2025 20:44
Copy link
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.

Pull request overview

This PR updates the migration script to handle enterprise repositories configured as "forks" that don't have an "origin" remote. Previously, the script assumed all repos had an "origin" remote, which caused failures for fork repos configured with "edx" and "openedx" remotes instead.

  • Adds conditional logic to detect whether a repo uses "origin" or fork-based remote configuration
  • For fork repos, updates the main/master branch tracking remote from "openedx" to "edx"
  • Changes debug settings to enable command tracing

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@pwnage101 pwnage101 force-pushed the pwnage101/fix-migration-script-x2 branch 2 times, most recently from 6c2be9a to 3a4ad97 Compare December 22, 2025 20:53
Copilot AI review requested due to automatic review settings December 22, 2025 20:53
Copy link
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.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@pwnage101 pwnage101 force-pushed the pwnage101/fix-migration-script-x2 branch 2 times, most recently from d17005b to 14aa29b Compare December 22, 2025 21:07
Copilot AI review requested due to automatic review settings December 22, 2025 21:07
Copy link
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.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Previously, I had assumed all repos had an "origin" remote. This is a
fatal assumption because several enterprise repos had been included in
FORKED_REPOS on newer devstacks so they were configured without an
"origin" remote. This fixes the migration script to handle the fork repo
case---instead of re-writing the "origin" remote, re-point the main
branch to track the "edx" remote instead of the "openedx" remote.

ENT-11240 (epic: ENT-11239)
@pwnage101 pwnage101 force-pushed the pwnage101/fix-migration-script-x2 branch from 14aa29b to ecd16b9 Compare December 23, 2025 17:01
@pwnage101 pwnage101 merged commit 84491c9 into master Dec 23, 2025
18 of 19 checks passed
@pwnage101 pwnage101 deleted the pwnage101/fix-migration-script-x2 branch December 23, 2025 17:34
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.

3 participants