dark_qss = qdarkstyle.load_stylesheet_from_environment()
File "/software/mambaforge/envs/tmpspy/lib/python3.7/site-packages/qdarkstyle/__init__.py", line 437, in load_stylesheet_from_environment
warnings.warning(DEPRECATION_MSG, DeprecationWarning)
AttributeError: module 'warnings' has no attribute 'warning'
The bug can be fixed by reverting that commit. (There may be some other location in the code where logging.warn() is being used instead of logging.warning(), but it should definitely be warnings.warn(), not warnings.warning()!)
Describe Your Environment
Please, report the output of the command (from v2.6+) or fill the information below:
Complicated; I encountered this while trying to debug why the Spyder Notebook plugin didn't work, so some complicated series of mamba install commands using deprecated versions of various packages uncovered this bug :)
It appears this commit: https://github.com/ColinDuquesnoy/QDarkStyleSheet/commit/73531859fef3931428b9c74ed7ac2ccf596d19df
inadvertently introduced a bug. The issue (https://github.com/ColinDuquesnoy/QDarkStyleSheet/issues/309) referred to the logging module, not the warnings module.
warnings.warning()
does not exist:The bug can be fixed by reverting that commit. (There may be some other location in the code where
logging.warn()
is being used instead oflogging.warning()
, but it should definitely bewarnings.warn()
, notwarnings.warning()
!)Describe Your Environment
Please, report the output of the command (from v2.6+) or fill the information below:
$ qdarkstyle --all
Language
Python
Steps to reproduce
Complicated; I encountered this while trying to debug why the Spyder Notebook plugin didn't work, so some complicated series of
mamba install
commands using deprecated versions of various packages uncovered this bug :)