Skip to content

Commit

Permalink
fix: remove index_url key
Browse files Browse the repository at this point in the history
Signed-off-by: Frost Ming <[email protected]>
  • Loading branch information
frostming committed Jul 30, 2024
1 parent 8058807 commit a749f88
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/pdm/models/candidates.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import dataclasses
import hashlib
import os
import posixpath
import re
import warnings
from functools import cached_property
Expand Down Expand Up @@ -405,11 +404,8 @@ def provenance_url(self) -> dict[str, Any] | None:
comes_from = self.link.comes_from # e.g. https://pypi.org/simple/requests/
if comes_from is None: # can't determine the index_url
return None
# FIXME: what about find-links source?
index_url = posixpath.dirname(comes_from.rstrip("/")) + "/"
return {
"url": self.link.url_without_fragment,
"index_url": index_url,
"archive_info": {
"hashes": {
name: hashes[0] for name, hashes in (self.link.hash_option or {}).items() if name in ALLOWED_HASHES
Expand Down

0 comments on commit a749f88

Please sign in to comment.