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

Python QuantLib==1.3.4 issues DeprecationWarning on import #647

Open
cdcadman opened this issue May 13, 2024 · 6 comments
Open

Python QuantLib==1.3.4 issues DeprecationWarning on import #647

cdcadman opened this issue May 13, 2024 · 6 comments

Comments

@cdcadman
Copy link

Here is a demonstration in the interactive shell, running python 3.12 with QuantLib version 1.34. When I use QuantLib version 1.33, these warnings are not issued:

C:\>python -Walways
Python 3.12.0 (tags/v3.12.0:0fb18b0, Oct  2 2023, 13:03:39) [MSC v.1935 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import QuantLib
<frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyPacked has no __module__ attribute
<frozen importlib._bootstrap>:488: DeprecationWarning: builtin type SwigPyObject has no __module__ attribute
<frozen importlib._bootstrap>:488: DeprecationWarning: builtin type swigvarlink has no __module__ attribute
>>>
Copy link

boring-cyborg bot commented May 13, 2024

Thanks for posting! It might take a while before we look at your issue, so don't worry if there seems to be no feedback. We'll get to it.

@lballabio
Copy link
Owner

Thanks! This needs to be fixed in SWIG. It seems to be a known issue: swig/swig#2881.

This only happens with the -Walways, right?

@cdcadman
Copy link
Author

Yes, DeprecationWarning is ignored by python's default warning filter, so I used the -Walways to make it print out. I first noticed the warnings in pytest logs for some code that uses QuantLib.

Copy link
Contributor

This issue was automatically marked as stale because it has been open 60 days with no activity. Remove stale label or comment, or this will be closed in two weeks.

@github-actions github-actions bot added the stale label Jul 15, 2024
Copy link
Contributor

This issue was automatically closed because it has been stalled for two weeks with no further activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jul 30, 2024
@lballabio lballabio reopened this Aug 28, 2024
@lballabio lballabio removed the stale label Aug 28, 2024
Copy link
Contributor

This issue was automatically marked as stale because it has been open 60 days with no activity. Remove stale label or comment, or this will be closed in two weeks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants