!rGlCMuXgAhgEpdvJUz:nixos.org

NixOS KDE

220 Members
60 Servers

Load older messages


SenderMessageTime
5 Sep 2024
@outfoxxed:outfoxxed.meoutfoxxed when the application updates and its store path changes, the cache is invalidated and the old files are also replaced 07:07:49
@outfoxxed:outfoxxed.meoutfoxxedas opposed to just leaving them there like the patch set does currently07:07:59
@k900:0upti.meK900But how would you know which files to replace07:08:35
@outfoxxed:outfoxxed.meoutfoxxedbecause they would have the same name07:08:48
@outfoxxed:outfoxxed.meoutfoxxedwhich is the hashed qrc path07:08:59
@k900:0upti.meK900Oh wait07:09:04
@k900:0upti.meK900Yeah I think I see what you mean07:09:09
@k900:0upti.meK900But I'm not sure about that07:09:12
@k900:0upti.meK900 Because having two store paths with the same qrc name but different versions installed at the same time is not that unlikely 07:09:39
@outfoxxed:outfoxxed.meoutfoxxedI think it should be implemented in the load/store functions as late as possible to avoid touching any internal structures that are more likely to change07:09:40
@outfoxxed:outfoxxed.meoutfoxxedjust add a header with the store path07:09:56
@outfoxxed:outfoxxed.meoutfoxxedand theres no risk of reading corrupt old caches because caching was disabled07:10:27
@outfoxxed:outfoxxed.meoutfoxxedAlso we should only do this for applications located in the nix store07:11:19
@outfoxxed:outfoxxed.meoutfoxxedWhat might work well here is to reuse the version field that the qml engine already stores with the cache and set it to max(whatever int type) to signify it has an extra header07:13:52
@outfoxxed:outfoxxed.meoutfoxxedso it will be discarded if its somehow loaded in non-store mode07:14:12
@outfoxxed:outfoxxed.meoutfoxxedits a uint32, we have plenty of headroom on the version number07:15:55
@k900:0upti.meK900I don't know about that07:16:57
@outfoxxed:outfoxxed.meoutfoxxeddo you have a better idea?07:17:07
@k900:0upti.meK900I don't want to mess with the internals any more than absolutely necessary07:17:35
@k900:0upti.meK900Maybe we should talk to Qt upstream and see what they think07:17:49
@outfoxxed:outfoxxed.meoutfoxxedI don't either but I also don't want hundreds of outdated cache files07:17:53
@outfoxxed:outfoxxed.meoutfoxxedyeah thats probably a good idea07:18:03
@outfoxxed:outfoxxed.meoutfoxxedI'll mention it07:18:30
@outfoxxed:outfoxxed.meoutfoxxedlooking through the load/store code its pretty integrated07:21:56
@outfoxxed:outfoxxed.meoutfoxxedprobably less of a good idea than I hoped07:22:13
@k900:0upti.meK900I'm also putting some notes on the PR07:26:06
@outfoxxed:outfoxxed.meoutfoxxedWhat do you think of hashing the application and qtdeclarative versions together and putting them in qml_compile_hash07:27:33
@outfoxxed:outfoxxed.meoutfoxxedthats a 48 character space usually used for just the qtdeclarative version07:27:49
@outfoxxed:outfoxxed.meoutfoxxedand already embedded in the qmlc07:27:57
@outfoxxed:outfoxxed.meoutfoxxedwe can use one or more bytes to signify it should be read as a hash of both and compared as such07:28:31

Show newer messages


Back to Room ListRoom Version: 9