Skip to content

Remove experimental cell_space module and update references#2969

Merged
EwoutH merged 1 commit intomesa:mainfrom
EwoutH:remove_cell_space
Dec 18, 2025
Merged

Remove experimental cell_space module and update references#2969
EwoutH merged 1 commit intomesa:mainfrom
EwoutH:remove_cell_space

Conversation

@EwoutH
Copy link
Copy Markdown
Member

@EwoutH EwoutH commented Dec 18, 2025

Summary

Remove deprecated mesa.experimental.cell_space namespace and update references to point to the stable mesa.discrete_space module.

Motive

The cell space module was stabilized and moved from mesa.experimental.cell_space to mesa.discrete_space in Mesa 3.2.0 (February 2025, PR #2610). Since then, three stable releases (3.2.0, 3.3.0, and 3.3.1) have been published with the cell space as a stable feature.

The experimental namespace has served its deprecation purpose by providing a migration path for users. With sufficient time having passed and multiple stable releases available, it's appropriate to remove the deprecated namespace to reduce maintenance burden, clean up the codebase, encourage users to adopt the stable API and prevent confusion about which namespace to use.

Implementation

Removed the mesa/experimental/cell_space directory. All functionality continues to exist in its stable location (mesa.discrete_space), we're simply removing the deprecated import path.

Migration Guide

Users still importing from mesa.experimental.cell_space should update their imports:

# Old (no longer works)
from mesa.experimental.cell_space import Grid, Cell, CellAgent

# New (stable since 3.2.0)
from mesa.discrete_space import Grid, Cell, CellAgent

This follows Mesa's experimental feature policy where deprecated experimental features can be fully removed at any point, and in this case after sufficient deprecation time and stable releases. The cell space has been stable since February and for three releases (3.2.0, 3.3.0, 3.3.1), providing ample migration time.

Deleted the mesa.experimental.cell_space module and its __init__.py, as cell space functionality has been moved to mesa.discrete_space. Updated documentation and type hints in related files to reference mesa.discrete_space instead of the removed experimental module.
@EwoutH EwoutH requested a review from quaquel December 18, 2025 19:20
@EwoutH EwoutH added the maintenance Release notes label label Dec 18, 2025
@github-actions

This comment was marked as off-topic.

@EwoutH EwoutH merged commit 9c67a63 into mesa:main Dec 18, 2025
20 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Release notes label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants