Skip to content

[JOSS-REVIEW] Conflicting dependency for HydroGenerate and dataretrieval in Python 3.8 environments #26

@PennyHow

Description

@PennyHow

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions