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

Improvement: Add typehints to Organization module #246

Open
3 tasks
jalajcodes opened this issue Mar 30, 2021 · 3 comments · May be fixed by #296
Open
3 tasks

Improvement: Add typehints to Organization module #246

jalajcodes opened this issue Mar 30, 2021 · 3 comments · May be fixed by #296
Assignees
Labels
Category: Coding Changes to code base or refactored code that doesn't fix a bug. Type: Enhancement New feature or request.
Projects

Comments

@jalajcodes
Copy link
Member

jalajcodes commented Mar 30, 2021

Description

Type hinting is a formal solution to statically indicate the type of a value within your Python code.

As a developer,
I need to add typehints to my code
to build and maintain a cleaner architecture and catch certain errors along the way.

Mocks

def get_organization(user_id, user_name):
representative_additional_info = UserExtensionModel.find_by_user_id(user_id)
try:
if representative_additional_info.is_organization_rep:

Here's how to add typehints in above function.

def get_organization(user_id: int, user_name: str):
    representative_additional_info = UserExtensionModel.find_by_user_id(user_id)
    ...
    ...

Resources

Typehints cheatsheet - Click Here

Acceptance Criteria

Update [Required]

  • Added correct typehints in the files related to Organization module.

Definition of Done

  • All of the required items are completed.
  • Approval by 1 mentor.

Estimation

1-2 hours

@jalajcodes jalajcodes added Category: Coding Changes to code base or refactored code that doesn't fix a bug. Open Source Hack Status: Available Issue was approved and available to claim or abandoned for over 3 days. labels Mar 30, 2021
@Rahulm2310 Rahulm2310 added the Type: Enhancement New feature or request. label Mar 30, 2021
@mtreacy002 mtreacy002 added this to Icebox in BIT Roadmap Apr 4, 2021
@HarshKumarChoudary
Copy link

I would like to work on this task. Please assign it to me. Thanks.

@jalajcodes
Copy link
Member Author

I would like to work on this task. Please assign it to me. Thanks.

Hi there! You need to complete #244 first.

@snifhex
Copy link

snifhex commented Aug 8, 2021

I would like to work on this task, Please assign it to me.

snifhex added a commit to snifhex/bridge-in-tech-backend that referenced this issue Aug 10, 2021
@snifhex snifhex linked a pull request Aug 10, 2021 that will close this issue
7 tasks
@vj-codes vj-codes removed the Status: Available Issue was approved and available to claim or abandoned for over 3 days. label Aug 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: Coding Changes to code base or refactored code that doesn't fix a bug. Type: Enhancement New feature or request.
Projects
BIT Roadmap
New Issues
Development

Successfully merging a pull request may close this issue.

6 participants