mirror of
https://github.com/appy-one/acebase.git
synced 2026-05-25 06:02:14 -06:00
[GH-ISSUE #68] Error when invoking .set function #49
Labels
No labels
IndexedDB
browser
bug
dependencies
documentation
duplicate
enhancement
feature request
indexes
indexes
invalid
pull-request
query
question
transaction logging
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/acebase#49
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @paradis-A on GitHub (Feb 6, 2022).
Original GitHub issue: https://github.com/appy-one/acebase/issues/68
Feel free to close this if irrelevant. Mentioning possible fix.
[test] Index build /bounds//search_field (fulltext) started
[test] Reading node "/" from address 0,0
[test] Node "/" being updated: adding 1 keys ("bounds"), updating 0 keys (), removing 0 keys ()
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v/search_field" saved at address 0,17 - 1 addresses, 68 bytes written in 1 chunk(s)
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v" saved at address 0,18 - 2 addresses, 144 bytes written in 1 chunk(s)
[test] Node "/bounds" saved at address 0,20 - 1 addresses, 38 bytes written in 1 chunk(s)
[test] Node "/" saved at address 0,0 - 1 addresses, 34 bytes written in 1 chunk(s)
[test] Reading node "/bounds/ckzavyllh000b3p61u4fhbn8v" from address 0,18
[test] Reading node "/bounds/ckzavyllh000b3p61u4fhbn8v" from address 0,18
[test] Reading node "/bounds/ckzavyllh000b3p61u4fhbn8v/search_field" from address 0,17
[test] Can't find event subscriptions to stop (path: "bounds/ckzavyllh000b3p61u4fhbn8v", event: (any), callback: undefined)
[test] Reading node "/bounds/ckzavyllh000b3p61u4fhbn8v/search_field" from address 0,17
[test] Indexed "/bounds/ckzavyllh000b3p61u4fhbn8v/search_field" value: 'ckzavyllh000b3p61u4fhbn8v,stockpileinboundtresttres' (object)
[test] done writing values to ./test.acebase/bounds-search_field.fulltext.idx.build
{ key: 'ckzavylli000c3p613rorwn7x', cost: 1500, quantity: 1 }
[test] Index build /bounds//materials//key started
[test] Index build /bounds//materials/*/search_field (fulltext) started
[test] Reading node "/bounds/ckzavyllh000b3p61u4fhbn8v" from address 0,18
[test] done writing build file ./test.acebase/bounds-search_field.fulltext.idx.build
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v" being updated: adding 1 keys ("materials"), updating 0 keys (), removing 0 keys ()
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v/materials/ckzavylli000c3p613rorwn7x" saved at address 0,21 - 1 addresses, 113 bytes written in 1 chunk(s)
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v/materials" saved at address 0,22 - 1 addresses, 38 bytes written in 1 chunk(s)
[test] Node "/bounds/ckzavyllh000b3p61u4fhbn8v" saved at address 0,18 - 2 addresses, 154 bytes written in 1 chunk(s)
C:\System\lenlen\lendb-server\node_modules\acebase\src\api-local.js:728
typeof oldValue === 'object' && Object.keys(oldValue).forEach(key => !seenKeys.includes(key) && seenKeys.push(key));
^
TypeError: Cannot convert undefined or null to object
at Function.keys ()
at Object.childChangedCallback [as callback] (C:\System\lenlen\lendb-server\node_modules\acebase\src\api-local.js:728:60)
at C:\System\lenlen\lendb-server\node_modules\acebase\src\storage.js:494:25
at Array.forEach ()
at Object.trigger (C:\System\lenlen\lendb-server\node_modules\acebase\src\storage.js:493:18)
at C:\System\lenlen\lendb-server\node_modules\acebase\src\storage.js:1066:51
at Array.forEach ()
at triggerAllEvents (C:\System\lenlen\lendb-server\node_modules\acebase\src\storage.js:1012:14)
at processTicksAndRejections (internal/process/task_queues.js:75:11)
[nodemon] app crashed - waiting for file changes before starting...
@appy-one commented on GitHub (Feb 6, 2022):
Thanks for your report and pull request, really appreciate it!
I do think this is a duplicate of #61 however
While your fix will definitely prevent the error, it does not fix the issue at hand. The main reason for this is because the event handler is expecting data to be delivered, but
notify_child_changedevent handlers do (and should) not get any data. As I've mentioned in the other issue, changing thenotify_child_changedtochild_changedsubscription should be the right fix for now.@appy-one commented on GitHub (Feb 21, 2022):
Fix for this is published with acebase version 1.15.0
@paradis-A commented on GitHub (Feb 22, 2022):
I confirm bug is now fixed. Closing this now.