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

AML hangs after updating mods #268

Open
CyarSkirata opened this issue Apr 20, 2021 · 8 comments · Fixed by #345
Open

AML hangs after updating mods #268

CyarSkirata opened this issue Apr 20, 2021 · 8 comments · Fixed by #345
Labels
Status: Implemented Indicates that the issue has been handled but may not have been merged. Type: Bug
Milestone

Comments

@CyarSkirata
Copy link

AML Version
1.4.1

Description
The program launches as usual, and begins to update mods. Upon completing that step, the program locks up entirely and the window where the mods are displayed turns black.

After launching the program more times than I can count, and deleting and reinstalling it three times, it's only functioned beyond that point twice: and I have no idea what could have changed.

One of these successful launches was the first of the three I've done with the current install, so hopefully the log should show _something different somewhere.

Attachments
AML.log

AML Screenshot 1

AML Screenshot 2

Sorry for the lack of "settings.json" file. Github says it doesn't support the file type and I don't know if or how it could be re-formatted to one of the supported types.

@CyarSkirata CyarSkirata added Status: Review Verify bug or check feasibility of a new feature. Type: Bug labels Apr 20, 2021
@RevZero RevZero changed the title AML crashes on launch AML hangs after updating mods Apr 21, 2021
@RevZero
Copy link
Member

RevZero commented Apr 21, 2021

After all mods have been processed, AML updates/refreshes the mod list view. This is where it sometimes hangs for some reason. Someone else just recently reported the same issue in our Discord channel, but it seems to be a rare.

Your log shows, that it finished normally the first time (as you pointed out).

2021-04-20 22:11:19,536 [ 1]  INFO | MainForm: 387 | ModUpdateTask completed
2021-04-20 22:12:38,705 [ 1]  INFO | MainForm:   0 | ModUpdateTask post processing completed

But it did not continue to the post processing (refreshing the UI) the second and third time.

2021-04-20 22:18:01,078 [ 1]  INFO | MainForm: 387 | ModUpdateTask completed
[hangs]
2021-04-20 22:18:01,078 [ 1]  INFO | MainForm: 387 | ModUpdateTask completed
[hangs]

This may be caused due to an internal bug in the ObjectListView component that is triggered by some edge case (probably timing related). This is hard to narrow down, without being able to reproduce it in my environment.

Does it maybe always work when you start AML for the first time? Either delete settings.json or extract a fresh copy of AML to a different folder and try it out.

If you are willing to join our Discord, we could try some things

@CyarSkirata
Copy link
Author

Both of the times it's worked have been on fresh installs, but it's also failed to work twice on fresh installs.

I have realised just now that there is one thing that I think is common to the fresh installs that worked.

On the first install I obviously hadn't yet saved any modlists when I booted it up.
On the second and third installs, I'd moved my WIP saved modlist into their files before I booted them.
On this fourth install, I didn't do that until after it worked the first time.

I'll test a fresh install and deleting settings.json, and if I can find the address somewhere (or if ya link it) I'll definitely join the Discord. I use the same name there as I do here so I'll be easy to spot.

@CyarSkirata
Copy link
Author

CyarSkirata commented Apr 21, 2021

I've tried a few tests, and I can provide a little more data. All of these tests were done with the saved modlist either removed from the file, or not inserted into the new files.

This is the log from the existing install, after I deleted settings.json and tried it again. Didn't work.
AML deleted settings.log

This log is from a single launch attempt using a fresh extract of the same zip. Also non-functional.
AML fresh extract.log

And here's the log from the fresh download I'm trying now, but it's gotten itself stuck in a different way. It's stopped at mod 702, but it's technically still responding.
The screenshot shows some mods displayed with their full information while others aren't: I'm able to scroll down the window, and if I mouse over a mod, it updates to show that information. There are occasional exceptions, which I assume are the ones the program didn't get to before it got stuck.
I'll leave this one and go do something else for awhile, and I'll update you as to its status when I come back.
AML fresh download.log
AML screenshot 3

@CyarSkirata
Copy link
Author

And after three hours, it's still stuck. Here's a fresh copu of the log incase it's added anything.
AML fresh download after delay.log

@RevZero
Copy link
Member

RevZero commented Apr 21, 2021

Thanks for the testing. The hanging during the update processing is probably not directly related to the freeze when the mod list is updated.

Would be interesting to see what would happen, if you had like "only" 100 mods or so. You obviously do not want to unsubscribe from 600 mods, but I could instruct you to work around that to test it out. Discord is https://discord.gg/QHSVGRn.

@CyarSkirata
Copy link
Author

I'm up for trying it, sure. I've joined the discord: Cyar Skirata#5664

@JoeOlmond
Copy link

I am having a similar issue. When I open the launcher it is good for roughly a minute but then it goes into an unresponsive state. The mod window goes black. After a few minutes the launcher returns to working order with no other problems. I do have over 2000 mods installed.

@RevZero
Copy link
Member

RevZero commented Apr 21, 2023

@JoeOlmond With that many mods, the mod list need a while to update. It probably could be improved by updating the mod-list asynchronously, but I never looked into that because its normally not that much of an issue.
The bottom line is, that the issue of the original poster where it got permanently stuck is probably caused by something else.
Anyway, thanks for reporting.

remcoros added a commit to remcoros/xcom2-launcher that referenced this issue Jul 31, 2023
remcoros added a commit to remcoros/xcom2-launcher that referenced this issue Jul 31, 2023
RevZero pushed a commit that referenced this issue Aug 14, 2023
Should fix #317, fix #289 and fix #268.

* Replaced SteamAPIWrapper with 'SteamManager', which is now responsible for calling 'RunCallbacks' in a timer. Except for startup/shutdown, no one should call init/runcallbacks/shutdown manually.
* Fixed an issue where callbacks (not callresults!) were registered multiple times, resulting in ever growing steamworks callbacks. * Wrapped some steam callbacks (CallResults) into an async helper function using proper async/await constructs.
* Tweaks to mod list being non responsive (also prevent unnecessarily refreshing/redrawing it)
* Load mod dependencies as part of the GetDetails batch requests
* Refresh mod list filter after hide/unhide to update mod list properly
@RevZero RevZero added this to the v1.6 milestone Aug 14, 2023
@RevZero RevZero added Status: Accepted Confirmed bug or useful feature that should be worked on. Status: Implemented Indicates that the issue has been handled but may not have been merged. and removed Status: Review Verify bug or check feasibility of a new feature. Status: Accepted Confirmed bug or useful feature that should be worked on. labels Aug 14, 2023
RevZero pushed a commit that referenced this issue Jul 5, 2024
Should fix #317, fix #289 and fix #268.

* Replaced SteamAPIWrapper with 'SteamManager', which is now responsible for calling 'RunCallbacks' in a timer. Except for startup/shutdown, no one should call init/runcallbacks/shutdown manually.
* Fixed an issue where callbacks (not callresults!) were registered multiple times, resulting in ever growing steamworks callbacks. * Wrapped some steam callbacks (CallResults) into an async helper function using proper async/await constructs.
* Tweaks to mod list being non responsive (also prevent unnecessarily refreshing/redrawing it)
* Load mod dependencies as part of the GetDetails batch requests
* Refresh mod list filter after hide/unhide to update mod list properly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Implemented Indicates that the issue has been handled but may not have been merged. Type: Bug
Projects
None yet
3 participants