anitab-org / bridge-in-tech-backend

BridgeInTech (BIT) is an application that allows organizations, mentors and mentees to actively collaborate through mentoring programs. This is the backend client of BridgeInTech.
https://bridgeintech-bit-heroku-psql.herokuapp.com/
GNU General Public License v3.0
24 stars 80 forks source link

Improvement: Add typehints to Organization module #246

Open jalajcodes opened 3 years ago

jalajcodes commented 3 years ago

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

https://github.com/anitab-org/bridge-in-tech-backend/blob/68d8ff9a8640cef1d3e53b2b0dd9b80e3d750fd7/app/api/dao/organization.py#L179-L182 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]

Definition of Done

Estimation

1-2 hours

HarshKumarChoudary commented 3 years ago

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

jalajcodes commented 3 years ago

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

Hi there! You need to complete #244 first.

snifhex commented 2 years ago

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