Skip to content
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

Remove none-check from publication_date #74

Closed
shenanigansd opened this issue Feb 4, 2024 · 0 comments · Fixed by #75
Closed

Remove none-check from publication_date #74

shenanigansd opened this issue Feb 4, 2024 · 0 comments · Fixed by #75
Assignees
Labels
bug Something isn't working

Comments

@shenanigansd
Copy link
Member

publication_date = parsedate_to_datetime(data.get("pubDate")) if data.get("pubDate") is not None else None

is causing mypy to say

src/letsbuilda/pypi/models/models_rss.py:37: error: Argument "publication_date" to "RSSPackageMetadata" has incompatible type "datetime | None"; expected "datetime"  [arg-type]

It looks like this field is always present, so lets just remove the none-check.

@shenanigansd shenanigansd added the bug Something isn't working label Feb 4, 2024
@shenanigansd shenanigansd self-assigned this Feb 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant