Skip to content

Unifiy datetime import #4577

Closed
@Bibo-Joshi

Description

@Bibo-Joshi

The imports of the datetime module are all over the place. We currently have at least the following styles in our lib:

  • import datetime
  • import datetime as dtm
  • from datetime import datetime, timedelta

Let's unify that to import datetime as dtm. I prefer this option since

  1. Since there is datetime.datetime, a standalone datetime can be confusing. Using the toplevel module is preferable IMO.
  2. dtm is shorter that datetime, plus it make dtm.datetime unambiguous`

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions