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

Update Binder environment to use latest Mesa version (#2652) #2655

Merged
merged 2 commits into from
Feb 4, 2025

Conversation

aarav-shukla07
Copy link
Contributor

Summary

The Binder environment for Mesa tutorials is currently broken because it uses an outdated version of Mesa (3.0.0b1). This causes errors when running the tutorials, preventing users from testing Mesa examples on Binder. The issue impacts new contributors and learners who rely on Binder to explore Mesa without setting up a local environment.

Bug / Issue

  • what is the bug:
    The Binder environment for Mesa tutorials is failing because it uses an outdated version of Mesa (3.0.0b1). This
    causes errors when running the tutorials.
  • why does it happen:
    The environment.yml file in the binder directory specifies an old version of Mesa (3.0.0b1), which is no longer
    compatible with the latest dependencies or tutorial code.
  • Impact of the bug:
    - Users cannot test Mesa tutorials on Binder, which limits accessibility and usability for new contributors and learners.
    - The broken environment prevents users from exploring Mesa’s features and examples without setting up a local development environment.

Implementation

  • Updated the environment.yml file to use the latest version of Mesa.

  • Simplified the dependencies to reduce build time and avoid potential conflicts.

  • Verified that the Binder environment now works by testing the tutorials locally and on Binder.

Testing

Steps via which testing can be done :

  • Go to https://mybinder.org/.

  • Enter the URL of the Mesa repository and click Launch.

  • Once the environment is built, navigate to the examples directory.

  • Open and run the introtutorial.ipynb tutorial.

  • Confirm that the tutorials run without errors and produce the expected output.

channels:
- conda-forge
dependencies:
- python
- python=3.9
Copy link
Member

Choose a reason for hiding this comment

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

Can you change this to just python -- we actually require >=3.11

However if we pin it to a python version, then it is one more thing to update

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @tpike3 ,
Thanks for the feedback! I’ve updated the environment.yml file to remove the pinned Python version and ensure compatibility with Python >=3.11. The environment has been tested locally and on Binder, and the tutorials are working as expected.
Please let me know if there’s anything else I need to address.

Copy link
Member

@tpike3 tpike3 left a comment

Choose a reason for hiding this comment

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

Thanks for catching this @aarav-shukla07 !

I had one quick request

@tpike3 tpike3 added bug Release notes label dependencies Pull requests that update a dependency file labels Jan 31, 2025
@tpike3 tpike3 merged commit 061de7a into projectmesa:main Feb 4, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Release notes label dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants