You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
failing test: src/test/local.e2etest.ts:1:468 - Unminifies an example file successfully - AssertionError [ERR_ASSERTION]: Expected "UNREADABLE" but got GOOD #384
✖ failing tests:
test at src/test/local.e2etest.ts:1:468
✖ Unminifies an example file successfully (10744.814553ms)
AssertionError [ERR_ASSERTION]: Expected "UNREADABLE" but got GOOD
The functiongiven performs a task that appears to split a given string (`e`) into chunks of a specified size (`t`)
at expectStartsWith (/Users/devalias/dev/jehna/humanify/src/test/local.e2etest.ts:24:5)
at TestContext.<anonymous> (/Users/devalias/dev/jehna/humanify/src/test/local.e2etest.ts:30:9)
at async Test.run (node:internal/test_runner/test:866:9)
at async Test.processPendingSubtests (node:internal/test_runner/test:574:7) {
generatedMessage: false,
code: 'ERR_ASSERTION',
actual: false,
expected: true,
operator: '=='
}
This test was failing within node-llama-cpp update PR's for a long time:
Because it was failing, the automerge github action refused to merge the PR; but for some reason, this latest PR was merged, and now the code on the main branch fails on this test.
I haven't had a chance to debug more specifically what changed between the last version of node-llama-cpp that worked, and the version it started breaking in, but I suspect it has something to do with the specifics of the Gbnf grammar/similar that's used to constrain the models output.
The following links may be relevant for understanding if/what changes need to be made to the Gbnf grammar (or other ways to achieve similar):
Interesting that this upgrade was able to run the tests and merge successfully when it's been failing for so long prior.. I wonder what the root issue was, and what fixed it; as looking at the main commits in this repo, it doesn't look like the tests were fixed/etc at all.
Background context:
See my previous exploration/analysis into this build failure in the following comments:
⇒ npm install humanifyjs
npm warn deprecated npmlog@6.0.2: This package is no longer supported.
npm warn deprecated are-we-there-yet@3.0.1: This package is no longer supported.
npm warn deprecated gauge@4.0.4: This package is no longer supported.
Actually.. cloning locally (7beba2d) and running npm test seems to fail with the same error as previously:
⇒ npm test
..snip..
> humanifyjs@2.2.2 test:e2e
> npm run build && find src -name '*.e2etest.ts' | xargs tsx --test --test-concurrency=1
..snip..
✖ failing tests:
test at src/test/local.e2etest.ts:1:468
✖ Unminifies an example file successfully (10744.814553ms)
AssertionError [ERR_ASSERTION]: Expected "UNREADABLE" but got GOOD
The function given performs a task that appears to split a given string (`e`) into chunks of a specified size (`t`)
at expectStartsWith (/Users/devalias/dev/jehna/humanify/src/test/local.e2etest.ts:24:5)
at TestContext.<anonymous> (/Users/devalias/dev/jehna/humanify/src/test/local.e2etest.ts:30:9)
at async Test.run (node:internal/test_runner/test:866:9)
at async Test.processPendingSubtests (node:internal/test_runner/test:574:7) {
generatedMessage: false,
code: 'ERR_ASSERTION',
actual: false,
expected: true,
operator: '=='
}
So this seems like it never should have passed and been able to be merged.. probably a race condition/similar bug in the automerge GitHub action that likely would be resolved by the improvements raised in:
This test has started failing in
mainsince this PR bumpingnode-llama-cppwas auto-merged:This test was failing within
node-llama-cppupdate PR's for a long time:Which I started looking into in this comment:
Because it was failing, the automerge github action refused to merge the PR; but for some reason, this latest PR was merged, and now the code on the
mainbranch fails on this test.I haven't had a chance to debug more specifically what changed between the last version of
node-llama-cppthat worked, and the version it started breaking in, but I suspect it has something to do with the specifics of theGbnfgrammar/similar that's used to constrain the models output.The following links may be relevant for understanding if/what changes need to be made to the
Gbnfgrammar (or other ways to achieve similar):Background Context