Skip to content
This repository has been archived by the owner on Mar 9, 2024. It is now read-only.

Use Python 3 types #31

Closed
1 of 3 tasks
mre opened this issue Dec 17, 2019 · 4 comments · Fixed by #33
Closed
1 of 3 tasks

Use Python 3 types #31

mre opened this issue Dec 17, 2019 · 4 comments · Fixed by #33

Comments

@mre
Copy link
Owner

mre commented Dec 17, 2019

Feature Request Type

  • Core functionality
  • Alteration (enhancement/optimization) of existing feature(s)
  • New behavior

Description

We should use types wherever we can to make refactoring easier. If someone wants to give it a try, please go ahead. I can provide support if needed. 😊

@orcutt989
Copy link
Contributor

orcutt989 commented Jan 10, 2020

@mre Do you mean Python 3.5 and lower type comments like -

var=1 #int 

or Python 3.6 typing?

var: int=1

Reference
https://mypy.readthedocs.io/en/latest/cheat_sheet_py3.html#variables

Regardless I am down to clown!

@mre
Copy link
Owner Author

mre commented Jan 10, 2020

True, I meant 3.6 types. We should upgrade to that. 😅
Please go ahead if you like to work on that. Thanks!

@orcutt989
Copy link
Contributor

orcutt989 commented Jan 10, 2020

@mre No sweat I just wantd to make sure! 😄 I'm on it. 👍

Did we want function typing too? For example...

# This is how you annotate a function definition
def stringify(num: int) -> str:
    return str(num)

orcutt989 added a commit to orcutt989/timelapse that referenced this issue Jan 10, 2020
all variables and functions are typed in order to help with refactoring
fix mre#31
@orcutt989 orcutt989 mentioned this issue Jan 10, 2020
10 tasks
@mre
Copy link
Owner Author

mre commented Jan 10, 2020

Did we want function typing too?

Yup, that would be great. I saw that you already did that in your PR. 😄

@mre mre closed this as completed in #33 Jan 12, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants