Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

GiteaBot
Copy link
Collaborator

@GiteaBot GiteaBot commented Sep 7, 2025

Backport #35410 by @ahanoff

Fixes #35159

Swift Package Manager expects an 'author.name' field in package metadata, but Gitea was only providing schema.org format fields (givenName, middleName, familyName). This caused SPM to fail with keyNotFound error when fetching package metadata.

Changes:

  • Add 'name' field to Person struct (inherited from https://schema.org/Thing)
  • Populate 'name' field in API response using existing String() method
  • Maintains backward compatibility with existing schema.org fields
  • Provides both formats for maximum compatibility

The fix ensures Swift Package Manager can successfully resolve packages while preserving full schema.org compliance.

…-gitea#35410)

Fixes go-gitea#35159

Swift Package Manager expects an 'author.name' field in package
metadata, but Gitea was only providing schema.org format fields
(givenName, middleName, familyName). This caused SPM to fail with
keyNotFound error when fetching package metadata.

Changes:
- Add 'name' field to Person struct (inherited from
https://schema.org/Thing)
- Populate 'name' field in API response using existing String() method
- Maintains backward compatibility with existing schema.org fields
- Provides both formats for maximum compatibility

The fix ensures Swift Package Manager can successfully resolve packages
while preserving full schema.org compliance.
@GiteaBot GiteaBot added modifies/api This PR adds API routes or modifies them modifies/go Pull requests that update Go code type/bug labels Sep 7, 2025
@GiteaBot GiteaBot requested review from lunny and wxiaoguang September 7, 2025 18:24
@GiteaBot GiteaBot added this to the 1.24.6 milestone Sep 7, 2025
@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Sep 7, 2025
@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 Sep 7, 2025
@wxiaoguang wxiaoguang enabled auto-merge (squash) September 7, 2025 19:37
@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 Sep 7, 2025
@wxiaoguang wxiaoguang merged commit 89c99a4 into go-gitea:release/v1.24 Sep 7, 2025
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. modifies/api This PR adds API routes or modifies them modifies/go Pull requests that update Go code type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants