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

Perspective-cli hosting error: input.on_delete is not a function #1405

Closed
mhkeller opened this issue Apr 29, 2021 · 1 comment · Fixed by #1419
Closed

Perspective-cli hosting error: input.on_delete is not a function #1405

mhkeller opened this issue Apr 29, 2021 · 1 comment · Fixed by #1419
Labels
bug Concrete, reproducible bugs good first issue A relatively simple issue JS

Comments

@mhkeller
Copy link

Bug Report

Steps to Reproduce:

  1. Install perspective-cli `npm install -g @finos/perspective-cli
  2. Create any csv file and run perspective host my-csv.csv Sample file:
name,value
a,2
b,2
c,4

Expected Result:

I expect it to host a server allowing me to see the data

Actual Result:

It shows this error:

Listening on port 8080
TypeError: input.on_delete is not a function
/usr/local/lib/node_modules/@finos/perspective-cli/node_modules/@finos/perspective/dist/cjs/@finos/perspective-cpp/dist/cjs/perspective.cpp.js:85
          throw ex;
          ^

RuntimeError: abort(TypeError: input.on_delete is not a function). Build with -s ASSERTIONS=1 for more info.
    at process.abort (/usr/local/lib/node_modules/@finos/perspective-cli/node_modules/@finos/perspective/dist/cjs/@finos/perspective-cpp/dist/cjs/perspective.cpp.js:700:15)
    at process.emit (events.js:314:20)
    at processPromiseRejections (internal/process/promises.js:209:33)
    at processTicksAndRejections (internal/process/task_queues.js:98:32)

Environment:

MacOs 10.15.7, node versions tested on 16.0.0 and 12.21.0

Additional Context:

I also tried installing @finso/perspective-cli as a local project dependency and running it with npx perspective host test.csv and it produced the same error.

@sc1f
Copy link
Contributor

sc1f commented Apr 30, 2021

This issue is due to a bitrot in perspective-cli—in v0.7.0 we updated the table and view API to be async, but when I went through and changed the constructors to the async form I must have missed the use of the table constructor in perspective-cli.

This would be a good first issue for somebody to look at; it's a pretty easy fix and offers a good springboard to familiarize oneself with the development steps for Perspective.

@sc1f sc1f added bug Concrete, reproducible bugs good first issue A relatively simple issue JS labels Apr 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Concrete, reproducible bugs good first issue A relatively simple issue JS
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants