{"id":39665346,"url":"https://github.com/tmlmt/milk-tracker","last_synced_at":"2026-01-18T09:30:01.871Z","repository":{"id":243846043,"uuid":"806239933","full_name":"tmlmt/milk-tracker","owner":"tmlmt","description":"Light breastfeeding data analysis ","archived":false,"fork":false,"pushed_at":"2024-07-21T20:46:17.000Z","size":1209,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-14T08:39:06.921Z","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":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tmlmt.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2024-05-26T18:56:40.000Z","updated_at":"2024-07-21T20:46:16.000Z","dependencies_parsed_at":"2024-06-11T14:01:53.551Z","dependency_job_id":"0add6f63-32f2-4108-a4fc-03786dad68a9","html_url":"https://github.com/tmlmt/milk-tracker","commit_stats":null,"previous_names":["tmlmt/milk-tracker"],"tags_count":19,"template":false,"template_full_name":null,"purl":"pkg:github/tmlmt/milk-tracker","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tmlmt%2Fmilk-tracker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tmlmt%2Fmilk-tracker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tmlmt%2Fmilk-tracker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tmlmt%2Fmilk-tracker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tmlmt","download_url":"https://codeload.github.com/tmlmt/milk-tracker/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tmlmt%2Fmilk-tracker/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28534159,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-18T00:39:45.795Z","status":"online","status_checked_at":"2026-01-18T02:00:07.578Z","response_time":98,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2026-01-18T09:29:59.608Z","updated_at":"2026-01-18T09:30:01.852Z","avatar_url":"https://github.com/tmlmt.png","language":"Python","readme":"# Milk Tracker\n\n![GitHub License](https://img.shields.io/github/license/tmlmt/milk-tracker?color=green) ![Release](https://img.shields.io/github/v/release/tmlmt/milk-tracker?color=blue \"Version\") ![Coverage](./coverage.svg \"Coverage\")\n\n\u003cp float=\"left\"\u003e\n    \u003cimg src=\"screenshot-01.png\" width=\"400\" /\u003e\n    \u003cimg src=\"screenshot-02.png\" width=\"400\" /\u003e\n\u003c/p\u003e\n\nBasic breastfeeding data analysis and tracking\n\n## Introduction\n\nThe idea of this app stemmed from the need to track and visualize breastfeeding meal statistics stored in a Pandas DataFrame. This was the opportunity to learn how to create and deploy a web app based on python-based nicegui, an alternative to streamlit with better state management and handling of user interaction. It quickly expanded to learn even more how to develop python applications with best development practices like:\n\n- formatting and linting with [ruff](https://github.com/astral-sh/ruff)\n- deploying with GitHub Actions\n- split code using a model-view-controller design pattern\n- validate data using [pydantic](https://github.com/pydantic/pydantic) models\n- keep track of changes using [git-cliff](https://github.com/orhun/git-cliff)\n- managing a python environment using [micromamba](https://mamba.readthedocs.io/en/latest/user_guide/micromamba.html)\n- Testing the code prior to releasing using [pytest](https://pytest.org/)\n- Calculating the coverage of tests using [coverage](https://coverage.readthedocs.io/en/latest/)\n- Typing python code and checking it with [mypy](https://mypy.readthedocs.io/en/stable/)\n\nHuge thanks to the Open Source community for providing such great tools to the world.\n\n## Features\n\n- Protect access with password\n- Record meals start and end times\n- Lock start time of new meal\n- Keep track of meal rounds during ongoing meal\n- Reminders for daily intake of vitamins\n- See latest three days trends in graphs\n- See daily stats in a table\n- Keep a log of daily memories\n\n## Backlog\n\n- Edit and delete any meal\n\n## Tried without satisfactory result\n\n- Prediction of next meal's time and duration (Facebook Prophet couldn't really predict accurately -- see https://github.com/tmlmt/milk-tracker/issues/15. Perhaps additional metadata would help, or another algorithm may be more addapted)\n\n## Self-hosting\n\nThe following instructions rely on the use of [micromamba](https://mamba.readthedocs.io/en/latest/user_guide/micromamba.html) for managing python environment and [nginx](https://nginx.org) for the web server. \n\n1. Use `env.yaml` file to create your environment: `micromamba env create -f env.yaml`\n2. Copy `milk_tracker` folder in your web server area, e.g. `/var/www/`\n3. Create an `.env` file within that folder with the following content: \n\n```\nAPP_PORT=\u003cport_number\u003e\nPASSWORD=\u003cargon2 password hash as login\u003e\nSTORAGE_SECRET=\u003cpassphrase to protect your storage area\u003e\n```\n\n4. Customize the `milk_tracker/config.yaml` file\n5. Initialize the meal journal and memories log by renaming `assets/journal.template.xlsx` and resp. `assets/memories.template.csv` into `assets/journal.xlsx` and resp. `assets/memories.csv`\n6. Use `scripts/milk-tracker.conf` as example to configure the redirection of http requests to your app using nginx and your own domain\n7. Use `scripts/milk-tracker.service` as example to configure a systemd unit to manage the start/stop of the app\n8. Enable the unit, e.g. `systemctl --user enable milk-tracker.service` if you're running the app using a specific user and choose to run user units\n9. Start the app, e.g. `systemctl --user start milk-tracker.service` \n10. Go to [https://\u003cyour_domain\u003e:\u003cport_number\u003e](https://\u003cyour_domain\u003e:\u003cport_number\u003e) and start tracking :-)\n\n## License\n\nMIT License\n\nCopyright (c) 2024 Thomas Lamant","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftmlmt%2Fmilk-tracker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftmlmt%2Fmilk-tracker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftmlmt%2Fmilk-tracker/lists"}