Skip to content

Conversation

@thoscut
Copy link

@thoscut thoscut commented Mar 4, 2025

In case an user is pulling from a LFS repository, the user should be retrieved from the token. This happens already in the current code, but after using an empty user variable for retrieving the permissions for the user on the specific repository.
The incorrect order seems to only impact the logged messages:

rvices/lfs/server.go:547:authenticate() [T] Trying GetUserRepoPermission for user <User nil> in repo <Repository

Otherwise it doesn't seem to impact pulls or pushed.

The pull request fixes this behaviour and had been tested locally already.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Mar 4, 2025
@github-actions github-actions bot added the modifies/go Pull requests that update Go code label Mar 4, 2025
@wxiaoguang
Copy link
Contributor

Thank you for the PR, I haven't looked into the problem and have no idea whether there was any real problem. But the CI reports a lot of failed tests.

@wxiaoguang wxiaoguang marked this pull request as draft March 4, 2025 14:34
@wxiaoguang wxiaoguang added the issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail label Mar 4, 2025
@wxiaoguang
Copy link
Contributor

Do you have more ideas?

@wxiaoguang
Copy link
Contributor

Thank you for the PR, inactive for long time, feel free to reopen if there would be new progress.

@wxiaoguang wxiaoguang closed this Mar 27, 2025
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Jun 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. modifies/go Pull requests that update Go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants