dwyl / sleep

πŸ›Œ MVP Sleep-tracking App with Step-by-Step Tutorial
23 stars 3 forks source link

MVP: Manual Sleep Tracking App #53

Open nelsonic opened 2 years ago

nelsonic commented 2 years ago

There are many apps https://github.com/dwyl/sleep/issues/8 and wearable devices https://github.com/dwyl/sleep/issues/7 that people can use for sleep-tracking. The issue is that these have a cost and the people using them have no control of their data.

I want to build the bare minimum interface for capturing/tracking sleep. At it's most basic, a sleep tracker is just a stop-watch https://github.com/nelsonic/stopwatch But rather than simply discarding the start and stop times, we record them.

Todo

Dependent on:

My plan is to write this out as a tutorial that a complete beginner can follow similar to all of our others.

nelsonic commented 2 years ago

Thinking of just using Google Docs / Draw.io to wireframe this ... see: https://github.com/dwyl/learn-wireframing

nelsonic commented 2 years ago

Simon has been implementing auth in the LiveView Chat app: https://github.com/dwyl/phoenix-liveview-chat-example/pull/16/files

I think we will do it slightly differently in this Sleep App because I don't really want to allow "anonymous" use. API Key: https://authdev.herokuapp.com/apps/3 πŸ”‘

nelsonic commented 2 years ago

I feel like my lack of sleep - and crucially my poor sleep communication - is holding me back in life. See: https://github.com/dwyl/sleep/issues/46 So I'm bumping up the priority on this and moving it to "In progress" so I will chip away at it over the coming weeks.

nelsonic commented 2 years ago

Can you tell what it is yet? 😜 phoenix-framerwork-welcome-page

nelsonic commented 2 years ago

Continue: ~/code/phoenix-liveview-chat-example ~/code/sleep

(have to restart my Mac to install updates ...)

nelsonic commented 2 years ago

I'm keen to use our "Prod" Auth instance for this so that there is zero start-up/wait time for using this twice-a-day app.

nelsonic commented 2 years ago

Deployed the "Prod" version to Fly.io https://auth.dwyl.com which means that Auth has zero startup time. So going to use that to make this mini app.

nelsonic commented 2 years ago

https://github.com/dwyl/sleep/tree/basic-sleep-app-issue-%2353

nelsonic commented 2 years ago

Tried to git push the code I wrote over the weekend as need to close all my non-work tabs to focus on work-work ... Get the following error:

Enumerating objects: 15, done.
Counting objects: 100% (15/15), done.
Delta compression using up to 8 threads
Compressing objects: 100% (10/10), done.
Writing objects: 100% (11/11), 2.44 KiB | 1.22 MiB/s, done.
Total 11 (delta 3), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (3/3), completed with 2 local objects.
remote: Internal Server Error
To github.com:dwyl/sleep.git
 ! [remote rejected] basic-sleep-app-issue-#53 -> basic-sleep-app-issue-#53 (Internal Server Error)
error: failed to push some refs to 'github.com:dwyl/sleep.git'

From googling, it looks like GitHub is having a hickup: https://stackoverflow.com/questions/71514374/im-trying-to-git-push-some-changes-and-i-get-this-internal-server-error https://github.com/isaacs/github/issues/1253 https://www.githubstatus.com/

github-status-1 github-status-2 github-status-3

Just going to close all the windows and hope that my Laptop doesn't die while GitHub is not working ... ⏳

Will continue with this mini side-project on the weekend. 🀞

nelsonic commented 2 years ago

Continue: https://github.com/dwyl/sleep/blob/basic-sleep-app-issue-%2353/tutorial.md