js-dos icon indicating copy to clipboard operation
js-dos copied to clipboard

Index DB issue on saving the game

Open muditjuneja opened this issue 8 months ago • 2 comments
trafficstars

Hi Team, I am getting below error -

NotFoundError: Failed to execute 'transaction' on 'IDBDatabase': One of the specified object stores was not found.
    at lcache.ts:113:41
    at new Promise (<anonymous>)
    at si.put (lcache.ts:107:16)
    at bundle-storage.ts:88:10
    at async Bi (player-api-load.ts:79:11)
    at async main.tsx:55:29

This happens when the player is loading hinders game saving. I can say that I am seeing it in a flaky manner where sometimes it happens and sometimes it doesn't and saving flow works.

Can you help here?

muditjuneja avatar Feb 24 '25 21:02 muditjuneja

Looks like browser bug, what browser do you used?

caiiiycuk avatar Feb 24 '25 22:02 caiiiycuk

I am on Brave Browser which is based out of chromium engine only.

muditjuneja avatar Feb 25 '25 06:02 muditjuneja

i have the same with Firefox and FF Nightly

Benman2785 avatar Jul 15 '25 09:07 Benman2785

Can you provide more details, like what game you playing, where, etc.

caiiiycuk avatar Jul 15 '25 10:07 caiiiycuk

Image

this is the "second" save i did this game

Benman2785 avatar Aug 23 '25 09:08 Benman2785

Is it reproducible? Can you share bundle to test?

caiiiycuk avatar Aug 23 '25 11:08 caiiiycuk

yes it is reproduceable

  1. go to: https://hoffmeister.li/js-dos/
  2. choose either "Perry Rhodan: Operation Eastside" or "BotF *"
  3. play game and save at one point
  4. quit game and shut down windows in js-dos
  5. choose "save progress" = yes
  6. 1-5 again = bug reproduced

here the package i use: https://hoffmeister.li/js-dos/games/PROE.jsdos (530mb)

ps: first save always works -> but 2nd,3rd,nth save doesnt work

Benman2785 avatar Aug 23 '25 19:08 Benman2785

mh, chatgpt says the problem is that i use multiple img files in my bundle -> one for Win95 and one for the game (yet i prefer this method) will try to make one with game and OS on same img file -> maybe i have time for that tomorrow or within next week

Benman2785 avatar Aug 23 '25 21:08 Benman2785

mh, chatgpt says the problem is that i use multiple img files in my bundle -> one for Win95 and one for the game (yet i prefer this method) will try to make one with game and OS on same img file -> maybe i have time for that tomorrow or within next week

You are trying to use the save/load feature with .img files, which is not intended to work. This is because every change made to the image filesystem requires storing the entire changed image, so it will not work. Instead, you should use qcow2 images. Once your bundle is ready, you need to apply sockdrive on top of it, as explained here: https://js-dos.com/publish-sockdrive-bundle.html

This is the only way to make larger images work with saves. Also, I wonder why you created your own Win95.img. I highly recommend using one of the pre-created bundles from js-dos. Please read this documentation: https://js-dos.com/jsdos-bundle.html

caiiiycuk avatar Aug 24 '25 11:08 caiiiycuk

mh, currently i have problems getting sockdrive to work -> i guess i need CPU v-Flag -> but my hoster doesnt allow that for my KVM

YET it kind of works now -> i used a 966mb HDD, installed Windows 95 + DX5.2 + Game -> could save several times (round 1, 10 and 50) without problem // 2GB is to big for that -> as we are limited by array-length

Benman2785 avatar Aug 25 '25 22:08 Benman2785

mh, currently i have problems getting sockdrive to work -> i guess i need CPU v-Flag -> but my hoster doesnt allow that for my KVM

YET it kind of works now -> i used a 966mb HDD, installed Windows 95 + DX5.2 + Game -> could save several times (round 1, 10 and 50) without problem // 2GB is to big for that -> as we are limited by array-length

Sockdrive is pure static solution, you only need a linux pc to convert js bundles to sockdrive bundle and then you can serve it as static website

caiiiycuk avatar Aug 27 '25 07:08 caiiiycuk

ok - i try to install it when i have more time -> last 2 tries didnt work :/

Benman2785 avatar Aug 28 '25 08:08 Benman2785