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

GetFeeds must always discard actions with dangling repo_id (#19598) #19629

Merged
merged 2 commits into from
May 8, 2022

Conversation

singuliere
Copy link
Contributor

@singuliere singuliere commented May 6, 2022

Backport of #19598

Co-authored-by: Loïc Dachary <loic@dachary.org>
(cherry picked from commit b536b65189319544939da9b6537919a4fc838d71)

Conflicts:
        models/action_test.go
	  The GetFeeds function does not have a Context argument in 1.16.
	models/action.go
	  The SQL statement is essentially the same in 1.16 but
	  structured differently. The Join() was copied and the
   	  created_unix field prefixed with `action`.
	models/action_list.go
	  in 1.16 the loadRepoOwner method did not exist and
	  it was done in the RetrieveFeeds method of web/feed/profile.go.
          The safeguard to skip when act.Repo == nil was moved there.

Fix #19631

@singuliere singuliere added this to the 1.16.8 milestone May 6, 2022
…19598)

Co-authored-by: Loïc Dachary <loic@dachary.org>
(cherry picked from commit b536b65)

Conflicts:
        models/action_test.go
	  The GetFeeds function does not have a Context argument in 1.16.
	models/action.go
	  The SQL statement is essentially the same in 1.16 but
	  structured differently. The Join() was copied and the
   	  created_unix field prefixed with `action`.
	models/action_list.go
	  in 1.16 the loadRepoOwner method did not exist and
	  it was done in the RetrieveFeeds method of web/feed/profile.go.
          The safeguard to skip when act.Repo == nil was moved there.
@singuliere singuliere changed the title GetFeeds must always discard actions with dangling repo_id (#19598) Draft: GetFeeds must always discard actions with dangling repo_id (#19598) May 6, 2022
@singuliere singuliere changed the title Draft: GetFeeds must always discard actions with dangling repo_id (#19598) GetFeeds must always discard actions with dangling repo_id (#19598) May 6, 2022
@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label May 6, 2022
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels May 6, 2022
@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 May 7, 2022
@6543
Copy link
Member

6543 commented May 7, 2022

@singuliere please update branch

@singuliere
Copy link
Contributor Author

make l-g-t-m work

@6543 6543 merged commit 0a2d618 into go-gitea:release/v1.16 May 8, 2022
@go-gitea go-gitea locked and limited conversation to collaborators May 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NPE in routers/web/feed/profile.go:37 on 1.16.7 following failed migration
4 participants