Assert failure: no null #5
Labels
No labels
dependencies
javascript
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
quodatum/basex-node#5
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?
Some of my execute calls fail at the "no null" assertion at line 128 in index.js. I tried changing the code to take the entire buffer if there is no null but then I get a different bug where it can't find the callback - I'll see what's going on there. Here's what I tried:
I was wondering if you had any idea what might be going on "under the hood". Seems the xquery calls work fine in the BaseX client (although there are quite a few and I'll need to test them all).
OK, I just figured it out and have a fix. Will send it your way in a sec.
Seems the npm version is out of date...
I am aware of this problem. It is due to the nature of Node and async buffers. Some of code is not properly testing that the entire message it wants to parse is available. The latest code has a better, approach to the problem (parser.js) BUT it is not yet implemented everywhere. It may not fix your problem, but I am working on it.
OK thanks Andy. When you manage to get it implemented, can you update the npm package and let us know? My fix is working fine for now but looking at what you've done here, I'd like to use your implementation eventually.
Oh an in case anyone else needs my quick fix, this should be the first two lines of the "parser1" function:
I have published version 0.5.1 to npm. It should fix this issue. Please let me know if it works for you.
OK great. I'll give it a go tomorrow. I already tried a more recent version today and it worked great so I imagine I won't have any trouble.
Gave it a go today and it's working great. Thanks Andy!