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

Remove/update deprecated/unsupported packages #52

Open
0xdevalias opened this issue Aug 23, 2024 · 2 comments
Open

Remove/update deprecated/unsupported packages #52

0xdevalias opened this issue Aug 23, 2024 · 2 comments

Comments

@0xdevalias
Copy link
Contributor

0xdevalias commented Aug 23, 2024

⇒ node --version
v22.6.0

⇒ npm --version
10.8.2
⇒ npm install humanifyjs
npm warn deprecated [email protected]: This package is no longer supported.
npm warn deprecated [email protected]: This package is no longer supported.
npm warn deprecated [email protected]: This package is no longer supported.
⇒ NODE_OPTIONS="--trace-deprecation" npx humanifyjs -h
(node:95592) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
    at node:punycode:3:9
    at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7)
    at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10)
    at loadBuiltinModule (node:internal/modules/helpers:98:7)
    at Module._load (node:internal/modules/cjs/loader:1099:17)
    at TracingChannel.traceSync (node:diagnostics_channel:315:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:217:24)
    at Module.require (node:internal/modules/cjs/loader:1339:12)
    at require (node:internal/modules/helpers:125:16)
    at Object.<anonymous> (/Users/devalias/dev/foohumanify/node_modules/whatwg-url/lib/url-state-machine.js:2:18)

⇒ npm why npmlog
[email protected]
node_modules/npmlog
  npmlog@"^6.0.2" from [email protected]
  node_modules/cmake-js
    cmake-js@"^7.3.0" from [email protected]
    node_modules/node-llama-cpp
      node-llama-cpp@"^3.0.0-beta.40" from [email protected]
      node_modules/humanifyjs
        humanifyjs@"^2.1.0" from the root project
⇒ npm why are-we-there-yet
[email protected]
node_modules/are-we-there-yet
  are-we-there-yet@"^3.0.0" from [email protected]
  node_modules/npmlog
    npmlog@"^6.0.2" from [email protected]
    node_modules/cmake-js
      cmake-js@"^7.3.0" from [email protected]
      node_modules/node-llama-cpp
        node-llama-cpp@"^3.0.0-beta.40" from [email protected]
        node_modules/humanifyjs
          humanifyjs@"^2.1.0" from the root project
⇒ npm why gauge
[email protected]
node_modules/gauge
  gauge@"^4.0.3" from [email protected]
  node_modules/npmlog
    npmlog@"^6.0.2" from [email protected]
    node_modules/cmake-js
      cmake-js@"^7.3.0" from [email protected]
      node_modules/node-llama-cpp
        node-llama-cpp@"^3.0.0-beta.40" from [email protected]
        node_modules/humanifyjs
          humanifyjs@"^2.1.0" from the root project
⇒ npm why whatwg-url
[email protected]
node_modules/whatwg-url
  whatwg-url@"^5.0.0" from [email protected]
  node_modules/node-fetch
    node-fetch@"^2.6.7" from [email protected]
    node_modules/openai
      openai@"^4.55.1" from [email protected]
      node_modules/humanifyjs
        humanifyjs@"^2.1.0" from the root project
@0xdevalias
Copy link
Contributor Author

0xdevalias commented Feb 25, 2025

RE: This error:

⇒ NODE_OPTIONS="--trace-deprecation" npx humanifyjs -h
(node:95592) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
    at node:punycode:3:9
    at BuiltinModule.compileForInternalLoader (node:internal/bootstrap/realm:399:7)
    at BuiltinModule.compileForPublicLoader (node:internal/bootstrap/realm:338:10)
    at loadBuiltinModule (node:internal/modules/helpers:98:7)
    at Module._load (node:internal/modules/cjs/loader:1099:17)
    at TracingChannel.traceSync (node:diagnostics_channel:315:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:217:24)
    at Module.require (node:internal/modules/cjs/loader:1339:12)
    at require (node:internal/modules/helpers:125:16)
    at Object.<anonymous> (/Users/devalias/dev/foohumanify/node_modules/whatwg-url/lib/url-state-machine.js:2:18)

Which comes from the openai package:

⇒ npm why whatwg-url
[email protected]
node_modules/whatwg-url
  whatwg-url@"^5.0.0" from [email protected]
  node_modules/node-fetch
    node-fetch@"^2.6.7" from [email protected]
    node_modules/openai
      openai@"^4.55.1" from [email protected]
      node_modules/humanifyjs
        humanifyjs@"^2.1.0" from the root project

Here's some updates on the timeline as to when node-fetch will no longer be included in it, which I believe will resolve this error:

seems that openai is still using node-fetch, so it might not work

Related upstream issues / workarounds for node-fetch not supporting HTTP_PROXY / etc:

Originally posted by @0xdevalias in #265 (comment)

@0xdevalias
Copy link
Contributor Author

0xdevalias commented Feb 25, 2025

RE: These deprecated warnings that all come from [email protected]:

⇒ npm install humanifyjs
npm warn deprecated [email protected]: This package is no longer supported.
npm warn deprecated [email protected]: This package is no longer supported.
npm warn deprecated [email protected]: This package is no longer supported.

Solving the build error in this package bump would likely allow us to resolve this issue:

See my previous exploration/analysis into the build failures for that dependency upgrade in the following comments:

It's been failing for quite a while now:

Looking at the pull request history for bumping node-llama-cpp:

It seems there has been test failures as far back as:

With the last successful upgrade being:

Using a script from my dotfiles to check the old PR checks, and whether they still have logs available:

Old PR Checks
⇒ gh-check-pr-test-logs-exist --repo jehna/humanify --dependabot 'node-llama-cpp' --workflow 'Test'
🔍 Using auto-generated Dependabot search query: 'Bump node-llama-cpp author:app/dependabot'

🔍 Fetching PRs in jehna/humanify (Search: 'Bump node-llama-cpp author:app/dependabot')...

📋 Matching PRs:
  PR #25: Bump node-llama-cpp from 3.0.0-beta.42 to 3.0.0-beta.44
  PR #110: Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0-beta.45
  PR #113: Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0-beta.46
  PR #119: Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0
  PR #123: Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.1
  PR #126: Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.3
  PR #148: Bump node-llama-cpp from 3.0.0-beta.44 to 3.1.1
  PR #194: Bump node-llama-cpp from 3.0.0-beta.44 to 3.2.0
  PR #235: Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.0
  PR #243: Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.1
  PR #259: Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.2
  PR #270: Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.0
  PR #289: Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.1
  PR #298: Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.2
  PR #301: Bump node-llama-cpp from 3.0.0-beta.44 to 3.5.0

🚀 Fetching workflow checks for each PR (workflow: 'Test')...
  📝 PR #25 - Bump node-llama-cpp from 3.0.0-beta.42 to 3.0.0-beta.44
    SUCCESS Run: 10342020426, Job: 28624470785, Completed: 2024-08-11T18:55:39Z, https://github.com/jehna/humanify/actions/runs/10342020426/job/28624470785
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/10342020426/job/28624470785

  📝 PR #110 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0-beta.45
    FAILURE Run: 10952237439, Job: 30410578743, Completed: 2024-09-20T02:44:38Z, https://github.com/jehna/humanify/actions/runs/10952237439/job/30410578743
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/10952237439/job/30410578743

  📝 PR #113 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0-beta.46
    FAILURE Run: 10986565195, Job: 30500102243, Completed: 2024-09-23T02:21:16Z, https://github.com/jehna/humanify/actions/runs/10986565195/job/30500102243
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/10986565195/job/30500102243

  📝 PR #119 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.0
    FAILURE Run: 11006198263, Job: 30560096048, Completed: 2024-09-24T03:07:11Z, https://github.com/jehna/humanify/actions/runs/11006198263/job/30560096048
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/11006198263/job/30560096048

  📝 PR #123 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.1
    FAILURE Run: 11025072536, Job: 30619327495, Completed: 2024-09-25T02:18:48Z, https://github.com/jehna/humanify/actions/runs/11025072536/job/30619327495
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/11025072536/job/30619327495

  📝 PR #126 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.0.3
    FAILURE Run: 11044698764, Job: 30681065017, Completed: 2024-09-26T02:57:16Z, https://github.com/jehna/humanify/actions/runs/11044698764/job/30681065017
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/11044698764/job/30681065017

  📝 PR #148 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.1.1
    FAILURE Run: 11411055050, Job: 31754595756, Completed: 2024-10-18T21:13:18Z, https://github.com/jehna/humanify/actions/runs/11411055050/job/31754595756
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/11411055050/job/31754595756

  📝 PR #194 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.2.0
    FAILURE Run: 11605087286, Job: 32314887872, Completed: 2024-10-31T02:37:10Z, https://github.com/jehna/humanify/actions/runs/11605087286/job/32314887872
    ❌ Logs expired/unavailable - 🔗 https://github.com/jehna/humanify/actions/runs/11605087286/job/32314887872

  📝 PR #235 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.0
    FAILURE Run: 12131715473, Job: 33824331143, Completed: 2024-12-03T02:29:45Z, https://github.com/jehna/humanify/actions/runs/12131715473/job/33824331143
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/12131715473/job/33824331143
    📋 View failed logs: gh run view 12131715473 --repo jehna/humanify --log-failed

  📝 PR #243 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.1
    FAILURE Run: 12228072358, Job: 34105732535, Completed: 2024-12-09T03:00:43Z, https://github.com/jehna/humanify/actions/runs/12228072358/job/34105732535
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/12228072358/job/34105732535
    📋 View failed logs: gh run view 12228072358 --repo jehna/humanify --log-failed

  📝 PR #259 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.2
    FAILURE Run: 12554593031, Job: 35003489033, Completed: 2024-12-31T02:37:09Z, https://github.com/jehna/humanify/actions/runs/12554593031/job/35003489033
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/12554593031/job/35003489033
    📋 View failed logs: gh run view 12554593031 --repo jehna/humanify --log-failed

  📝 PR #270 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.0
    FAILURE Run: 12663197159, Job: 35289351219, Completed: 2025-01-08T02:58:25Z, https://github.com/jehna/humanify/actions/runs/12663197159/job/35289351219
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/12663197159/job/35289351219
    📋 View failed logs: gh run view 12663197159 --repo jehna/humanify --log-failed

  📝 PR #289 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.1
    FAILURE Run: 12941994481, Job: 36098955172, Completed: 2025-01-24T02:26:22Z, https://github.com/jehna/humanify/actions/runs/12941994481/job/36098955172
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/12941994481/job/36098955172
    📋 View failed logs: gh run view 12941994481 --repo jehna/humanify --log-failed

  📝 PR #298 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.4.2
    FAILURE Run: 13002502354, Job: 36263639435, Completed: 2025-01-28T02:39:24Z, https://github.com/jehna/humanify/actions/runs/13002502354/job/36263639435
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/13002502354/job/36263639435
    📋 View failed logs: gh run view 13002502354 --repo jehna/humanify --log-failed

  📝 PR #301 - Bump node-llama-cpp from 3.0.0-beta.44 to 3.5.0
    FAILURE Run: 13065242932, Job: 36456364632, Completed: 2025-01-31T02:32:51Z, https://github.com/jehna/humanify/actions/runs/13065242932/job/36456364632
    ✅ Logs exist: https://github.com/jehna/humanify/actions/runs/13065242932/job/36456364632
    📋 View failed logs: gh run view 13065242932 --repo jehna/humanify --log-failed

The oldest PR that still does have test error logs available seems to be:

  • Bump node-llama-cpp from 3.0.0-beta.44 to 3.3.0 #235
    • https://github.com/jehna/humanify/actions/runs/12131715473/job/33824331143
      • ..snip..
        
        # [2024-12-03 02:28:15]  Loading model with options {
        #   modelPath: '/Users/runner/.humanifyjs/models/Phi-3.1-mini-4k-instruct-Q4_K_M.gguf',
        #   gpuLayers: 0
        # }
        # Subtest: Unminifies an example file successfully
        not ok 4 - Unminifies an example file successfully
          ---
          duration_ms: 87609.07725
          location: '/Users/runner/work/humanify/humanify/src/test/local.e2etest.ts:1:468'
          failureType: 'testCodeFailure'
          error: |-
            Expected "UNREADABLE" but got GOOD
            
            The provided function `a` appears to be a sublist generator for slicing a string or an array in JavaScript
          code: 'ERR_ASSERTION'
          name: 'AssertionError'
          expected: true
          actual: false
          operator: '=='
          stack: |-
            expectStartsWith (/Users/runner/work/humanify/humanify/src/test/local.e2etest.ts:24:5)
            TestContext.<anonymous> (/Users/runner/work/humanify/humanify/src/test/local.e2etest.ts:30:9)
            async Test.run (node:internal/test_runner/test:797:9)
            async Test.processPendingSubtests (node:internal/test_runner/test:527:7)
          ...
        1..4
        # tests 4
        # suites 0
        # pass 3
        # fail 1
        # cancelled 0
        # skipped 0
        # todo 0
        # duration_ms 125798.5[195](https://github.com/jehna/humanify/actions/runs/12131715473/job/33824331143#step:9:196)41
        Error: Process completed with exit code 1.
        

Looking at the CHANGELOG entry for the version that started breaking:


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):

Originally posted by @0xdevalias in #301 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant