GithubHelp home page GithubHelp logo

Comments (6)

wang-boyu avatar wang-boyu commented on July 2, 2024

Thanks for sharing the code and screenshot. The error appears to be from type hints. Can I ask which version of Python you were using?

Mesa & Mesa-Geo require Python 3.9 and above. I couldn't reproduce the error with Python 3.10. Perhaps try to recreate a clean virtual environment with Python 3.9 or above, install Mesa-Geo and try again?

from mesa-geo.

EwoutH avatar EwoutH commented on July 2, 2024

This is indeed an error caused by new syntax introduced in Python 3.9. Upgrading should resolve the problem.

@wang-boyu the more interesting problem is how users manage to install Mesa-geo with incompatible Python versions. Have we set our Python requirements correctly in this repo? https://packaging.python.org/en/latest/guides/dropping-older-python-versions/#specify-the-version-ranges-for-supported-python-distributions

from mesa-geo.

wang-boyu avatar wang-boyu commented on July 2, 2024

Python requirement is specified in the setup.cfg file:

python_requires = >=3.9
I suppose it should work as expected...?

Edit: in python 3.8 I could only install mesa-geo 0.8.0. When attempting to install 0.9.0, there is an error message indicating python >= 3.9 is required, which is as expected.

from mesa-geo.

EwoutH avatar EwoutH commented on July 2, 2024

Yes, this is indeed the case and it's configured correctly: https://github.com/EwoutH/mesa/actions/runs/8379466683

@whitbern which version of mesa-geo are you using and which Python version? How did you install mesa-geo?

from mesa-geo.

whitbern avatar whitbern commented on July 2, 2024

Hello--I have Python 3.11.5 I have the latest version of mesa-geo: 0.7.0. I installed mesa-geo using these commands for Windows in the Anaconda Prompt:

conda install fiona pyproj rtree shapely
pip install mesa-geo

from mesa-geo.

EwoutH avatar EwoutH commented on July 2, 2024

Right, I read the error wrongly. Seems like an issue in the GeoSpace or the mesa space itself.

  1. Which mesa version are you using?
  2. Could you print m.space.agents and its type.
  3. Could you update to the latest versions of both mesa and mesa-geo and see if this error still persists?

from mesa-geo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.