Composer package registry: packages not deletable #9532

Closed
opened 2025-11-02 08:42:02 -06:00 by GiteaMirror · 6 comments
Owner

Originally created by @ToSchQLB on GitHub (Sep 7, 2022).

Description

I created a composer package: https://try.gitea.io/Toni.Schreiber/-/packages/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2

But I can't delete it via API

curl -k --user toni.schreiber:TOKEN-X DELETE \
     https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb/yii2-filter-helper/0.1.7.2

But the result is 404 - page not found.

Gitea Version

1.17.0

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

https://try.gitea.io/ and own docker-installation does not work

Database

No response

Originally created by @ToSchQLB on GitHub (Sep 7, 2022). ### Description I created a composer package: [https://try.gitea.io/Toni.Schreiber/-/packages/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2](https://try.gitea.io/Toni.Schreiber/-/packages/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2) But I can't delete it via API ```shell curl -k --user toni.schreiber:TOKEN-X DELETE \ https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb/yii2-filter-helper/0.1.7.2 ``` But the result is 404 - page not found. ### Gitea Version 1.17.0 ### Can you reproduce the bug on the Gitea demo site? Yes ### Log Gist _No response_ ### Screenshots _No response_ ### Git Version _No response_ ### Operating System _No response_ ### How are you running Gitea? https://try.gitea.io/ and own docker-installation does not work ### Database _No response_
GiteaMirror added the topic/packagestype/question labels 2025-11-02 08:42:02 -06:00
Author
Owner

@wxiaoguang commented on GitHub (Sep 7, 2022):

If you are deploying your own Gitea, check your nginx config (especially the ending slash for proxy_pass)

See this one:


If you are playing with try.gitea.io, make sure the package name is escaped correctly toschqlb%2Fyii2-filter-helper , no slash.

@wxiaoguang commented on GitHub (Sep 7, 2022): If you are deploying your own Gitea, check your nginx config (especially the ending slash for proxy_pass) See this one: * https://github.com/go-gitea/gitea/issues/20890#issuecomment-1222291868 ---- If you are playing with try.gitea.io, make sure the package name is escaped correctly `toschqlb%2Fyii2-filter-helper` , no slash.
Author
Owner

@ToSchQLB commented on GitHub (Sep 7, 2022):

Thank you for this tip but even, if I try it this way

curl -k --user toni.schreiber:TOKEN -X DELETE \
     https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2

I got Error 404

@ToSchQLB commented on GitHub (Sep 7, 2022): Thank you for this tip but even, if I try it this way ```shell curl -k --user toni.schreiber:TOKEN -X DELETE \ https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2 ``` I got Error 404
Author
Owner

@wxiaoguang commented on GitHub (Sep 7, 2022):

https://try.gitea.io/api/swagger#/package/deletePackage

image

@wxiaoguang commented on GitHub (Sep 7, 2022): https://try.gitea.io/api/swagger#/package/deletePackage ![image](https://user-images.githubusercontent.com/2114189/188882143-26eb826f-4e39-4683-b2a6-ab79d8ee9b6c.png)
Author
Owner

@ToSchQLB commented on GitHub (Sep 7, 2022):

This works, but here is the problem

I was able to create the package with this URL:
https://try.gitea.io/api/packages/toni.schreiber/composer

But I can't delete this one:
https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2

I have to use this one with api/v1/packages:
https://try.gitea.io/api/v1/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2

@ToSchQLB commented on GitHub (Sep 7, 2022): This works, but here is the problem I was able to create the package with this URL: https://try.gitea.io/api/packages/toni.schreiber/composer But I can't delete this one: https://try.gitea.io/api/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2 I have to use this one with api/**v1**/packages: https://try.gitea.io/api/v1/packages/toni.schreiber/composer/toschqlb%2Fyii2-filter-helper/0.1.7.2
Author
Owner

@KN4CK3R commented on GitHub (Sep 8, 2022):

The composer api simply does not offer an endpoint to delete a package. The /api/v1/ endpoint is the Gitea api.

@KN4CK3R commented on GitHub (Sep 8, 2022): The composer api simply does not offer an endpoint to delete a package. The `/api/v1/` endpoint is the Gitea api.
Author
Owner

@KN4CK3R commented on GitHub (Oct 10, 2022):

Can this be closed?

@KN4CK3R commented on GitHub (Oct 10, 2022): Can this be closed?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#9532