-
Notifications
You must be signed in to change notification settings - Fork 4
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
Address Warnings Produced By gempyor
Test Suite
#244
Comments
Looks like the |
It's good that you've already addressed the first warning related to -First step is: Identify the location of the warning, the warning comes from the -Second: Modify the code to use Here's how you might modify the code in import importlib.util
def get_loader(name):
spec = importlib.util.find_spec(name)
if spec is None:
return None
return spec.loader Monkey-patch in your project: If you prefer not to modify the package directly, you can add a monkey patch in your project's initialization code. import importlib.util
import confuse.util
def patched_get_loader(name):
spec = importlib.util.find_spec(name)
if spec is None:
return None
return spec.loader
confuse.util.get_loader = patched_get_loader So, for the |
Hey @KuzeyGorgulu and thank you for the suggestions! I can't endorse the first approach because modifying a virtualenv manually makes it difficult to have reproducible installs and those changes are liable to be clobbered by modifications to the dependencies. I think the second approach isn't necessary for now since it is easy enough to change the version used by virtualenv and it only presents as a warning in 3.12. I'd rather wait to see what the maintainers of I think perhaps this code change would be better off packaged as a PR to the |
I understand your concerns about modifying the virtual environment and the importance of reproducibility. However, I believe my approach is beneficial for a few reasons. Implementing a monkey-patch is a temporary, non-invasive fix that cleans up the deprecation warnings without altering the virtual environment or dependencies, ensuring our development process isn't disrupted. Waiting for the
|
Currently the
gempyor
test suite throws 28 warnings of 2 types, both of which are deprecation related. "Fixing" this issue wouldn't involve a behavior change, but rather just updating the code to avoid the deprecated behavior/functions. First one is frompandas
:And second one is from
confuse
:I've already addressed the first one, going to take a look at the second one, making an issue for posterity.
The text was updated successfully, but these errors were encountered: