-
-
Notifications
You must be signed in to change notification settings - Fork 30
Update SciPy lecture: Fix outdated import statement for SciPy 1.15+ compatibility #406
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
Conversation
…ompatibility Co-authored-by: mmcky <[email protected]>
|
This review triggers some good ideas, but copilot didn't interpret the context of the lecture correctly. I have made a manual update to this PR to address the good review suggestion -- and made a note about older versions of SciPy |
@bishmaybarik when you have time would you mind to review this suggestion? |
Hi @mmcky. Sure, I'll review this and get back to you as soon as possible! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @mmcky , I went through the PR and this version looks good. I also checked the deployment and it looks like everything is clear and in place.
thanks @bishmaybarik. |
The SciPy lecture contained an outdated example showing that importing SciPy automatically imports NumPy symbols into the global namespace. This behavior changed in modern SciPy versions (1.15+) as part of namespace cleanup efforts.
What was wrong:
The lecture showed this outdated code example:
What's fixed:
Updated the section to accurately reflect that SciPy 1.15+ no longer auto-imports NumPy symbols, which is better practice as it avoids namespace pollution. The lecture now correctly explains that NumPy should be imported explicitly:
Testing:
scipy.stats
,scipy.optimize
, andscipy.integrate
modulesThis change ensures students learn current best practices while maintaining full compatibility with modern SciPy versions.
Fixes #334.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
fred.stlouisfed.org
/usr/share/miniconda/envs/quantecon/bin/python -Xfrozen_modules=off -m ipykernel_launcher -f /tmp/tmpvqpmxghl.json --HistoryManager.hist_file=:memory:
(dns block)https://api.github.com/repos/scipy/scipy/releases/tags/v1.15.0
curl -s REDACTED
(http block)jax.quantecon.org
/usr/share/miniconda/envs/quantecon/bin/python /usr/share/miniconda/envs/quantecon/bin/jb build lectures --path-output ./ -n -W --keep-going
(dns block)/usr/share/miniconda/envs/quantecon/bin/python /usr/share/miniconda/envs/quantecon/bin/jb build lectures/scipy.md --path-output ./ -n -W --keep-going
(dns block)If you need me to access, download, or install something from one of these locations, you can either:
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.