question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

naive and aware constraints on datetime types

See original GitHub issue

Should be fairly easy since speedate gives offset as optional.

@antonagestam said he might be able to work on this, see https://github.com/pydantic/pydantic/discussions/3477#discussioncomment-3771452

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
samuelcolvincommented, Oct 31, 2022

Just to be clear, speedate is part of the pydantic org, and I built it specifically for pydantic-core, so we can change it if required.

1reaction
samuelcolvincommented, Sep 30, 2022

Totally agree, plan is to rewrite the documentation completely - on my long list of things to do.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why naïve times are local times in Python - Paul Ganssle
Since naïve datetimes originally represented "abstract" datetime objects, they have no UTC offset and both hash and equality is based only on ...
Read more >
Allow specifying `datetime` (and `time`) to be aware or naive
The main question is that, what should we treat naive datetime objects as? Do they represent local time or utc time? Since datetime.astimezone...
Read more >
How to pass a timezone format file to a naive datetime object ...
I made it work this way: lastDate = lastDate.replace(tzinfo=FirstDate.tzinfo) lastDate - FirstDate. Replacing only the tzinfo attribute on ...
Read more >
What is the difference between naive and aware? - Educative.io
Types of datetime class. The datetime class is classified into two categories: Naive; Aware. If a datetime object has time zone information, then...
Read more >
Datetime — System Development With Python 2.0 ...
two types of datetimes - naive and aware​​ It's usually safer to be explicit. pytz is based on the Olson database, a reference...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found