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

v1.8.1 has become corrupted or missing on the npm repository #41

Open
geoidesic opened this issue Dec 3, 2022 · 4 comments
Open

v1.8.1 has become corrupted or missing on the npm repository #41

geoidesic opened this issue Dec 3, 2022 · 4 comments

Comments

@geoidesic
Copy link

Please could you republish it?
https://www.npmjs.com/package/timezone-support/v/1.8.1

@prantlf
Copy link
Owner

prantlf commented Dec 3, 2022

Are you sure, that you do not use an NPM proxy with an incomplete package database instead of npmjs.org?

Enquiring npmjs.org show that the version is available:

❯ npm get registry
https://registry.npmjs.org/

❯ npm v timezone-support@1.8.1
timezone-support@1.8.1 | MIT | deps: 1 | versions: 25
Lightweight time zone support for your applications or other date libraries.
https://github.com/prantlf/timezone-support#readme
...
dist
.tarball: https://registry.npmjs.org/timezone-support/-/timezone-support-1.8.1.tgz
.shasum: 0a8c04d0614be6fccdd2280aaad5072fa5d31e5f
.integrity: sha512-+pKzxoUe4PZXaQcswceJlA+69oRyyu1uivnYKdpsC7eGzZiuvTLbU4WYPqTKslEsoSvjN8k/u/6qNfGikBB/wA==
.unpackedSize: 20.9 MB
...
published over a year ago by prantlf <prantlf@gmail.com>

❯ npm pack timezone-support@1.8.1
npm notice
npm notice 📦  timezone-support@1.8.1
npm notice === Tarball Contents ===
npm notice 1.1kB   LICENSE
npm notice 6.0kB   README.md
npm notice 1.8kB   bin/create-timezone-data
...
npm notice total files:   78
npm notice
timezone-support-1.8.1.tgz

And installing it works too:

❯ npm init -y
Wrote to /Users/prantlf/test/package.json:
...

❯ npm i timezone-support@1.8.1 --save-exact
added 2 packages, and audited 3 packages in 626ms
found 0 vulnerabilities

❯ npm ls timezone-support
test@1.0.0 /Users/prantlf/test
└── timezone-support@1.8.1

@geoidesic
Copy link
Author

Try it with node v12 please?

I get this:

yarn install
yarn install v1.22.19
[1/5]   Validating package.json...
[2/5]   Resolving packages...
[3/5]   Fetching packages...
error An unexpected error occurred: "https://registry.yarnpkg.com/timezone-support/-/timezone-support-1.8.1.tgz: incorrect data check".
info If you think this is a bug, please open a bug report with the information provided in "/Users/noeldacosta/repo/gitlab/netbuilder/cpd/cpd-portal/client/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
noeldacosta@Noels-MacBook-M1-Pro client % npm get registry
https://registry.npmjs.org/
noeldacosta@Noels-MacBook-M1-Pro client % node -v
v12.22.12

@geoidesic
Copy link
Author

Using npm:

npm i timezone-support@1.8.1 --save-exact
npm ERR! code Z_DATA_ERROR
npm ERR! errno -3
npm ERR! zlib: incorrect data check

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/noeldacosta/.npm/_logs/2022-12-03T11_13_58_576Z-debug.log
noeldacosta@Noels-MacBook-M1-Pro client %

@prantlf
Copy link
Owner

prantlf commented Dec 3, 2022

I'm afraid that I can't reproduce it with Node.js 12.

You should consider upgrading to a supported Node.js version, preferably a LTS, but I doubt that this problem will disappear.

❯ node --version
v12.22.12

Using NPM:

❯ npm --version
6.14.16

❯ npm init -y
Wrote to /Users/prantlf/test/package.json:
...

❯ npm i timezone-support@1.8.1 --save-exact
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN test@1.0.0 No description
npm WARN test@1.0.0 No repository field.

+ timezone-support@1.8.1
added 2 packages from 3 contributors and audited 2 packages in 0.546s
found 0 vulnerabilities

❯ npm ls timezone-support
test@1.0.0 /Users/prantlf/test
└── timezone-support@1.8.1

Using yarn:

❯ yarn --version
1.22.19

❯ yarn init -y
yarn init v1.22.19
warning The yes flag has been set. This will automatically answer yes to all questions, which may have security implications.
success Saved package.json
✨  Done in 0.02s.

❯ yarn add timezone-support@1.8.1 --save-exact
yarn add v1.22.19
info No lockfile found.
[1/4] 🔍  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] 🔗  Linking dependencies...
[4/4] 🔨  Building fresh packages...
success Saved lockfile.
success Saved 2 new dependencies.
info Direct dependencies
└─ timezone-support@1.8.1
info All dependencies
├─ commander@2.19.0
└─ timezone-support@1.8.1
✨  Done in 0.44s.

❯ yarn list timezone-support
yarn list v1.22.19
warning Filtering by arguments is deprecated. Please use the pattern option instead.
└─ timezone-support@1.8.1
✨  Done in 0.05s.

You got an error "incorrect data check". It looks like a corrupted package archive. You could also try downloading and testing it:

❯ npm pack timezone-support@1.8.1
npm notice
npm notice 📦  timezone-support@1.8.1
...
npm notice total files:   78
npm notice
timezone-support-1.8.1.tgz

❯ tar tf timezone-support-1.8.1.tgz
package/package.json
...
package/util/generate-browser-tests.js
❯ curl -o tzs.tgz https://registry.yarnpkg.com/timezone-support/-/timezone-support-1.8.1.tgz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 1876k  100 1876k    0     0  3600k      0 --:--:-- --:--:-- --:--:-- 3622k

❯ tar tzf tzs.tgz
package/package.json
...
package/util/generate-browser-tests.js

You could also try cleaning the cache:

npm cache clean -f
yarn cache clean --all

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

2 participants