'Uncaught Package not found fili' error when trying to use eeg-pipes 2.0.2 with muse-js example
tanvach opened this issue · 4 comments
I've been trying to use bufferFFT()
example code with muse-js example (link).
How to replicate the issue:
- Run
yarn add eeg-pipes
inmuse-js
directory - Add
import { bufferFFT, alphaPower } from "eeg-pipes";
to top ofmain.ts
file - After this line:
client.eegReadings.subscribe(reading => {console.log(reading);});
, addclient.eegReadings.pipe(bufferFFT({ bins: 256 }), alphaPower()).subscribe(buffer => console.log(buffer));
- Run
yarn start
and loadhttp://localhost:4445/
- Open js console and see
Uncaught Package not found fili
@jdpigeon suggested to use v1.x. I've found v1.2.0 would give Uncaught Package not found babel-runtime
error, but v1.1.0 seems to load fine.
We're taking a look at this. Can you confirm whether fili is in your project's node_modules
folder and in the list of modules returned by npm list --prod
?
Thank you, muse-js is using yarn
:
> yarn list --prod
yarn list v1.5.1
├─ @types/web-bluetooth@0.0.2
├─ dsp.js@1.0.1
├─ eeg-pipes@2.0.3
│ ├─ dsp.js@^1.0.1
│ ├─ fili@^2.0.1
│ ├─ rxjs@^5.5.2
│ └─ rxjs@5.5.10
│ └─ symbol-observable@1.0.1
├─ fili@2.0.1
├─ rxjs@6.0.0
│ └─ tslib@^1.9.0
├─ symbol-observable@1.0.1
└─ tslib@1.9.0
✨ Done in 0.53s
When I use npm install eeg-pipes
it would break yarn start
.
I double checked that indeed eeg-pipes
is in node_modules
For cleaner way to reproduce this, I've created a repo here https://github.com/tanvach/muse-fft
It's a simple react app that imports muse-js and eeg-pipes. You can run using the usual npm install
and npm start
. This time, It throws a more informative fili related error.
npm list --prod
output
> npm list --prod
muse-fft@0.1.0 /Users/tan_vachiramon/Codes/muse-fft
├── dsp.js@1.0.1
├─┬ eeg-pipes@2.0.3
│ ├── dsp.js@1.0.1 deduped
│ ├── fili@2.0.1 deduped
│ └── rxjs@5.5.2 deduped
├── fili@2.0.1
├─┬ muse-js@3.0.1
│ ├── @types/web-bluetooth@0.0.2
│ └─┬ rxjs@6.1.0
│ └── tslib@1.9.1
├─┬ react@16.3.2
...