Skip to content

Add missing pytz to package dependencies#366

Open
hdh7485 wants to merge 3 commits intopredict-idlab:mainfrom
hdh7485:fix/add-pytz-dependency
Open

Add missing pytz to package dependencies#366
hdh7485 wants to merge 3 commits intopredict-idlab:mainfrom
hdh7485:fix/add-pytz-dependency

Conversation

@hdh7485
Copy link

@hdh7485 hdh7485 commented Feb 13, 2026

Summary

  • Add pytz to [tool.poetry.dependencies] in pyproject.toml
  • pytz is imported in plotly_resampler/aggregation/plotly_aggregator_parser.py (line 8) but was not declared as a dependency

Problem

In clean environments (CI, Docker, fresh virtualenvs), importing plotly_resampler fails with:

ModuleNotFoundError: No module named 'pytz'

This happens because pytz is often installed as a transitive dependency of other packages, masking the missing declaration.

Fix

Added pytz = ">=2020.1" to the package dependencies.

Fixes #365

pytz is imported in plotly_resampler/aggregation/plotly_aggregator_parser.py
but was not declared as a dependency in pyproject.toml, causing
ModuleNotFoundError in clean environments.

Fixes predict-idlab#365
@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.27%. Comparing base (560e6b9) to head (a8df80a).
⚠️ Report is 7 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #366      +/-   ##
==========================================
- Coverage   83.83%   83.27%   -0.56%     
==========================================
  Files          13       13              
  Lines        1206     1232      +26     
==========================================
+ Hits         1011     1026      +15     
- Misses        195      206      +11     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

[BUG] Missing pytz in package dependencies causes ModuleNotFoundError

3 participants