loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix invalid swagger syntax of $ref with sibling (#7019)

Ticket #5676 states that the output from `make generate-swagger` is not valid according to the current [OpenAPI specification](https://swagger.io/specification/#path-item-object). In future this [may change](https://swagger.io/specification/#reference-object) but currently this has the effect that the `description` field will be ignored. Removing the description from the type definition of the offending entry will fix the invalid output and have the same end result as before, as the description would have been ignored anyway.

## Checklist
### Tests

No changes to Go (except removal of comment) or Javascript code. Have added the `lint-swagger` task to the CI test run however.

### Documentation

- [ ] I created a pull request [to the documentation](https://codeberg.org/forgejo/docs) to explain to Forgejo users how to use this change.
- [x] I did not document these changes and I do not expect someone else to do it.

### Release notes

- [x] I do not want this change to show in the release notes.
- [ ] I want the title to show in the release notes with a link to this pull request.
- [ ] I want the content of the `release-notes/<pull request number>.md` to be be used for the release notes instead of the title.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/7019
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Co-authored-by: Sven Steinbauer <sven@unlogic.co.uk>
Co-committed-by: Sven Steinbauer <sven@unlogic.co.uk>

authored by

Sven Steinbauer
Sven Steinbauer
and committed by
Earl Warren
f05b9604 3ba7445d

+1 -3
+1 -1
.forgejo/workflows/testing.yml
··· 24 24 - uses: https://data.forgejo.org/actions/checkout@v4 25 25 - uses: ./.forgejo/workflows-composite/setup-env 26 26 - run: su forgejo -c 'make deps-backend deps-tools' 27 - - run: su forgejo -c 'make --always-make -j$(nproc) lint-backend tidy-check swagger-check fmt-check swagger-validate' # ensure the "go-licenses" make target runs 27 + - run: su forgejo -c 'make --always-make -j$(nproc) lint-backend tidy-check swagger-check lint-swagger fmt-check swagger-validate' # ensure the "go-licenses" make target runs 28 28 - uses: ./.forgejo/workflows-composite/build-backend 29 29 frontend-checks: 30 30 if: vars.ROLE == 'forgejo-coding' || vars.ROLE == 'forgejo-testing'
-1
modules/structs/pull_review.go
··· 89 89 NewLineNum int64 `json:"new_position"` 90 90 } 91 91 92 - // CreatePullReviewCommentOptions are options to create a pull review comment 93 92 type CreatePullReviewCommentOptions CreatePullReviewComment 94 93 95 94 // SubmitPullReviewOptions are options to submit a pending pull review
-1
templates/swagger/v1_json.tmpl
··· 22411 22411 "x-go-package": "code.gitea.io/gitea/modules/structs" 22412 22412 }, 22413 22413 "CreatePullReviewCommentOptions": { 22414 - "description": "CreatePullReviewCommentOptions are options to create a pull review comment", 22415 22414 "$ref": "#/definitions/CreatePullReviewComment" 22416 22415 }, 22417 22416 "CreatePullReviewOptions": {