-
Notifications
You must be signed in to change notification settings - Fork 261
Fix urls entries in pyproject.toml with variable cases #803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
a8717fc
8730ff8
f515f3f
715db29
01a17af
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -117,6 +117,9 @@ def __init__( | |
|
|
||
| self._yanked = yanked | ||
|
|
||
| # Currently only used for testing purposes | ||
|
||
| self._urls: dict[str, str] = {} | ||
|
|
||
| @property | ||
| def name(self) -> NormalizedName: | ||
| return self._name | ||
|
|
@@ -355,6 +358,9 @@ def all_classifiers(self) -> list[str]: | |
| def urls(self) -> dict[str, str]: | ||
| urls = {} | ||
|
|
||
| if self._urls: | ||
| return self._urls | ||
|
|
||
| if self.homepage: | ||
| urls["Homepage"] = self.homepage | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this not always definitely true? because
nameandurlare a pair frompackage.urls.items().I am not sure what the intent of this code was but this variation seems pointless?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps the original code was just a roundabout way of reading
package.repository_url- and doing that directly is a better fix?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah i think the original code wasn't well written, i'll simplify it 👍🏼