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

jaylydb: TypeError: cannot read property 'type' of undefined #334

Open
Corosauce opened this issue Nov 10, 2023 · 0 comments
Open

jaylydb: TypeError: cannot read property 'type' of undefined #334

Corosauce opened this issue Nov 10, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@Corosauce
Copy link

Corosauce commented Nov 10, 2023

Describe the bug

Went afk to let the game run, came back to this error.

19:16:38[Scripting][error]-TypeError: cannot read property 'type' of undefined at updateParticipants (jaylydb/index.js:108) at <anonymous> (jaylydb/index.js:223)

My code isn't doing anything too complicated, every 2 seconds its writing out a list of objects and their values to the database, without revealing too much it looks roughly like this.

Scoreboard with its data bits looking like:

image

Code:

db init:
this.db = new JaylyDB(dbName);

code that iterates over some objects:

var index: number = 0; for (const object of this.objects) { object.save(index, this.db); index++; }

the object:

save(index: number, db: JaylyDB) { db.set(index + "_posX", this.pos.x); db.set(index + "_posY", this.pos.y); db.set(index + "_posZ", this.pos.z); }

Using version 1.1.3

Updates

Seems very intermittent, cannot reproduce reliably.

I went to run /script profiler start and was met with massive spam of the same error, but not the second time after a /reload

@Corosauce Corosauce added the bug Something isn't working label Nov 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant