Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When conflicts have been previously detected ensure that they can be resolved #19247

Merged
merged 4 commits into from
Mar 29, 2022

Conversation

zeripath
Copy link
Contributor

@zeripath zeripath commented Mar 29, 2022

There is yet another problem with conflicted files not being reset when
the test patch resolves them.

This PR adjusts the code for checkConflicts to reset the ConflictedFiles
field immediately at the top. It also adds a reset to conflictedFiles
for the manuallyMerged and a shortcut for the empty status in
protectedfiles.

Regression #17902

Signed-off-by: Andrew Thornton [email protected]

…resolved

There is yet another problem with conflicted files not being reset when
the test patch resolves them.

This PR adjusts the code for checkConflicts to reset the ConflictedFiles
field immediately at the top. It also adds a reset to conflictedFiles
for the manuallyMerged and a shortcut for the empty status in
protectedfiles.

Signed-off-by: Andrew Thornton <[email protected]>
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Mar 29, 2022
Copy link
Member

@delvh delvh left a comment

Choose a reason for hiding this comment

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

I hope using nil instead of []string{} won't lead to NPEs...

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Mar 29, 2022
@6543
Copy link
Member

6543 commented Mar 29, 2022

I hope using nil instead of []string{} won't lead to NPEs...

if we use for ... := range nil go will handle it for us

@6543
Copy link
Member

6543 commented Mar 29, 2022

bot

@6543 6543 merged commit 1eebbf2 into go-gitea:main Mar 29, 2022
@zeripath zeripath deleted the really-reset-the-conflict-status branch March 29, 2022 17:13
@zeripath
Copy link
Contributor Author

Sorry about this. I think this is the third PR relating to similar problems and it's beyond reasonable now.

We need some tests for this code.

@zeripath zeripath added issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. and removed backport/v1.16 issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change labels Mar 29, 2022
@zeripath
Copy link
Contributor Author

This does not need to be backported it is a regression due to #17902

@zeripath zeripath added the issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change label Mar 29, 2022
@zeripath
Copy link
Contributor Author

Therefore marked as skip-changelog.

zjjhot added a commit to zjjhot/gitea that referenced this pull request Mar 30, 2022
* giteaoffical/main: (31 commits)
  Add Package Registry (go-gitea#16510)
  Show messages for users if the ROOT_URL is wrong, show JavaScript errors (go-gitea#18971)
  [skip ci] Updated translations via Crowdin
  Make git.OpenRepository accept Context (go-gitea#19260)
  Use full output of git show-ref --tags to get tags for PushUpdateAddTag (go-gitea#19235)
  When conflicts have been previously detected ensure that they can be resolved (go-gitea#19247)
  More commit info from API (go-gitea#19252)
  Move some issue methods as functions (go-gitea#19255)
  Move project files into models/project sub package (go-gitea#17704)
  Granular webhook events in editHook (go-gitea#19251)
  Provide configuration to allow camo-media proxying (go-gitea#12802)
  Move init repository related functions to modules (go-gitea#19159)
  Move organization related structs into sub package (go-gitea#18518)
  Refactor repo clone button and repo clone links, fix JS error on empty repo page (go-gitea#19208)
  Show last cron messages on monitor page (go-gitea#19223)
  Allow API to create file on empty repo (go-gitea#19224)
  Use goproxy.io instead of goproxy.cn (go-gitea#19242)
  New cron task: delete old system notices (go-gitea#19219)
  Let web and API routes have different auth methods group (go-gitea#19168)
  Only send webhook events to active system webhooks and only deliver to active hooks (go-gitea#19234)
  ...
@go-gitea go-gitea locked and limited conversation to collaborators Apr 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/regression Indicates a previously functioning feature or behavior that has broken or regressed after a change lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants