{"id":23376128,"url":"https://github.com/xevion/trivia","last_synced_at":"2026-04-18T13:31:26.483Z","repository":{"id":118246100,"uuid":"273563548","full_name":"Xevion/trivia","owner":"Xevion","description":"A simple locally hosted Flask webapp supporting Trivia competitions.","archived":false,"fork":false,"pushed_at":"2023-05-13T01:38:31.000Z","size":155,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-14T02:52:33.276Z","etag":null,"topics":["cli","competition-manager","efta","flask","trivia"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Xevion.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2020-06-19T18:41:13.000Z","updated_at":"2023-05-13T14:47:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"70a6ddcc-b0e1-44be-9917-6ea7c6a132c9","html_url":"https://github.com/Xevion/trivia","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Xevion%2Ftrivia","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Xevion%2Ftrivia/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Xevion%2Ftrivia/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Xevion%2Ftrivia/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Xevion","download_url":"https://codeload.github.com/Xevion/trivia/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247773744,"owners_count":20993633,"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":["cli","competition-manager","efta","flask","trivia"],"created_at":"2024-12-21T17:33:47.859Z","updated_at":"2026-04-18T13:31:21.442Z","avatar_url":"https://github.com/Xevion.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# trivia\n\n\u003cdiv align=\"center\"\u003e\n    \u003cimg src=\"./.media/cli.png\" alt=\"Screenshot of CLI Leaderboard\" /\u003e\n\u003c/div\u003e\n\n\nA simple locally hosted Flask webapp supporting Trivia competitions.\n\n## Setup\n\nSetup is designed to be as simple as possible with no configuration required. This webapp should only be locally accessible\non at `localhost:5000` unless\n\n```\ngit clone https://github.com/Xevion/trivia.git\ncd trivia\npip install -r requirements.txt\nflask run\n```\n\nEdit .flaskenv to change the configuration preset.\n\nThe CLI clientside implementation can be ran with\n\n```\npython cli.py\n```\n\nand exited with `q`.\n\n## Application Design\n\nThe webapp has two sides: Client and Server.\n\n### Server\n\nThe server provides client code as well as a simple backend API for refreshing the page continuously.\n\nData fed into the tables is taken from a locally updated file which is continuously watched for updates.\n\nOnce an update is seen on the file, said file is read, and if readable, valid JSON is detected, the backend will begin\nproviding the data to clients as they request it.\n\nEach request is bundled with the last time a request was sent. If no update or change has been seen in the mean time,\nthe response is empty and nothing occurs (`304 Not Modified`).\n\nIf a change in the scores is seen, the response includes a leaderboard.\n\n\n### Client\n\nThe frontend client is a fullscreen table displaying a simple leaderboard.\n\nThe leaderboard should scroll up and down in order to display as many teams as needed. Speed should be adjusted\nso that text is easily readable even while moving.\n\nA second scrolling option should be available that is not animated and simply moves the top row in the leaderboard to\nthe bottom of the leaderboard. One row should be made to represent the divider between the top and bottom of the\nleaderboard.\n\n| Rank | Team Name  | Total Score | 1 | 2 | 3 | 4 |\n|------|------------|-------------|---|---|---|---|\n| 1    | Tigers     | 14          | 4 | 2 | 5 | 3 |\n| 2    | Orangutans | 9           | 3 | 2 | 0 | 4 |\n| 2    | Wolves     | 9           | 0 | 2 | 5 | 2 |\n| 4    | Owls       | 7           | 1 | 2 | 0 | 4 |\n| 5    | Rats       | 3           | 0 | 2 | 0 | 1 |\n\n- Ranks will be calculated client side.\n    - This includes ties for any given rank. Take note that despite there being no Rank 3 in the table, Rank 4 and 5 are\n    taken just after 2. Ties should occupy ranks as if no tie system exists at all, although display ties just the same.\n- A simple nth place system.\n    - First, Second and Third place will be marked with Gold, Silver and Bronze colors. Still considering methods of \n    marking.\n        - Simple Image\n        - Color Text\n        - Color Background\n\n## Ideas\n\n- Method of reading and converting Excel Leaderboards to the proper format.\n    - Should be built *failsafe*, given that the file is unreadable or somehow corrupted.\n- Build application to support any platform\n    - The API should be able to support any kind of platform, from a Windows Application, to an Android App, to a CLI\n    implementation.\n- A fun CLI implementation of the client.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxevion%2Ftrivia","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxevion%2Ftrivia","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxevion%2Ftrivia/lists"}