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

Simplify enriched datetime code #761

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

torotil
Copy link
Contributor

@torotil torotil commented Oct 1, 2024

This removes the proxy classes EnrichedDate and EnrichedDateTime as they don’t actually add any functionality that would justify the complexity. I think it’s a good next step, but in general I think this sub-system needs more work.

I took the liberty to freely break the API with this PR because I didn’t even know what to keep compatible with, as the code and documentation seem out-of-sync. If needed I’d happily adjust the code to keep the compatibility in some way or the other.

Open questions for me are:

  • timezone=True support: From what I gathered from the sqlalchemy docs it would need specific implementations per DB-backend. I don’t think the implementation in the arrow module would work across different ones.
  • python_type: I couldn’t find any documentation or usage of this, so I removed it. As far as I could find out it’s only defined for actual types not TypeDecorators.

NB: I don’t think this is ready for merging yet, but I think it’s best to discuss things with actual code in mind.

@torotil torotil force-pushed the refactor-enriched_datetime branch from 750f4cf to 5e345db Compare October 22, 2024 11:51
@torotil torotil force-pushed the refactor-enriched_datetime branch from 5e345db to 6151a5a Compare October 22, 2024 12:05
@torotil torotil mentioned this pull request Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant