Call-for-Code-for-Racial-Justice / Call-for-Code-for-Racial-Justice/TakeTwo-WebAPI

Load python modules correctly

Offen
#46 1 Kommentar 0 Reaktionen 1 zugewiesene Person Zugewiesen an @shubham599 Auf GitHub ansehen
bug stale
Vorherrschende Sprache
Python
Sterne
8
Forks
8
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

**Describe the bug**
Finish #45. Please see here on how to load multiple files - https://fastapi.tiangolo.com/it/tutorial/bigger-applications/

Basically, you need empty __init__.py file to tell python that the folder is a module. You can then simply load as import root_folder.sub_folder.sub_folder.filename.

Context: https://github.com/Call-for-Code-for-Racial-Justice/TakeTwo-WebAPI/pull/45/files#r817986839

FYI @demilolu

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.