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

[Feature] Browse CKAN/history/*.ckan files in GUI #3741

Closed
Crudefern opened this issue Dec 10, 2022 · 4 comments · Fixed by #3834
Closed

[Feature] Browse CKAN/history/*.ckan files in GUI #3741

Crudefern opened this issue Dec 10, 2022 · 4 comments · Fixed by #3834
Labels
Enhancement New features or functionality GUI Issues affecting the interactive GUI

Comments

@Crudefern
Copy link

Crudefern commented Dec 10, 2022

Problem

It's really annoying when ckan crashes or some other problem that restarts ckan and the list of mods to install/remove is wiped.

Suggestions

A history/changelist so you can see the changes you have made recently through restarts.
Or the ability to save a list of mods to a file to install a bunch of mods at once.
I would try coding it myself but i don't know C#

@Crudefern Crudefern changed the title Mod changelist? [Feature] Mod changelist? Dec 10, 2022
@HebaruSan
Copy link
Member

HebaruSan commented Dec 15, 2022

Hmm, the problem is about saving pending changesets somewhere in case there's a crash, but the suggestions don't look like they would help with that.

A history/changelist so you can see the changes you have made recently through restarts.

This is available in the form of .ckan files in the <game dir>/CKAN/history folder, created each time you install or remove mods.

Or the ability to save a list of mods to a file to install a bunch of mods at once.

This also exists currently:

Does either of those things solve your problem?

@HebaruSan HebaruSan added the Support Issues that are support requests label Dec 15, 2022
@Crudefern
Copy link
Author

i did not know about either of those

@Crudefern
Copy link
Author

Crudefern commented Dec 15, 2022

those will help but i was thinking of the history being built into the .exe in a menu option so you don't have to go digging through files to find it

@HebaruSan HebaruSan added Enhancement New features or functionality GUI Issues affecting the interactive GUI and removed Support Issues that are support requests labels Dec 15, 2022
@HebaruSan HebaruSan changed the title [Feature] Mod changelist? [Feature] Browse CKAN/history/*.ckan files in GUI Dec 15, 2022
@HebaruSan
Copy link
Member

HebaruSan commented Apr 26, 2023

There are some performance-related technical challenges to this idea:

  • The list of files grows with no upper bound (my Steam instance's CKAN/history folder currently has 2836 files!)
  • There's no index listing or inherent organization other than what the filesystem natively provides
  • If there are a lot of files, just looping over their names and sorting by timestamp takes several seconds in Windows Explorer, which is not really acceptable for an interactive application. (I'm on an HDD, so it's slower than SSD or NVME, but there's nothing stopping a user from doing that as well.)
  • Loading and parsing all of them to get things like mod names or counts would simply be out of the question

So we would need a UI that in principle could handle hundreds or thousands of files. It would have to avoid applying any file-read operation to the whole list, so maybe just show a list of timestamps and then show details after the user clicks one of them. We would need some kind of loading mode in the UI during which the mouse would be an hourglass, etc., ideally with the option to cancel if the user changes their mind. If we think it's crucial to show mod counts, we could do something like parsing one screenful of files in a background thread and updating the UI.

Assuming we can manage that, the user would most likely want to:

  • View the list of mods and their versions for any previous point in the history
  • Revert the currently installed mods to a previous list, which would require turnkey support for removing and downgrading versions, with decent recovery for versions that have since been frozen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New features or functionality GUI Issues affecting the interactive GUI
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants