-
Notifications
You must be signed in to change notification settings - Fork 17
Update xtensor-zarr=0.0.7 #43
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
Update xtensor-zarr=0.0.7 #43
Conversation
47ebe85
to
6b47a4f
Compare
Trigger CI |
The error is related to zarr.js:
Maybe @manzt has some ideas? |
Looks like a node version? No sure when/where that changed. The experimental warning is like from node pre-14. Ideally it should be node v15. I can take a closer look later today. |
Thanks, maybe adding the |
Can reproduce locally with $ fnm use 12 # change node version
Using Node v12.19.1
$ npm start
> @ start /Users/fm813/github/manzt/zarr_implementations/generate_data/js
> node src/index.js
(node:43251) ExperimentalWarning: The ESM module loader is experimental.
file:///Users/fm813/github/manzt/zarr_implementations/generate_data/js/src/index.js:3
import { PNG } from "pngjs";
^^^
SyntaxError: The requested module 'pngjs' is expected to be of type CommonJS, which does not support named exports. CommonJS modules can be imported by importing the default export.
For example:
import pkg from 'pngjs';
const { PNG } = pkg;
at ModuleJob._instantiate (internal/modules/esm/module_job.js:97:21)
at async ModuleJob.run (internal/modules/esm/module_job.js:143:20)
at async Loader.import (internal/modules/esm/loader.js:182:24)
at async Object.loadESM (internal/process/esm_loader.js:84:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ start: `node src/index.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/fm813/.npm/_logs/2021-05-01T13_02_24_462Z-debug.log on 15, $ fnm use 15
Using Node v15.6.0
$ npm start
> start
> node src/index.js # no errors |
@manzt I worked around the older version of npm, but I'm not sure if the changes would be acceptable to you.
|
@davidbrochart, this has to deal with how modules written for a legacy module system (common-js) are loaded in Node & browser as more modern ES modules. ESM is experimental in Node 12, but the changes you've made are supported in 12 and later. Totally acceptable – thanks! |
I'd suspect due to zarr-developers/zarr-python#729 |
6ec0fa1
to
09080d3
Compare
agreed. it should be fixed again after zarr-developers/zarr-python#709 is finished |
This branch works locally with zarr 2.8.3 if you want to bump |
09080d3
to
c8f78ad
Compare
environment.yml
Outdated
@@ -6,16 +6,14 @@ dependencies: | |||
- maven | |||
- make | |||
- cmake | |||
- xtensor-zarr=0.0.4 | |||
- xtensor-zarr=0.0.7=*_1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this also be >=
? Otherwise, 🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed it to >=0.0.8|=0.0.7=*_1
.
c8f78ad
to
7b00c0e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks ready to me (trusting @manzt's review of the JS changes)
No description provided.