-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Python: Package pytz not included #11974
Comments
Yes that's intended: if (type.id() == LogicalTypeId::TIMESTAMP_TZ) {
// We have to add the timezone info
auto tz_utc = import_cache.pytz.timezone()("UTC");
auto timestamp_utc = tz_utc.attr("localize")(py_timestamp);
auto tz_info = import_cache.pytz.timezone()(client_properties.time_zone);
return timestamp_utc.attr("astimezone")(tz_info);
} We need pytz to be able to convert the value to the right python type |
Sorry, I meant "It's intended not being included in the package?" |
Yes that's intended, we don't include dependencies in the package |
No problem at all, I can totally install pytz. As this is expected, I'm closing this. |
@Tishj what's the reason for not specifying dependencies, if I may ask? Users that don't want dependencies to be installed can already use |
What happens?
Can't use
current_timestamp
with duckdb python package.Not sure if this is intended.
To Reproduce
Solution:
pip install pytz
OS:
Ubuntu 23.10, 64-bit, X11, Linux 6.5.0-28-generic
DuckDB Version:
0.10.2
DuckDB Client:
Python 3.11.6
Full Name:
Thiago Lages de Alencar
Affiliation:
None (looking for job)
What is the latest build you tested with? If possible, we recommend testing with the latest nightly build.
I have not tested with any build
Did you include all relevant data sets for reproducing the issue?
Not applicable - the reproduction does not require a data set
Did you include all code required to reproduce the issue?
Did you include all relevant configuration (e.g., CPU architecture, Python version, Linux distribution) to reproduce the issue?
The text was updated successfully, but these errors were encountered: