DeprecationWarning upon "import holidays" in version 0.17
See original GitHub issueThe implementation of deprecating the Swaziland calendar contains a bug. Just importing the holidays package is enough to fire the DeprecationWarning
.
Steps to reproduce (in bash):
# Setup
python -m venv demo
source demo/bin/activate
pip install --upgrade pip
# Bad version
pip install holidays==0.17
# Expose bug
python -W error::DeprecationWarning -c 'import holidays'
# Workoround
pip uninstall -y holidays
pip install holidays!=0.17
python -W error::DeprecationWarning -c 'import holidays'
# Cleanup
deactivate
rm -rf demo
Expected behavior:
The DeprecationWarning
should only fire when the user constructs an instance of the Swaziland
or a subclass.
Issue Analytics
- State:
- Created 10 months ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
dr-prodigy/python-holidays - GitHub
Country Code Subdivisions Available
Angola AO None
Argentina AR None
Aruba AW None
Read more >holidays Changelog - pyup.io
Swaziland deprecation warning fix 794 (arkid15r) First release (0.17) November 13, 2022 ... Add holidays, extended holidays and tests for Portugal
Read more >What's new in 1.4.0 (January 22, 2022) - Pandas
What's new in 1.4.0 (January 22, 2022)#. These are the changes in pandas 1.4.0. See Release notes for a full changelog including other...
Read more >Add holidays to your calendar in Outlook for Windows
Add holidays for the country that you want to appear on the Outlook calendar. ... Outlook versions but aren't seeing holiday dates through...
Read more >Use the Holidays calendar on iPhone - Apple Support
Select or deselect US Holidays (or the holiday calendar for your country or region). Add a holiday calendar from a different region. Tap...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Unfortunately I could not work on a new release for some days… now it’s online and should be okay. Thx!
The suggested fix was implemented in #794 PR yesterday.
Thank you!