Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace attrdict with metadict #4

Merged
merged 1 commit into from
Oct 11, 2022
Merged

Conversation

abocquet
Copy link

@abocquet abocquet commented May 13, 2022

What?

pyEPR uses a package called AttrDict. AttrDict is not compatible with python 3.9 and above, so one has to use an old version of python to work with pyEPR. This change aims at fixing this by replacing AttrDict with another package that is compatible with later versions of python.

We replace AttrDict (https://pypi.org/project/attrdict/) with MetaDict (https://pypi.org/project/metadict/0.1.2/). Both packages expose dictionary-like objects so the change will be totally transparent to the user.

How?

In the code, we have

from attrdict import AttrDict as Dict

# everywhere else:
from . import Dict

we just had to replace it with

from metadict import MetaDict as Dict

Does it work?

Yes, it works with the demo script from pyEPR, tested on Windows with python 3.7. Feel free to test it on your own machine before approving

@abocquet abocquet marked this pull request as ready for review May 13, 2022 07:06
@abocquet abocquet merged commit 7dbfeee into master Oct 11, 2022
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.

1 participant