-
-
Notifications
You must be signed in to change notification settings - Fork 177
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
Multiple Assertion Failed !! #755
Comments
Does it still happen if you remove: .on('end', function () {
console.log('Stream ended')
a();
}) Because the Since node 12, node calls finalizers on process exit and we've yet to implement a proper hook to account for this (see #667 and nodejs/node#28428). Without such a hook we hit the |
@vweevers as suggested ran by removing on "end" event still fails, additionally tried it on Mac as well with node 12.18.3 still fails with same assertions.. A creepy workaround that i found was to give some time before exiting node process by using setTimeout of 5 seconds which exits normally... i think there are some events in node loop which are not processed when the process exits immediately... |
That's not good. Does it also happen if you replace |
Ok this is interesting, using level package doesn't give this problem both are at 6.0.1 version... |
I'm getting the same errors on Windows 10 with leveldown 5.6.0 (no level-party) In my system it happens during "createReadStream" but not right away, it seems to happen a random time after the stream was opened and a few items were returned. Also I tried adding a delay before the call to createReadStream because I had a feeling it was a timing problem but that has the effect that the process dies silently instead of producing the assertion errors. EDIT: the above may be a red herring. I downgraded leveldown, levelup and encoding-down to be exactly the same between the newer and older version of my application and still the newer version exposes the problem when reading the db from the older one for the first time. |
I've rebuild leveldown (5.6.0) so I get pdbs and debugged this a bit. I can trigger the crash fairly reliable in my environment but I can't really say what'd be necessary to reproduce it, if I can provide any more information that would help I'd be happy to do so. EDIT: ooof, this was quite a bit more trivial than I thought. So what happens is that during the upgrade from the old version of my application to the new one it restarts itself. This happens asynchronously and it just so happens that the db stream is still being read. This triggers - as described above - the iterator to be garbage collected before the stream is done reading which in turn triggers the |
Would this behavior be triggered when DB is empty? Say i said createstream for key range not existing? And for me why does level package work and not level-party is still a question 🤔 |
This brings the leveldown version to 6.1.0 which has fixes that could prevent an assert from happening in leveldb. Level/leveldown#783 Level/leveldown#755
I am using
node runtime 12.20.0 & 12.18.3
on aWindows 10 & Mac 10.14.6
machine with following code, which is resulting in lot of Assertion Failed Messages:Message 1: Assertion Failed at binding.cc @ 545
Message 2:Assertion Failed at version_set.cc @ 798
The text was updated successfully, but these errors were encountered: