NuGet repository does not accept symbol packages #13531

Closed
opened 2025-11-02 10:45:15 -06:00 by GiteaMirror · 4 comments
Owner

Originally created by @colejohnson66 on GitHub (Sep 25, 2024).

Description

We updated to 1.22.2, and it looks like Gitea is now responding HTTP 400 to symbol package pushes.

Gitea Version

1.22.2

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

This is the output in Jenkins

image

Text Form

13:12:42 [out] $ dotnet.exe nuget push --api-key ******** --source http://10.0.0.31/api/packages/{org}/nuget/index.json *.nupkg --skip-duplicate --symbol-api-key ********
13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/index.json'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source.
13:12:43 Pushing {package}.2024.925.1310.nupkg to 'http://10.0.0.31/api/packages/{org}/nuget'...
13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source.
13:12:43 PUT http://10.0.0.31/api/packages/{org}/nuget/
13:12:43 Created http://10.0.0.31/api/packages/{org}/nuget/ 170ms
13:12:43 Your package was pushed.
13:12:43 Pushing {package}.2024.925.1310.snupkg to 'http://10.0.0.31/api/packages/{org}/nuget/symbolpackage'...
13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source.
13:12:43 PUT http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/
13:12:43 BadRequest http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/ 9ms
13:12:43 error: Response status code does not indicate success: 400 (Bad Request).
13:12:43 .NET Command Completed - Exit Code: 1

Git Version

No response

Operating System

No response

How are you running Gitea?

Windows Service

Database

None

Originally created by @colejohnson66 on GitHub (Sep 25, 2024). ### Description We updated to 1.22.2, and it looks like Gitea is now responding HTTP 400 to symbol package pushes. ### Gitea Version 1.22.2 ### Can you reproduce the bug on the Gitea demo site? Yes ### Log Gist _No response_ ### Screenshots This is the output in Jenkins ![image](https://github.com/user-attachments/assets/57dcb126-c47a-4087-b12e-608882c8c4fb) <details><summary>Text Form</summary> > 13:12:42 [out] $ dotnet.exe nuget push --api-key ******** --source http://10.0.0.31/api/packages/{org}/nuget/index.json *.nupkg --skip-duplicate --symbol-api-key ******** > 13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/index.json'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source. > 13:12:43 Pushing {package}.2024.925.1310.nupkg to 'http://10.0.0.31/api/packages/{org}/nuget'... > 13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source. > 13:12:43 PUT http://10.0.0.31/api/packages/{org}/nuget/ > 13:12:43 Created http://10.0.0.31/api/packages/{org}/nuget/ 170ms > 13:12:43 Your package was pushed. > 13:12:43 Pushing {package}.2024.925.1310.snupkg to 'http://10.0.0.31/api/packages/{org}/nuget/symbolpackage'... > 13:12:43 warn : You are running the 'push' operation with an 'HTTP' source, 'http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/'. Non-HTTPS access will be removed in a future version. Consider migrating to an 'HTTPS' source. > 13:12:43 PUT http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/ > 13:12:43 BadRequest http://10.0.0.31/api/packages/{org}/nuget/symbolpackage/ 9ms > 13:12:43 error: Response status code does not indicate success: 400 (Bad Request). > 13:12:43 .NET Command Completed - Exit Code: 1 </p> </details> ### Git Version _No response_ ### Operating System _No response_ ### How are you running Gitea? Windows Service ### Database None
GiteaMirror added the topic/packagestype/bugissue/needs-feedback labels 2025-11-02 10:45:15 -06:00
Author
Owner

@lunny commented on GitHub (Sep 25, 2024):

Which version did you upgrade from? Can that version work for you?

@lunny commented on GitHub (Sep 25, 2024): Which version did you upgrade from? Can that version work for you?
Author
Owner

@colejohnson66 commented on GitHub (Sep 25, 2024):

I think 1.22.1. But that's not working either once I downgrade. Even 1.22.0 doesn't work. As a sanity check, manually executing dotnet nuget push from the command line also gets HTTP 400 on symbols.

Of note: I did upgrade MySQL from 8.0 to 9.0 at the same time (using the migration assistant in MySQL Workbench). So that might be the culprit.

Update: The health check said I should run gitea doctor convert to fix tables in utf8mb4_0900_ai_ci, but that didn't solve it.

The log, on 1.22.2, gives this:

2024/09/25 15:04:22 ...eb/routing/logger.go:102:func1() [I] router: completed PUT /api/packages/{org}/nuget/ for 10.0.0.31:61706, 201 Created in 53.0ms @ nuget/nuget.go:434(nuget.UploadPackage)
2024/09/25 15:04:22 ...eb/routing/logger.go:102:func1() [I] router: completed PUT /api/packages/{org}/nuget/symbolpackage/ for 10.0.0.31:61706, 400 Bad Request in 7.0ms @ nuget/nuget.go:511(nuget.UploadSymbolPackage)

@colejohnson66 commented on GitHub (Sep 25, 2024): I think 1.22.1. But that's not working either once I downgrade. Even 1.22.0 doesn't work. As a sanity check, manually executing `dotnet nuget push` from the command line also gets HTTP 400 on symbols. Of note: I *did* upgrade MySQL from 8.0 to 9.0 at the same time (using the migration assistant in MySQL Workbench). So that might be the culprit. Update: The health check said I should run `gitea doctor convert` to fix tables in `utf8mb4_0900_ai_ci`, but that didn't solve it. The log, on 1.22.2, gives this: > 2024/09/25 15:04:22 ...eb/routing/logger.go:102:func1() [I] router: completed PUT /api/packages/{org}/nuget/ for 10.0.0.31:61706, 201 Created in 53.0ms @ nuget/nuget.go:434(nuget.UploadPackage) > 2024/09/25 15:04:22 ...eb/routing/logger.go:102:func1() [I] router: completed PUT /api/packages/{org}/nuget/symbolpackage/ for 10.0.0.31:61706, 400 Bad Request in 7.0ms @ nuget/nuget.go:511(nuget.UploadSymbolPackage)
Author
Owner

@KN4CK3R commented on GitHub (Sep 27, 2024):

Could you attach the symbol package here for me to try?

@KN4CK3R commented on GitHub (Sep 27, 2024): Could you attach the symbol package here for me to try?
Author
Owner

@colejohnson66 commented on GitHub (Sep 27, 2024):

I unfortunately can't, but I took a look at Gitea's code, and it looks like it gives 400 if the package is "bad" in some way, such as a missing PDB. I took a look inside the generated snupkg and indeed, there's no PDB inside. This makes sense as we switched to embedded PDBs (<DebugType>Embedded</DebugType>), so I think this was just a PEBKAC on my part.

@colejohnson66 commented on GitHub (Sep 27, 2024): I unfortunately can't, but I took a look at Gitea's code, and it looks like it gives 400 if the package is "bad" in some way, such as a missing PDB. I took a look inside the generated `snupkg` and indeed, there's no PDB inside. This makes sense as we switched to embedded PDBs (`<DebugType>Embedded</DebugType>`), so I think this was just a PEBKAC on my part.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13531