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

fix: remove timezone clobbering #19

Merged
merged 1 commit into from
Sep 10, 2024
Merged

fix: remove timezone clobbering #19

merged 1 commit into from
Sep 10, 2024

Conversation

nwoolmer
Copy link
Contributor

@nwoolmer nwoolmer commented Sep 10, 2024

Fixes #12

Test outputs

make test
python3 -m pytest
====================================================================== test session starts =======================================================================
platform darwin -- Python 3.9.6, pytest-7.3.2, pluggy-1.5.0
rootdir: [snipped]
plugins: mock-3.11.1
collected 35 items                                                                                                                                               

tests/test_dialect.py ..........                                                                                                                           [ 28%]
tests/test_examples.py .....                                                                                                                               [ 42%]
tests/test_superset.py .................                                                                                                                   [ 91%]
tests/test_types.py ..                                                                                                                                     [ 97%]
tests/test_username.py .                                                                                                                                   [100%]

======================================================================== warnings summary ========================================================================
[snipped]

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
================================================================ 35 passed, 12 warnings in 5.10s =================================================================
python3 -m black src
All done! ✨ 🍰 ✨
18 files left unchanged.
python3 -m ruff check src/questdb_connect --fix
python3 -m ruff check src/examples --fix
python3 -m ruff check tests --fix
docker run -e QUESTDB_CONNECT_HOST='host.docker.internal' -e SQLALCHEMY_SILENCE_UBER_WARNING=1 questdb/questdb-connect:latest
rows: 1
{
    "col_boolean": "True",
    "col_byte": "8",
    "col_short": "12",
    "col_int": "13",
    "col_long": "14",
    "col_float": "15.234",
    "col_double": "16.88993244",
    "col_symbol": "coconut",
    "col_string": "banana",
    "col_char": "C",
    "col_uuid": "6d5eb038-63d1-4971-8484-30c16e13de5b",
    "col_date": "2023-04-22 00:00:00",
    "col_ts": "2023-04-22 18:10:10.765123",
    "col_geohash": "dfvgsj",
    "col_long256": "0xa3b400fcf6ed707d710d5d4e672305203ed3cc6254d1cefe313e4a465861f42a"
}

@nwoolmer nwoolmer added the bug Something isn't working label Sep 10, 2024
@nwoolmer nwoolmer marked this pull request as ready for review September 10, 2024 13:30
@ideoma ideoma merged commit 2b891c5 into main Sep 10, 2024
3 checks passed
@ideoma ideoma deleted the nw_remove_tz_clobber branch September 10, 2024 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

questdb_connect calls time.tzset(), affects global behavior and inconsistent with SQLAlchemy defaults
2 participants