Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

[fix] Updating an code host config maintains the correct unrestricted state#58772

Merged
pjlast merged 3 commits intomainfrom
pjlast/58746-code-host-update-fix
Dec 5, 2023
Merged

[fix] Updating an code host config maintains the correct unrestricted state#58772
pjlast merged 3 commits intomainfrom
pjlast/58746-code-host-update-fix

Conversation

@pjlast
Copy link
Contributor

@pjlast pjlast commented Dec 5, 2023

Closes #58772

Fixes an issue where the logic that determines whether or not a code host connection is unrestricted differs between the code host connection creation and update code.

Test plan

Tests updated

@cla-bot cla-bot bot added the cla-signed label Dec 5, 2023
@github-actions github-actions bot added the team/source Tickets under the purview of Source - the one Source to graph it all label Dec 5, 2023
@sourcegraph-bot
Copy link
Contributor

sourcegraph-bot commented Dec 5, 2023

Codenotify: Notifying subscribers in CODENOTIFY files for diff a8854c2...ecf38eb.

Notify File(s)
@eseliger internal/database/external_services.go
internal/database/external_services_test.go

@pjlast pjlast requested a review from a team December 5, 2023 14:00
Copy link
Member

@eseliger eseliger left a comment

Choose a reason for hiding this comment

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

good find! ty for test :)

@pjlast pjlast merged commit 12457a5 into main Dec 5, 2023
@pjlast pjlast deleted the pjlast/58746-code-host-update-fix branch December 5, 2023 14:11
@sourcegraph-release-bot
Copy link
Collaborator

sourcegraph-release-bot commented Dec 5, 2023

The backport to 5.2 failed at https://github.com/sourcegraph/sourcegraph/actions/runs/7101937836:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-5.2 5.2
# Navigate to the new working tree
cd .worktrees/backport-5.2
# Create a new branch
git switch --create backport-58772-to-5.2
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 12457a5bf22f7e4c5035b565597d11e274585e56
# Push it to GitHub
git push --set-upstream origin backport-58772-to-5.2
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-5.2

If you encouter conflict, first resolve the conflict and stage all files, then run the commands below:

git cherry-pick --continue
# Push it to GitHub
git push --set-upstream origin backport-58772-to-5.2
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-5.2
  • Follow above instructions to backport the commit.
  • Create a pull request where the base branch is 5.2 and the compare/head branch is backport-58772-to-5.2., click here to create the pull request.
  • Make sure to tag @sourcegraph/release-guild in the pull request description.
  • Once the backport pull request is created, kindly remove the release-blocker from this pull request.

@sourcegraph-release-bot sourcegraph-release-bot added backports failed-backport-to-5.2 release-blocker Prevents us from releasing: https://about.sourcegraph.com/handbook/engineering/releases labels Dec 5, 2023
@pjlast pjlast removed release-blocker Prevents us from releasing: https://about.sourcegraph.com/handbook/engineering/releases backports failed-backport-to-5.2 labels Dec 5, 2023
pjlast added a commit that referenced this pull request Dec 6, 2023
keegancsmith pushed a commit that referenced this pull request Dec 7, 2023
…estricted… (#58795)

* [fix] Updating an code host config maintains the correct unrestricted state (#58772)

(cherry picked from commit 12457a5)

* Undo changelog change
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

backport 5.2 cla-signed team/source Tickets under the purview of Source - the one Source to graph it all

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants