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

[Bug] WebUI: Topics get removed from org repo, but not from organization view #24820

Closed
udeved opened this issue May 20, 2023 · 0 comments · Fixed by #24825
Closed

[Bug] WebUI: Topics get removed from org repo, but not from organization view #24820

udeved opened this issue May 20, 2023 · 0 comments · Fixed by #24825
Assignees
Labels
issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented type/bug

Comments

@udeved
Copy link

udeved commented May 20, 2023

Description

There seems to be a bug with repo topics in organizations.

I make api calls to add and remove a topic, in our case the pacman repo target.
This all works fine for the repo, but the organization doesn't notice the changes.
It only does if I manually do a "done" edit of the repo's topics in the UI.

Gitea Version

1.19.3

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

gitea-bug-topic.png

gitea-bug-topic2.png

Git Version

2.40.1

Operating System

artix linux

How are you running Gitea?

Gitea runs as server instance on bare metal server.
We build the gitea package with a package pipeline, essentially arch linux package minus systemd.

Database

MySQL

@yardenshoham yardenshoham added the issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented label May 20, 2023
@yardenshoham yardenshoham self-assigned this May 20, 2023
delvh pushed a commit that referenced this issue May 21, 2023
The topics are saved in the `repo_topic` table.
They are also saved directly in the `repository` table.

Before this PR, only `AddTopic` and `SaveTopics` made sure the `topics`
field in the `repository` table was synced with the `repo_topic` table.

This PR makes sure `GenerateTopics` and `DeleteTopic`
also sync the `topics` in the repository table.

`RemoveTopicsFromRepo` doesn't need to sync the data
as it is only used to delete a repository.

Fixes #24820
GiteaBot pushed a commit to GiteaBot/gitea that referenced this issue May 21, 2023
)

The topics are saved in the `repo_topic` table.
They are also saved directly in the `repository` table.

Before this PR, only `AddTopic` and `SaveTopics` made sure the `topics`
field in the `repository` table was synced with the `repo_topic` table.

This PR makes sure `GenerateTopics` and `DeleteTopic`
also sync the `topics` in the repository table.

`RemoveTopicsFromRepo` doesn't need to sync the data
as it is only used to delete a repository.

Fixes go-gitea#24820
lunny pushed a commit that referenced this issue May 21, 2023
…4829)

Backport #24825 by @yardenshoham

The topics are saved in the repo_topic table with a repoID key. They are
also saved directly in the repository table.

Before this PR, only `AddTopic` and `SaveTopics` made sure the `topics`
field in the repository field was synced with the repo_topic table.

This PR makes sure `GenerateTopics` and `DeleteTopic` also sync the
`topics` in the repository table.

`RemoveTopicsFromRepo` doesn't need to sync the data as it is only used
to delete a repository.

- Fixes #24820
Codeberg-org pushed a commit to Codeberg-org/gitea that referenced this issue Jun 3, 2023
) (go-gitea#24829)

Backport go-gitea#24825 by @yardenshoham

The topics are saved in the repo_topic table with a repoID key. They are
also saved directly in the repository table.

Before this PR, only `AddTopic` and `SaveTopics` made sure the `topics`
field in the repository field was synced with the repo_topic table.

This PR makes sure `GenerateTopics` and `DeleteTopic` also sync the
`topics` in the repository table.

`RemoveTopicsFromRepo` doesn't need to sync the data as it is only used
to delete a repository.

- Fixes go-gitea#24820

(cherry picked from commit 04f9ab1)
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/confirmed Issue has been reviewed and confirmed to be present or accepted to be implemented type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants