{"id":16551521,"url":"https://github.com/kimfucious/juniorpythonapp","last_synced_at":"2025-10-13T05:04:23.973Z","repository":{"id":182729918,"uuid":"668827759","full_name":"kimfucious/JuniorPythonApp","owner":"kimfucious","description":"Teaching the lad some things","archived":false,"fork":false,"pushed_at":"2023-07-22T18:34:55.000Z","size":34,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-04T16:46:53.757Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kimfucious.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-07-20T17:20:07.000Z","updated_at":"2023-07-20T17:23:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"ee147f19-797e-4faa-94f1-f3fa74b869fb","html_url":"https://github.com/kimfucious/JuniorPythonApp","commit_stats":null,"previous_names":["kimfucious/juniorpythonapp"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimfucious%2FJuniorPythonApp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimfucious%2FJuniorPythonApp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimfucious%2FJuniorPythonApp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimfucious%2FJuniorPythonApp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kimfucious","download_url":"https://codeload.github.com/kimfucious/JuniorPythonApp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kimfucious%2FJuniorPythonApp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259080942,"owners_count":22802394,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-11T19:37:39.570Z","updated_at":"2025-10-13T05:04:23.881Z","avatar_url":"https://github.com/kimfucious.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# The [enter adjective here] App\n\nMy kid asked me, \"What's an API?\" the other day, so I'm using this to teach him.\n\nWe're doing this in Python, because that's what he's learning in school.\n\n## What's an API?\n\nAn API is a thing that you can ask something of, and it might answer.\n\n### APIs used in this app\n\n-   [icanhazdadjoke](https://icanhazdadjoke.com/)\n-   [REST Countries](https://restcountries.com/#rest-countries)\n-   [The Yo Momma Joke API](https://yomomma.info/)\n-   A custom API built with Flask (for the Wish List)\n\n### Required External Python Dependencies\n\n-   [art](https://pypi.org/project/art/)\n-   [cowsay](https://pypi.org/project/cowsay/)\n-   [halo](https://pypi.org/project/halo/)\n-   [python-dotenv](https://pypi.org/project/python-dotenv/)\n-   [requests](https://pypi.org/project/requests/)\n-   [termcolor](https://pypi.org/project/termcolor/)\n\nThese can be installed with:\n\n```shell\npip install -r requirements.txt\n```\n\n\u003e **NOTE:** The backend server has its own dependencies. Read the `README.md` file there.\n\n## Running the App\n\nUse this command to run in the terminal:\n\n```shell\npython main.py\n```\n\n### Using Docker\n\nIt doesn't really make sense to Docker here, but it's here for demonstration purposes.\n\nBuild the app with this command:\n\n```shell\ndocker build -t my-python-app .\n```\n\nRun the app interactively with:\n\n```shell\ndocker run -it my-python-app\n```\n\n#### Using Docker Compose\n\nThis is a bit clunky. It's better to run locally or use Docker w/o compose in this scenario, but it's here for demonstrative purposes.\n\nBuild the app with:\n\n```shell\ndocker compose build\n```\n\nRun the app (and backend) with:\n\n```shell\ndocker-compose up -d\n```\n\n\u003e **NOTE:** Be sure to use the dash here. The `-d` starts the services in detached mode, so that the interactive app does not get intermixed with the logging.\n\nRun the following command to get the container id of the `my-python-app`:\n\n```shell\ndocker ps\n```\n\nThe id will look something like this: eeb58d36221d\n\nRun the following command to attach to the container:\n\n```shell\ndocker attach eeb58d36221d # \u003c-- use the appropriate container id here\n```\n\nThe rest is buggy, and I haven't figured it out yet. In short, the app does not show the initial screen. It's blank and when you press any key, it shows an error from the apps menu system. Press another key and you're in.\n\n## Things to learn\n\n-   ASCII art\n-   Colorizing output\n-   Docker\n-   Environment variables\n-   Enums\n-   Error handling\n-   Global variables\n-   Interactive menus\n-   Making HTTP calls to a RESTful API\n-   Serializing JSON\n-   Spinners\n-   Using packages\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkimfucious%2Fjuniorpythonapp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkimfucious%2Fjuniorpythonapp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkimfucious%2Fjuniorpythonapp/lists"}