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

problem getting internet-radio.lua updates within maiden #3

Closed
tapecanvas opened this issue Feb 14, 2024 · 5 comments · Fixed by #4
Closed

problem getting internet-radio.lua updates within maiden #3

tapecanvas opened this issue Feb 14, 2024 · 5 comments · Fixed by #4
Assignees
Labels
bug Something isn't working

Comments

@tapecanvas
Copy link
Owner

tapecanvas commented Feb 14, 2024

went to test updating one of my shields to the latest internet-radio release from maiden

  • got "Updating project "internet-radio" failed update failed: worktree contains unstaged changes" - but there should be no unstaged changes..
  • after this message the commit number shown for internet-norns in the library was the most recent "05428d3"
  • tried to update again: and it seemed to work (no "failed to update" message), but:
  • instead of updating, I got "the latest version of "internet-radio" is already installed..
  • restarted norns also shutdown and restart
  • still no luck (nothing changed after restart or shutdown)
  • removed internet-norns from maiden with "remove" button
  • reinstalled with matron ;install https://github.com/tapecanvas/internet-radio
  • now everything else was updated (license file was added, commit number was most recent, norns screen showed current 0.1.8 header, but lua file in maiden still showed 0.1.7 and wasn't most current code..
  • tried update again, but "latest ver. installed" - 0.1.7 code still in internet-radio.lua
  • manually deleted internet-radio.lua file, from code folder in maiden then removed internet-radio from maiden again and reinstalled with matron ;install https://github.com/tapecanvas/internet-radio
    - now its all up to date...
  • might be a problem with state saving function? - don't think so now.
  • test again after next update
@tapecanvas tapecanvas added the bug Something isn't working label Feb 14, 2024
@tapecanvas tapecanvas self-assigned this Feb 14, 2024
@tapecanvas
Copy link
Owner Author

tapecanvas commented Feb 14, 2024

https://llllllll.co/t/norns-maiden/14052/233 and https://llllllll.co/t/sines/39292/105 might provide some insight. This could just be me editing the script from within maiden and those edits not matching the final version pushed to github.. Will set one shield aside (with 05428d3 code) untouched and see if it updates as expected with the next release..

@tapecanvas
Copy link
Owner Author

@p3r7 helped me wrap my head around the problem:

synopsis

  • My stream files in /lib are being modified (sorted, written to, fav status, etc)
  • maiden detects these changes and won't allow the update to overwrite local modifications in /code
  • changes can be made and stored in dust/data though.

proposed solution

  • "The modified version should go in the data folder. the initial version could still reside in the code folder but it would not be more than a template of sort."

changes required

  1. modify save_streams function and selected_file path to read and write to /dust/data/internet-radio/ directory
  2. Ensure that the initial version of the stream files in the /code/internet-radio/lib directory is only used as a template. (think about what should really be here)
  3. write function to copy the initial "templates" (ie what should be included with install - streams.lua, bbc.lua, template.lua) from /code/internet-radio/lib to /dust/data/internet-radio if they don't already exist aka initial install.
  4. test test test
  5. Update any documentation or comments to reflect changes.

@tapecanvas
Copy link
Owner Author

think I have a fix in place (in the streams-location-changes branch)

summary of changes:

  • updated default stream location paths
  • added section to copy included stream files from /code/internet-radio/lib/ to /data/internet-radio/streams/
  • this should allow stream lists to be modified by the script (during sorting, favoriting, adding, renaming, etc) and saved to a location (/data/) where local modifications do not prevent updates to be installed from maiden script update button.
  • only tested that it runs with no errors so and that the default files are moved into the new directory so far, no update tests, or add/edit/favorite functionality has been tested yet.

@tapecanvas tapecanvas linked a pull request Feb 17, 2024 that will close this issue
@tapecanvas
Copy link
Owner Author

git is confusing, but I finally got the right changes added to the main branch with commit 3b38717

@tapecanvas
Copy link
Owner Author

after some testing and further revisions, the issue is not fully resolved and in the main branch changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant