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

fix sugarscape_g1mt running options, requirements and changes to README #109

Merged
merged 4 commits into from
Mar 2, 2024

Conversation

FoFFolo
Copy link
Contributor

@FoFFolo FoFFolo commented Mar 1, 2024

I fixed the running options on the run.py script according to what the README says, adjusting the option to run "mesa runserver" command.
I also fixed the requirements text file as declared in the issue #76.
I modified the README based on the precedent PRs.
I noticed that there are other problems, especially in the app.py when launching solara, but I don't know if my changes are actually meaningful to merge, so I don't want to do a lot of messy changes.

```

Then open your browser to [http://127.0.0.1:8521/](http://127.0.0.1:8521/) and press Reset, then Run.

## Files

* ``sugarscape_g1mt/trader_agents.py``: Defines the Trader agent class.
* ``sugarscape_g1mt/resource_agents.py``: Defines the Sugar and Spice agent classes.
* ``sugarscape_g1mt/resource_agents.py``: Defines the Resource agent class which contains an amount of sugar and spice.
Copy link
Contributor

Choose a reason for hiding this comment

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

Those all should be single backticks, since they are Markdown syntax.

@@ -64,42 +64,43 @@ def assess_results(results, single_agent):

args = sys.argv[1:]


if args[0] == "runserver":
try:
Copy link
Contributor

Choose a reason for hiding this comment

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

Using a check if len(args) == 0 then server.launch() would reduce the number of nesting by 1. According to PEP 20, flat is better than nested.

@rht
Copy link
Contributor

rht commented Mar 2, 2024

LGTM

@rht rht merged commit 9deafba into projectmesa:main Mar 2, 2024
3 checks passed
@rht
Copy link
Contributor

rht commented Mar 2, 2024

Merged, thank you @FoFFolo.

@FoFFolo FoFFolo deleted the sugarscape_g1mt_changes branch March 3, 2024 13:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants