Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: Remove list_items schema #413

Closed
4 tasks done
nelsonic opened this issue Sep 3, 2023 · 11 comments
Closed
4 tasks done

Chore: Remove list_items schema #413

nelsonic opened this issue Sep 3, 2023 · 11 comments
Assignees
Labels
chore a tedious but necessary task often paying technical debt elixir Pull requests that update Elixir code in-progress An issue or pull request that is being worked on by the assigned person priority-1 Highest priority issue. This is costing us money every minute that passes. T2h Time Estimate 2 Hours tech-debt A feature/requirement implemented in a sub-optimal way & must be re-written technical A technical issue that requires understanding of the code, infrastructure or dependencies

Comments

@nelsonic
Copy link
Member

nelsonic commented Sep 3, 2023

I captured the addition of list_items in: book/mvp/list_items
image

But the more I look at it, the more I feel this schema is superfluous.
Basically it's just being used as a place to store the sequence of item.cids.
It creates additional complexity without a tangible benefit other than a degree of normalisation.
But if we just put the seq field directly in the list and use papertrail to track changes,
we can achieve effectively the same result in terms of both accountability/audibility and "undo" functionality.

Todo

  • Remove the list_items schema. ✂️
  • Add seq field to list schema ➕
  • Refactor the functions. 🧑‍💻 ♻️
  • Update the docs 📝

Besides simplifying the schema so that it becomes easier to reason about and query,
I think we can speed up the items_with_timers query by inlining the sub-query.
So I want to get this done ASAP.

@nelsonic nelsonic added T2h Time Estimate 2 Hours technical A technical issue that requires understanding of the code, infrastructure or dependencies priority-1 Highest priority issue. This is costing us money every minute that passes. chore a tedious but necessary task often paying technical debt tech-debt A feature/requirement implemented in a sub-optimal way & must be re-written elixir Pull requests that update Elixir code labels Sep 3, 2023
@nelsonic nelsonic self-assigned this Sep 3, 2023
@nelsonic nelsonic moved this to 🔖 Ready for Development in dwyl app kanban Sep 4, 2023
@nelsonic nelsonic moved this from 🔖 Ready for Development to 🏗 In progress in dwyl app kanban Sep 5, 2023
@nelsonic nelsonic added the in-progress An issue or pull request that is being worked on by the assigned person label Sep 5, 2023
@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

Tackling this now. 🧑‍💻 ⏳

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

3 files deleted. code significantly simplified. all functionality preserved. zero regrets.

12 files changed, 112 insertions(+), 334 deletions(-)

Muuuuuuuuch betterer! 👌

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

https://github.com/dwyl/mvp/actions/runs/6080146395/job/16493657525#step:1:40
image

Warning: Failed to download action 'https://api.github.com/repos/actions/checkout/tarball/f43a0e5ff2bd294095638e18286ca9a3d1956744'. Error: Response status code does not indicate success: 503 (Service Unavailable).
Warning: Back off 24.429 seconds before retry.
Error: Response status code does not indicate success: 503 (Service Unavailable).

🤦‍♂️

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

Attempting to re-run failed job:
image

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

Still failing ... 😞

image

Looks like I'm heading to bed. 🛌

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

image

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

Checkout continues to fail:

image
Error: Can't use 'tar -xzf' extract archive file: /home/runner/work/_actions/_temp_308d408f-5b9e-41ff-a895-4601d0a7fcd6/032c8199-d0ef-4408-901d-2b1e5823d97f.tar.gz. return code: 2.

Lame.

@LuchoTurtle
Copy link
Member

I've re-run the action and it seems to be working now - https://github.com/dwyl/mvp/actions/runs/6080146395/job/16499914191.

It appears to have been a degradation problem with Github Actions, as per https://www.githubstatus.com/.

image

I believe this can be closed now :D Looks awesome, amazing work 🥳

@nelsonic
Copy link
Member Author

nelsonic commented Sep 5, 2023

Thanks for taking a look @LuchoTurtle 👌
Included (excluded) in #345

@nelsonic nelsonic closed this as completed Sep 5, 2023
@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in dwyl app kanban Sep 5, 2023
@nelsonic
Copy link
Member Author

nelsonic commented Sep 6, 2023

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore a tedious but necessary task often paying technical debt elixir Pull requests that update Elixir code in-progress An issue or pull request that is being worked on by the assigned person priority-1 Highest priority issue. This is costing us money every minute that passes. T2h Time Estimate 2 Hours tech-debt A feature/requirement implemented in a sub-optimal way & must be re-written technical A technical issue that requires understanding of the code, infrastructure or dependencies
Projects
Status: Done
Status: Done
Development

No branches or pull requests

2 participants