Skip to content

Junk-Store: Merge PR's and minor updates #782

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

Merged
merged 7 commits into from
Apr 1, 2025

Conversation

ebenbruyns
Copy link
Contributor

@ebenbruyns ebenbruyns commented Mar 12, 2025

Junk-Store

This merges PR's from PartyWumpus, GloriousEggroll and Ugzuzg.

PartyWumpus: changed scripts to work on nixos
GloriousEggroll: Added changes to make Umu fixes work correctly.
Ugzuzg: Changed sorting to be case insensitive on the game grid screen.

Fix for Garden Story where ${} was in the name the $ needed escaping.

Added args that needs to be passed to games that was over looked in the initial builds (very few if any games might be affected by this).

Task Checklist

Developer

  • I am the original author or an authorized maintainer of this plugin.
  • I have abided by the licenses of the libraries I am utilizing, including attaching license notices where appropriate.

Plugin

  • I have verified that my plugin works properly on the Stable and Beta update channels of SteamOS.
  • I have verified my plugin is unique or provides more/alternative functionality to a plugin already on the store.

Backend

  • No: I am using a custom backend other than Python.
  • No: I am using a tool or software from a 3rd party FOSS project that does not have it's dependencies statically linked.
  • No: I am using a custom binary that has all of it's dependencies statically linked.

Community

  • I have tested and left feedback on two other pull requests for new or updating plugins.
  • I have commented links to my testing report in this PR.

Testing

  • Tested by a third party on SteamOS Stable or Beta update channel.

This mergest PR's from Beebles, GloriousEggroll and Ugzuzg.

Beebles: changed scripts to work on nixos
GloriousEggroll: Added changes to make Umu fixes work correctly.
Ugzuzg: Changed sorting to be case insensitive on the game grid screen.

Fix for Garden Story where ${} was in the name the $ needed escaping.

Added args that needs to be passed to games that was over looked in the initial builds (very few if any games might be affected by this).
@ebenbruyns ebenbruyns requested a review from a team as a code owner March 12, 2025 22:01
@EMERALD0874
Copy link
Member

EMERALD0874 commented Mar 12, 2025

Please properly fill out the template and comment when done.

  • Replace REPLACE_WITH_PLUGIN_NAME.
  • Replace REPLACE_WITH_SUMMARY with the summary you provided above it.
  • Remove the unnecessary testing checkbox per the Markdown comment in the testing section.

@github-project-automation github-project-automation bot moved this to 🆕 New in SDH Tracker Mar 12, 2025
@EMERALD0874 EMERALD0874 moved this from 🆕 New to 👀 In review in SDH Tracker Mar 12, 2025
Copy link
Member

@EMERALD0874 EMERALD0874 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for testing store.

@TrainDoctor TrainDoctor moved this from 👀 In review to 🔖 Ready for review in SDH Tracker Mar 12, 2025
@GedasFX
Copy link
Contributor

GedasFX commented Mar 15, 2025

Clicking Install Dependencies button made my deck hang on this
20250315_233101

Is this supposed to take more than 10 minutes?

Logs:

[2025-03-15 23:26:47,262][INFO]: Migrating
[2025-03-15 23:26:47,263][INFO]: Junk-Store starting up...
[2025-03-15 23:26:47,263][INFO]: plugin: Junk-Store dir: /home/deck/homebrew/data/Junk-Store
[2025-03-15 23:26:47,263][INFO]: Junk Store initializing
[2025-03-15 23:26:47,263][INFO]: execute_action cmd: ./scripts/junk-store.sh init
[2025-03-15 23:26:47,263][INFO]: execute_action args: ()
[2025-03-15 23:26:47,263][INFO]: execute_action app_id:
[2025-03-15 23:26:47,264][INFO]: execute_action game_id:
[2025-03-15 23:26:47,264][INFO]: execute_action input_data:
[2025-03-15 23:26:47,264][INFO]: call_script: ./scripts/junk-store.sh init ()
[2025-03-15 23:26:47,264][INFO]: call_script: ./scripts/junk-store.sh init
[2025-03-15 23:26:47,264][INFO]: input_data:
[2025-03-15 23:26:47,264][INFO]: args: ()
[2025-03-15 23:26:47,264][INFO]: creating lock
[2025-03-15 23:26:47,264][INFO]: inside lock
[2025-03-15 23:26:47,264][INFO]: running cmd: ./scripts/junk-store.sh init
[2025-03-15 23:26:47,276][INFO]: Junk Store initialized
[2025-03-15 23:26:47,277][INFO]: Starting WebSocket server on port 8765
[2025-03-15 23:26:47,280][ERROR]: Error in start_ws_server: Call runner.setup() before making a site
[2025-03-15 23:26:47,281][INFO]: Junk-Store started
[2025-03-15 23:26:49,240][INFO]: execute_action: init InitActions
[2025-03-15 23:26:49,241][INFO]: execute_action args: ()
[2025-03-15 23:26:49,241][INFO]: execute_action cmd: ./scripts/get-json.py main-menu-actions
[2025-03-15 23:26:49,241][INFO]: execute_action args: ()
[2025-03-15 23:26:49,241][INFO]: execute_action app_id:
[2025-03-15 23:26:49,241][INFO]: execute_action game_id:
[2025-03-15 23:26:49,241][INFO]: execute_action input_data:
[2025-03-15 23:26:49,241][INFO]: call_script: ./scripts/get-json.py main-menu-actions ()
[2025-03-15 23:26:49,241][INFO]: call_script: ./scripts/get-json.py main-menu-actions
[2025-03-15 23:26:49,241][INFO]: input_data:
[2025-03-15 23:26:49,242][INFO]: args: ()
[2025-03-15 23:26:49,242][INFO]: creating lock
[2025-03-15 23:26:49,242][INFO]: inside lock
[2025-03-15 23:26:49,242][INFO]: running cmd: ./scripts/get-json.py main-menu-actions
[2025-03-15 23:26:49,283][INFO]: Init action set MainMenu
[2025-03-15 23:26:49,286][INFO]: execute_action: MainMenu GetContent
[2025-03-15 23:26:49,286][INFO]: execute_action args: ()
[2025-03-15 23:26:49,286][INFO]: execute_action cmd: ./scripts/get-json.py main-menu-content
[2025-03-15 23:26:49,286][INFO]: execute_action args: ()
[2025-03-15 23:26:49,286][INFO]: execute_action app_id:
[2025-03-15 23:26:49,287][INFO]: execute_action game_id:
[2025-03-15 23:26:49,287][INFO]: execute_action input_data:
[2025-03-15 23:26:49,287][INFO]: call_script: ./scripts/get-json.py main-menu-content ()
[2025-03-15 23:26:49,287][INFO]: call_script: ./scripts/get-json.py main-menu-content
[2025-03-15 23:26:49,287][INFO]: input_data:
[2025-03-15 23:26:49,287][INFO]: args: ()
[2025-03-15 23:26:49,287][INFO]: creating lock
[2025-03-15 23:26:49,287][INFO]: inside lock
[2025-03-15 23:26:49,287][INFO]: running cmd: ./scripts/get-json.py main-menu-content

Nothing on FE logs.

@GedasFX GedasFX mentioned this pull request Mar 15, 2025
7 tasks
@ebenbruyns
Copy link
Contributor Author

That's a race condition that I've been chasing for months now. I think you stumbled on a thread (pun intended) that I might be able to pull on here!

@ebenbruyns
Copy link
Contributor Author

@GedasFX once this is deployed to the testing store could you verify that it's now actually working?

@GedasFX
Copy link
Contributor

GedasFX commented Mar 15, 2025

Yeah will do but will have to wait for tomorrow ^^ you can probably see the time from the steam deck 😄

@ebenbruyns
Copy link
Contributor Author

All good, I have a deck that's untouched by any dev tools, so I'll check it on that too, but race conditions are VERY hard to test reliably.

@ebenbruyns
Copy link
Contributor Author

I've tested on my "clean" deck. It appears to work, but it's a race condition so take that for what it's worth.

@GedasFX
Copy link
Contributor

GedasFX commented Mar 16, 2025

Plugin Testing Report

Installed Plugins

  • Decky Cloud Save - 1.4.2-pre1
  • Junk-Store - 1.1.9-d7a47dc
  • Decky Ludusavi - 1.0.0
  • ProtonDB Badges - 1.0.12-1
  • HLTB for Deck - 1.4.2
  • Emuchievements - 2.0.3
  • SteamGridDB - 1.4.0
  • vibrantDeck - 2.0.1
  • PowerTools - 2.0.2
  • Steam Deck HQ - 1.0-0338b3d

Specifications

  • SteamOS 20250224.1(Stable)
  • Steam 1741737356 (Stable)
  • Decky v3.1.3 (Stable)

Issues

Has the following major blocking issue(s):
[1] Clicking install Dependencies does not actually populate the textbox with logs, but they all do appear after the download is done. This leaves the impression that the program still halts, however it took 2 minutes to finish. Subpar UX. According to this video this feature used to work and broke at some point.

[3] After logging in to Epic Games, no games show up. Took me a while to figure out that I need to click "refresh games" in a settings menu. According to this video this feature used to work and broke at some point.

Has the following minor non-blocking issue(s):
[2] Trying to sign into Epic Games makes no keyboard appear, which is not much of the plugin's fault, but as a person who took a 1 year break from steam deck, forgot the good old steam+X. Trying to sign in with Google, it says it opens a new page, but it doesn't.

[4] I tried launching a game "Cat Quest" to try out if integration works, and, it opens, but it requested OAuth from Epic Games, which, while worked, it didn't end up closing. I needed to manually close the window afterwards. Unsure if anything can be done about this.

[5] README shows 2 tutorial videos, but it is actually, the same video. You should clean that up :D

Summary

After downloading the updated plugin and retrying the install dependencies, I was greeted with issue [1], I am not sure if it is worth putting it to a "major" issue but it is for sure regression failure. I was able to at least continue.

Trying to log in with Epic had me stumped a little bit with issue [2], but it was my skill issue for the most part. That being said, I found that if you use OAuth to log in to Epic Games, it will not work, and I couldn't find that documented as a known issue.

After login I see the second regression failure, of [3], where I can see games should auto load, but they haven't. Was able to bypass by clicking the first settings button of the two and selecting reload.

Installation and launching works okay, launching from Steam works okay too. If epic games requests OAuth, the window does not close, however.

Testing of documented changes:

  • Ugzuzg: Changed sorting to be case insensitive on the game grid screen.
    • Tested OK, "Horizon Chase Turbo" shows before "HOT WHEELS UNLEASHED".

Testing Limitations:
Paywalled features, like the GOG launcher, are not tested.
PartyWumpus, GloriousEggroll features - unable to test due to lack of game and or OS.

@ebenbruyns
Copy link
Contributor Author

ebenbruyns commented Mar 16, 2025

@GedasFX I need some more information around #3 (also I do not believe this is a blocking issue as the user can still continue to use the application). The auto refresh of games is actually rather prone to refresh loops. There's code specifically checking if you have text in the search box or if you have the installed flag toggled (pushing x).

Could you verify that this is actually a regression vs the deployed version on the stable store? I have a vague recollection that I might actually have disabled this due to refresh loops when a users logs in and they have no games in their account.

Due to the extensibility of this plugin it comes with a unique set of challenges because everything is async and stateless.

@GedasFX
Copy link
Contributor

GedasFX commented Mar 16, 2025

@ebenbruyns Checked on 1.1.8, seems to work there okay.
Testing process: Uninstall plugin, delete data/Junk-Store, install plugin, open games list
On 1.1.8 - Games load instantly
On 1.1.9-d7a47dc - Games do not load
image

I feel like this is an issue as, as a new user, it for sure confused me why I didn't have any games.

@ebenbruyns
Copy link
Contributor Author

I don't disagree that it's an issue, but it's not a show stopper. Did you clear the databases for the 1.1.8 test? If so this is curious because I haven't gone anywhere near that code. I wonder if there's something in the decky frontend lib that's shifted...

I'll have a closer look at this one. Thanks for spotting it.

@GedasFX
Copy link
Contributor

GedasFX commented Mar 16, 2025

yeah i did the same test for both (on the test process "install plugin" i install either 118 or 119)

@ebenbruyns
Copy link
Contributor Author

So it looks like something has shifted in decky/ui
image

@ebenbruyns
Copy link
Contributor Author

looking into #1, I suspect this has to do with the child process not flushing it's buffers and it's also using \r instea of \n for stuff. it could also be related to python having blocking reads on streams by default and it's a royal pain to have nonblocking streams work in python. This is not really something users engage with a lot so it's not worth trying to solve the none blocking stream read for this one thing. It's a tough one because it's tempting to just skill std err or std out, but that's a half solution either way you look at it.

@ebenbruyns
Copy link
Contributor Author

ebenbruyns commented Mar 17, 2025

so 2 and 4 I can't do anything about, that's out of my control. Oauth is a know issue in game mode, you can how ever do this in desktop mode if you put steam in big picture mode.

5 is a typo, out of scope, but thanks for the heads up, it's sorted now!

I've made some updates, can you verify that they align with your testing now?

@GedasFX
Copy link
Contributor

GedasFX commented Mar 17, 2025

Currently waiting for new build, but I went to check the code you changed, and I only see README was updated? Was 1 or 3 touched on?

As for non-blocking and blocking streams, I do not know what your implementation is, but I engineered something cool before, which might come in useful: just create a fire and forget async task and have its completion be an event, and just wrap it all in a promise. This way it does not block python nor JS render threads.

First, create a task and run it
https://github.com/GedasFX/decky-ludusavi/blob/9917545e4100db7753e497b6982e433406fbddba/main.py#L34
https://github.com/GedasFX/decky-ludusavi/blob/9917545e4100db7753e497b6982e433406fbddba/py_modules/ludusavi.py#L23

Emit completion:
https://github.com/GedasFX/decky-ludusavi/blob/9917545e4100db7753e497b6982e433406fbddba/py_modules/ludusavi.py#L47

And then wrap all together in FE:
https://github.com/GedasFX/decky-ludusavi/blob/9917545e4100db7753e497b6982e433406fbddba/src/util/syncUtil.ts#L39

This basically sets up listener, then fires the start job, which only completes after event is done.
And this is all abstracted away as await backup(gameName).

@GedasFX
Copy link
Contributor

GedasFX commented Mar 17, 2025

2 and 4 are fine, they are minor issues anyway, just wanted to verify if they are known issues. I remember having exact same issues with google drive.

@GedasFX
Copy link
Contributor

GedasFX commented Mar 17, 2025

And another unrelated issue, but it appears that by sheer coincidence, this plugin broke testing of another one: #785 (comment)

This might come as a new issue on github eventually, as if that plugin loaded before this one, then functionality of this plugin would have been affected instead.

Right now I am not too sure what to do about this, personally will ignore it's existence, but someone from loader team should come in with support.

@jessebofill
Copy link
Contributor

And another unrelated issue, but it appears that by sheer coincidence, this plugin broke testing of another one: #785 (comment)

This might come as a new issue on github eventually, as if that plugin loaded before this one, then functionality of this plugin would have been affected instead.

Right now I am not too sure what to do about this, personally will ignore it's existence, but someone from loader team should come in with support.

it wont be a problem on this side as I state here #785 (comment)

@mrsjunkrunner
Copy link

v1.1.9 resolves this issue ebenbruyns/junkstore#84

Issue now closed as fix is confirmed by author.

@mrsjunkrunner
Copy link

The new version waiting to be merged to testing seems to also resolve this issue: ebenbruyns/junkstore#37

Leaving it open until we can confirm from new testing release.

@GedasFX
Copy link
Contributor

GedasFX commented Mar 23, 2025

All issues appear to be resolved, LGTM!

@ebenbruyns
Copy link
Contributor Author

Just waiting on my own testers to complete their test report before thinking about moving to stable.

@Tech127x
Copy link

Tech127x commented Mar 26, 2025

Plugin Testing Report

Installed Plugins
Junk-Store - 1.1.9-2f05eff

Specifications
SteamOS Holo 3.6.22
Steam Ver 1741737356
Decky ver 3.1.4-pre1

Issues
Major - none
Minor - none

Summary

  • Log out and back into Epic game services multiple times - no problems observed
  • Download and launch multiple games from Epic
    • All tested games download, perform dependency installation automatically, properly launch game
    • Upon relaunch of game, dependencies do not attempt to reinstall, game launches and plays properly
    • Entry added to Steam "non-steam games" for installed game and launch properly from there as well as in JunkStore as expected

@ebenbruyns
Copy link
Contributor Author

@EMERALD0874 when you get a chance can you deploy a new build with the last commit so we can verify that it works. I think this is probably very close to being ready. The last commit is a low impact change, just escaping spaces in a shell script essentially.

@TrainDoctor
Copy link
Member

@ebenbruyns deployed, please have a tester confirm then we should be good from there.

@mrsjunkrunner
Copy link

Plugin Testing Report

Installed Plugins:
Junk-Store - 1.1.9-a48ef7b
Wine Cellar: v0.1.6-cf38b52

Specifications:
Decky Version: v3.1.3 (Stable Channel)
Steam OS Holo: 3.6.20 (Stable Channel)
Steam Version: 1741737356

Issues:
Major - none
Minor - none

Summary:

New commit tested muptiple times on non-dev Steam Deck. Changed exe names for games to have a space. Behaves as expected, no longer breaks exe files into separate buttons if there is a space in the name.

@ebenbruyns
Copy link
Contributor Author

@Tech127x Do you mind just resubmitting your test report after testing the last commit... then I think we might be good to go to stable

@GedasFX not sure if you wanted to weight in again?

@Tech127x
Copy link

Tech127x commented Apr 1, 2025

Plugin Testing Report

Installed Plugins
Junk-Store - 1.1.9-a48ef7b

Specifications
SteamOS Holo 3.6.22
Steam Ver 1741737356
Decky ver 3.1.4-pre1

Issues
Major - none
Minor - none

Summary

Tested naming of games that have a space in their name. If the name of an exe in the game folder has a space or is changed to have a space, the listing in JunkStore when displaying .exe's in directory display correctly and will properly change if I manually change the file name. Multiple attempts with different exe's in different game folders tested (changing/changing back/native) all respond properly

Copy link
Member

@TrainDoctor TrainDoctor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good stuff everyone. Off to production.

@github-project-automation github-project-automation bot moved this from 🔖 Ready for review to 👀 In review in SDH Tracker Apr 1, 2025
@TrainDoctor TrainDoctor merged commit 6db3a45 into SteamDeckHomebrew:main Apr 1, 2025
2 checks passed
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in SDH Tracker Apr 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

7 participants