GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |
GeezerVison is showing github.com — Fix datetime.combine inference when tzinfo is omitted by carljm · Pull Request #16811 · python/typeshed Conversation
Member
Time objects may carry a timezone, and typeshed currently doesn't model the distinction between a timezone-aware vs timezone-naive time. If a date is combined with a timezone-aware time using We choose
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Contributor
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
srittau
approved these changes
Uh oh!
There was an error while loading. Please reload this page.
bschnurr
added a commit
to bschnurr/pyright
that referenced
this pull request
Category A: python/typeshed#11844 (6e76a91ed3fc9a2c41b46ac6c3ae1673d0a3c2a1) loses datetime subclass identity and incorrectly infers an omitted combine timezone as None. python/typeshed#16811 fixes combine, but subclass preservation remains unresolved. Retain the exact pre-PR datetime stub and original OverloadCall1 reveal rather than carrying an incomplete generic migration. Add focused regression coverage for constructors, factories, combine timezone forms, and invalid arguments. Full suite: 3731 tests passed; lint and typecheck passed. Co-authored-by: Copilot <[email protected]>
bschnurr
added a commit
to microsoft/pyright
that referenced
this pull request
* Update typeshed to 0abbaf725bf8439af222272e14326037fa5d4b2b Co-authored-by: Copilot <[email protected]> * Adjust datetime reveal for generic typeshed annotation Typeshed made datetime generic over tzinfo in python/typeshed#11844 (6e76a91ed3fc9a2c41b46ac6c3ae1673d0a3c2a1). The existing unparameterized annotation now displays as datetime[Any]. Co-authored-by: Copilot <[email protected]> * Defer generic datetime stubs to preserve subclass behavior Category A: python/typeshed#11844 (6e76a91ed3fc9a2c41b46ac6c3ae1673d0a3c2a1) loses datetime subclass identity and incorrectly infers an omitted combine timezone as None. python/typeshed#16811 fixes combine, but subclass preservation remains unresolved. Retain the exact pre-PR datetime stub and original OverloadCall1 reveal rather than carrying an incomplete generic migration. Add focused regression coverage for constructors, factories, combine timezone forms, and invalid arguments. Full suite: 3731 tests passed; lint and typecheck passed. Co-authored-by: Copilot <[email protected]> --------- Co-authored-by: Copilot <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ReviewersUh oh!
There was an error while loading. Please reload this page. AssigneesNo one assignedLabels
None yet
ProjectsMilestoneNo milestoneDevelopmentSuccessfully merging this pull request may close these issues. Uh oh!
There was an error while loading. Please reload this page. Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later. | |
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |