anschelburk / simple_planner

Apache License 2.0
0 stars 0 forks source link

Code Review #3: Editable HTMX Boxes #18

Closed anschelburk closed 3 months ago

anschelburk commented 3 months ago

Summary & Update

Thank you for your comment - I have now implemented the changes into this branch. This ended up being an unexpectedly interesting exercise: I was given a link to a separate GitHub repo which was similar enough to integrate a lot of the code, but different enough that I had to first go through everything, learn the names of the variables and models you used (most of which were different from mine), change the code so it was compatible with my repo, and then integrate the relevant parts of it in.

This started out very slow for me: I spent a lot of time looking up individual lines and sections of code, and spent a significant amount of time at the end of Day 1 / beginning of Day 2 figuring out how I could effectively organize and document my work (for myself) so that I wouldn't lose track of anything. (I kept in mind that, recently, you found that a piece of my code had failed simply because of four minor typos. I realized that in order to avoid that here, I needed to have a good enough organizational system to keep track of what I was doing - especially in Django, where many of the modules import each other, and depend on each other to work.)

In the end, I came out with what seems like a much better system for organizing my code within my IDE and getting things done. (I'll show you tomorrow - an unexpected bonus was that my system was good enough that I was able to completely debug my own code - in under 15 minutes!) I imagine that this kind of exercise - looking at a repo someone else created to help with a current project - is probably not uncommon in software roles, and it was really cool to get some experience successfully going through that process here.

Questions

A few questions I'd like to go over tomorrow:

Next Steps

A few next steps that I think would be good:

  1. Make sure the list/ URLConfig has an editing feature - I was only able to see an Add button.
  2. Expand this feature for multiple to-do lists.
  3. Integrate the calendar and list onto a single page.
    • My guess for the most efficient way to do this would be to edit the base_site.html page to include multiple frames, each one loading a distinct HTML template. However, if you think there's a better way, please let me know!

Looking forward to checking in tomorrow morning!

-AKB

bbelderbos commented 3 months ago

Awesome progress. let's walk through this in ~2 hours ...

Re admin, the decorator code is here: venv/lib/python3.1x/site-packages/django/contrib/admin/decorators.py(I have a shortcut in Vim that lets me jump to source code rapidly)

The first part of this update is really interesting, getting code provided by another dev working is a super valuable and needed skill ("not uncommon" -> "very common" I think actually)

Would you like to blog post about this after PDM? You can do so on our blog ... (I can think of at least 5 other cool posts you could do haha, up to you though ...)

bbelderbos commented 3 months ago

2 small fixes on https://github.com/anschelburk/simpleplanner/pull/19/files + starter steps for multi widget feature which I logged here: https://github.com/anschelburk/simpleplanner/issues/20

bbelderbos commented 3 months ago

If you want to work from my changes merge them into this branch, then merge it into main and start a new branch please.