-
Notifications
You must be signed in to change notification settings - Fork 1
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
TypeError: Cannot read property 'map' of undefined #5
Comments
I think this should be fixed in the latest alphas. |
I have tried, but unfortunately not. Am I doing something wrong? Maybe using some global package/node/npm instead of the local ones? $ node --version
v16.3.0
$ npm --version
7.18.1
$ npm list imba
ssr-app-imba@ /home/sebastian/develop/imba/ssr-app-imba
└── imba@2.0.0-alpha.145
$ sudo -H npm list imba
ssr-app-imba@ /home/sebastian/develop/imba/ssr-app-imba
└── imba@2.0.0-alpha.145
$ sudo npm list imba
ssr-app-imba@ /home/sebastian/develop/imba/ssr-app-imba
└── imba@2.0.0-alpha.145
$ npm -g list imba
/home/sebastian/.npm/lib
└── imba@2.0.0-alpha.145
$ sudo -H npm -g list imba
/usr/lib
└── imba@2.0.0-alpha.145
$ sudo npm -g list imba
/usr/lib
└── imba@2.0.0-alpha.145 $ npm start
> start
> imba src/http.imba
> node_modules/imba/bin/imba.imba.js:16186:27: error: [imba] Cannot read property 'map' of undefined
16186 │ errors: res.errors.map(function(_0) {
╵ ^
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28
at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)
at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30)
node_modules/imba/bin/imba.imba.js:16170:15: note: This error came from the "onLoad" callback registered here
16170 │ return esb.onLoad({filter: /\.imba1?$/}, async function({path, namespace}) {
╵ ~~~~~~
at Bundle.plugin (/home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16170:16)
at handlePlugins (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:686:7)
at Object.buildOrServe (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:903:44)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1444:17
at new Promise (<anonymous>)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1443:14)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1334:51)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16219:41
at processTicksAndRejections (node:internal/process/task_queues:96:5)
node_modules/imba/src/imba/imba.imba:12:14: note: The plugin "imba" was triggered by this import
12 │ export * from './dom/styles';
╵ ~~~~~~~~~~~~~~
> node_modules/imba/bin/imba.imba.js:16186:27: error: [imba] Cannot read property 'map' of undefined
16186 │ errors: res.errors.map(function(_0) {
╵ ^
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28
at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)
at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30)
node_modules/imba/bin/imba.imba.js:16170:15: note: This error came from the "onLoad" callback registered here
16170 │ return esb.onLoad({filter: /\.imba1?$/}, async function({path, namespace}) {
╵ ~~~~~~
at Bundle.plugin (/home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16170:16)
at handlePlugins (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:686:7)
at Object.buildOrServe (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:903:44)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1444:17
at new Promise (<anonymous>)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1443:14)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1334:51)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16219:41
at processTicksAndRejections (node:internal/process/task_queues:96:5)
node_modules/imba/src/imba/process.imba:11:16: note: The plugin "imba" was triggered by this import
11 │ import log from '../utils/logger'/*$path$*/;
╵ ~~~~~~~~~~~~~~~~~
× failed with 2 errors [
{
detail: TypeError: Cannot read property 'map' of undefined
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28
at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)
at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30),
location: {
column: 27,
file: 'node_modules/imba/bin/imba.imba.js',
length: 0,
line: 16186,
lineText: ' errors: res.errors.map(function(_0) {\n' +
' at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28\n' +
' at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)\n' +
' at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30)',
namespace: 'file'
},
notes: [ [Object], [Object] ],
text: "[imba] Cannot read property 'map' of undefined"
},
{
detail: TypeError: Cannot read property 'map' of undefined
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28
at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)
at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30),
location: {
column: 27,
file: 'node_modules/imba/bin/imba.imba.js',
length: 0,
line: 16186,
lineText: ' errors: res.errors.map(function(_0) {\n' +
' at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28\n' +
' at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)\n' +
' at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30)',
namespace: 'file'
},
notes: [ [Object], [Object] ],
text: "[imba] Cannot read property 'map' of undefined"
}
]
> node_modules/imba/bin/imba.imba.js:16186:27: error: [imba] Cannot read property 'map' of undefined
16186 │ errors: res.errors.map(function(_0) {
╵ ^
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16186:28
at async callback (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:772:28)
at async handleRequest (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:603:30)
node_modules/imba/bin/imba.imba.js:16170:15: note: This error came from the "onLoad" callback registered here
16170 │ return esb.onLoad({filter: /\.imba1?$/}, async function({path, namespace}) {
╵ ~~~~~~
at Bundle.plugin (/home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16170:16)
at handlePlugins (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:686:7)
at Object.buildOrServe (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:903:44)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1444:17
at new Promise (<anonymous>)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1443:14)
at Object.build (/home/sebastian/develop/imba/ssr-app-imba/node_modules/esbuild/lib/main.js:1334:51)
at /home/sebastian/develop/imba/ssr-app-imba/node_modules/imba/bin/imba.imba.js:16219:41
at processTicksAndRejections (node:internal/process/task_queues:96:5)
node_modules/imba/src/imba/imba.imba:12:14: note: The plugin "imba" was triggered by this import
12 │ export * from './dom/styles';
╵ ~~~~~~~~~~~~~~ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I installed as instructed and tried to start with:
./node_modules/imba/bin/imba -w src/express.imba
and my global imbaimba -w src/express.imba
The text was updated successfully, but these errors were encountered: