Skip to content

Minor (bug) fixes to discrete_space#2687

Merged
quaquel merged 7 commits intomesa:mainfrom
quaquel:discrete_space
Feb 13, 2025
Merged

Minor (bug) fixes to discrete_space#2687
quaquel merged 7 commits intomesa:mainfrom
quaquel:discrete_space

Conversation

@quaquel
Copy link
Copy Markdown
Member

@quaquel quaquel commented Feb 12, 2025

  1. This adds mesa.discrete_space to __init__. You can now do from mesa import discrete_space. This also fixes the failing benchmarks.
  2. This solves cell.agents is prone to create bugs #2682. Cell.agents now returns a copy of the list of agents in the cell, rather than the actual list. This reduces the potential for nasty side effects. Since Cell already has add_agent and remove_agent, this was a simple fix.

@quaquel quaquel requested review from Corvince and EwoutH February 13, 2025 06:28
@quaquel quaquel added trigger-benchmarks Special label that triggers the benchmarking CI bug Release notes label labels Feb 13, 2025
@quaquel quaquel linked an issue Feb 13, 2025 that may be closed by this pull request
@quaquel quaquel merged commit 22817e7 into mesa:main Feb 13, 2025
9 of 11 checks passed
@quaquel quaquel deleted the discrete_space branch February 15, 2025 11:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Release notes label trigger-benchmarks Special label that triggers the benchmarking CI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cell.agents is prone to create bugs

2 participants