I ran into some problems installing the dataretrieval package alongside HydroGenerate, specifically relating to a common dependency (charset_normalizer)
>> import dataretrieval
>> AttributeError: partially initialized module 'charset_normalizer' has no attribute 'md__mypyc' (most likely due to a circular import)
This occurred specifically when I was testing with a Python 3.8 environment, and stems from the version definition of charset_normalizer in the HydroGenerate dependencies. For Python 3.8, the version definition needs to be changed to charset_normalizer<3,>=2.
However, this did not occur when I was testing with a Python 3.11 environment. Therefore I would not necessarily suggest changing the dependency version definition. Instead, I think it would be best to retire Python 3.8, and to be safe specify that HydroGenerate can only be run from Python 3.10.
So in your pyproject.toml, changing this:
|
requires-python = ">=3.8" |
To this:
requires-python = ">=3.10"
But if you have an alternative approach then I am happy to discuss it.