Skip to content

Conversation

@mmcky
Copy link
Contributor

@mmcky mmcky commented Dec 22, 2025

Summary

Upgrades build software and dependencies to align with lecture-python-intro.

Changes

environment.yml

  • Upgrade anaconda to 2025.12
  • Upgrade quantecon-book-theme to 0.15.1
  • Add jupyter-book version constraint (<2.0)

.github/dependabot.yml

  • Add conda ecosystem with weekly schedule
  • Add ignore rule for jupyter-book >= 2.0

.github/workflows/ci.yml

  • Temporarily disable build cache for full execution check

lectures/_config.yml

  • Add nb_merge_streams: true
  • Add path_to_docs: lectures

Reference

- Upgrade anaconda to 2025.12
- Upgrade quantecon-book-theme to 0.15.1
- Add jupyter-book version constraint (<2.0)
- Configure Dependabot for conda ecosystem with jupyter-book restriction
- Add nb_merge_streams and path_to_docs to _config.yml
- Temporarily disable build cache for full execution check
@netlify
Copy link

netlify bot commented Dec 22, 2025

Deploy Preview for lustrous-melomakarona-3ee73e ready!

Name Link
🔨 Latest commit e3cc859
🔍 Latest deploy log https://app.netlify.com/projects/lustrous-melomakarona-3ee73e/deploys/694a6fca36119e00084697c3
😎 Deploy Preview https://deploy-preview-293--lustrous-melomakarona-3ee73e.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

- Add kaleido to environment.yml for reliable image export
- Update all fig.to_image() calls to use engine='kaleido'
- Fixes execution errors in BCG_complete_mkts, BCG_incomplete_mkts, and knowing_forecasts_of_others
- Kaleido is the modern replacement for orca and works reliably in CI environments
- Update objf_prime to return 1D gradient array instead of 2D
- Fixes 'Input array gradx must be 1D' error in amss2 and amss3
- Resolves compatibility issue with scipy.optimize.fmin_slsqp in Python 3.13
@mmcky
Copy link
Contributor Author

mmcky commented Dec 23, 2025

Fixed the amss2 and amss3 build errors.

The issue was a scipy compatibility problem with Python 3.13. The objf_prime function in recursive_allocation.py was returning a 2D gradient array, but scipy's fmin_slsqp now strictly requires a 1D array for scalar objective functions.

Changes:

  • Updated objf_prime to return a 1D gradient vector instead of a 2D Jacobian matrix
  • The gradient computation logic remains identical, just the return format changed
  • This fixes the "Input array gradx must be 1D" error

Commit: eb0d904

Python version should be constrained by the anaconda distribution version
specified in environment.yml, not updated independently by dependabot.
@github-actions
Copy link

github-actions bot commented Dec 23, 2025

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades build software and dependencies to align with lecture-python-intro, updating the build environment to use newer versions of critical packages and adjusting configuration to support these updates.

Key Changes:

  • Upgraded anaconda to 2025.12 and quantecon-book-theme to 0.15.1
  • Added kaleido dependency and updated plotting calls to use the kaleido engine
  • Fixed a bug in recursive_allocation.py where gradient computation was incorrectly implemented as a Jacobian matrix
  • Added conda ecosystem support to dependabot with appropriate version constraints

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
environment.yml Upgrades anaconda and quantecon-book-theme versions, adds kaleido dependency, and constrains jupyter-book to <2.0
.github/dependabot.yml Adds conda ecosystem configuration with weekly updates and ignore rules for jupyter-book and python
.github/workflows/ci.yml Temporarily disables build cache to ensure full execution checks
lectures/_config.yml Adds nb_merge_streams and path_to_docs configuration options
lectures/knowing_forecasts_of_others.md Updates plotly to_image() call to explicitly use kaleido engine
lectures/BCG_incomplete_mkts.md Updates multiple plotly to_image() calls to explicitly use kaleido engine
lectures/BCG_complete_mkts.md Updates plotly to_image() call to explicitly use kaleido engine
lectures/_static/lecture_specific/amss2/recursive_allocation.py Fixes bug where objf_prime incorrectly computed a Jacobian matrix instead of a gradient vector

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions github-actions bot temporarily deployed to pull request December 23, 2025 02:44 Inactive
@github-actions github-actions bot temporarily deployed to pull request December 23, 2025 03:48 Inactive
@mmcky
Copy link
Contributor Author

mmcky commented Dec 23, 2025

@HumphreyYang tried to fix a few issues with the execution due to upgrades in software. If you have any time to take a look at the suggestions and updates to a file used by AMSS and AMSS2, it would be great appreciated.

@mmcky mmcky added the review label Dec 23, 2025
@HumphreyYang
Copy link
Member

HumphreyYang commented Dec 23, 2025

If you have any time to take a look at the suggestions and updates to a file used by AMSS and AMSS2, it would be great appreciated.

Hi @mmcky, this looks great to me!

@mmcky mmcky merged commit 915366c into main Dec 23, 2025
9 checks passed
@mmcky mmcky deleted the upgrade-build-software-2025 branch December 23, 2025 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants