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

Add type annotations for functions (PEP 484) #183

Open
3 of 10 tasks
mrbermell opened this issue Oct 25, 2021 · 4 comments
Open
3 of 10 tasks

Add type annotations for functions (PEP 484) #183

mrbermell opened this issue Oct 25, 2021 · 4 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@mrbermell
Copy link
Collaborator

mrbermell commented Oct 25, 2021

PEP 484 specifies a syntax for providing type hints for function arguments and return types:

def greeting(name: str) -> str:
    return 'Hello ' + name

This makes the code more readable and gives more information to linters which can point out inconsistencies.

It would be great to have for all python files in the framework, especially the ones used for bot development. This is a great way to get started working with and understanding the framework. Any help is greatly appreciated!

TODO:

  • core/game.py
  • core/model.py
  • core/procedure.py
  • core/forward_model.py
  • core/load.py
  • core/table.py
  • core/util.py
  • ai/env.py
  • ai/pathfinding.py
  • ai/registry.py
@mrbermell mrbermell added the good first issue Good for newcomers label Oct 25, 2021
@phasenoisepon
Copy link

Please assign this issue to me, I am working on basic annotation and should hopefully have a PR up soon for you to review.

@mrbermell
Copy link
Collaborator Author

@phasenoisepon, great that you've taken on this! Do you need any help or do you have any questions? =)

@phasenoisepon
Copy link

Haven't had a lot of time to work on this, feel free to assign it to someone else.

@mrbermell
Copy link
Collaborator Author

Ok, no worries!

@mrbermell mrbermell mentioned this issue Nov 24, 2021
@mrbermell mrbermell added this to the Bot Bowl IV milestone Dec 5, 2021
@njustesen njustesen removed this from the Bot Bowl IV Announcement milestone Jan 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants