pypi PEP 0503 not respected - failling to install package with uv (OD-2073)
tpiron opened 1 year ago

Hello,

It seems that pypi on onedev does not implement the pep 0503 specification correctly: https://peps.python.org/pep-0503/#specification.

The URL SHOULD include a hash in the form of a URL fragment with the following syntax: #<hashname>=<hashvalue>, where <hashname> is the lowercase name of the hash function (such as sha256) and <hashvalue> is the hex encoded digest.

On onedev pypi the url fragment is #<hashname>-<hashvalue>

pip installation is working anyway, but some other tools might fail. For example uv returns an error: Unexpected fragment (expected #sha256=... or similar) on URL.

I think this could be fixed easily here, if you confirm it's just that I could open an PR: https://code.onedev.io/onedev/server/~files/2339161e07927ae864af2c0641f9058caf78983d/server-plugin/server-plugin-pack-pypi/src/main/java/io/onedev/server/plugin/pack/pypi/package-versions.tpl?position=source-17.106-17.107-1

  • OneDev changed state to 'Closed' 1 year ago
    Previous Value Current Value
    Open
    Closed
  • OneDev commented 1 year ago

    State changed as code fixing the issue is committed (4ae762d6)

  • OneDev changed state to 'Released' 1 year ago
    Previous Value Current Value
    Closed
    Released
  • OneDev commented 1 year ago

    State changed as build OD-5496 is successful

  • Robin Shen commented 1 year ago

    @thpiron thanks for reporting. This issue has now been fixed in build OD-5496

issue 1/1
Type
Bug
Priority
Normal
Assignee
Affected Versions
11.1.1
Labels
No labels
Issue Votes (0)
Watchers (2)
Reference
OD-2073
Please wait...
Connection lost or session expired, reload to recover
Page is in error, reload to recover