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

Python class not being generated #1

Closed
rohitranjan017 opened this issue Apr 6, 2022 · 4 comments · Fixed by #3
Closed

Python class not being generated #1

rohitranjan017 opened this issue Apr 6, 2022 · 4 comments · Fixed by #3

Comments

@rohitranjan017
Copy link

Even after npm build run, the python class is not being generated in the example_component directory. I can see the example_component.js file but no ExampleComponent.py . How to import the React component and run the python dash application?

@rohitranjan017
Copy link
Author

@T4rk1n , I realized the python class is not being generated because metadata.json file is empty. Could you please suggest why is that and what could be a workaround for it?

@b-long
Copy link

b-long commented Apr 28, 2022

I wonder if this is still a valid issue. I haven't seen a new release of Dash, but I did notice that this is merged plotly/dash#1956 .

@Jordan-Hall
Copy link
Contributor

I wonder if this is related pip install error im getting

(venv) C:\dev\clients\madetech\gov_uk_dash_components>pip install -r requirements.txt     
Collecting dash[dev]
  Cloning https://github.com/plotly/dash.git (to revision typescript-component-generator) to c:\users\libert~1\appdata\local\temp\pip-install-7c_agz67\dash_11e4957ed35f4091bdc101aef9930efe
  Running command git clone --filter=blob:none --quiet https://github.com/plotly/dash.git 'C:\Users\LIBERT~1\AppData\Local\Temp\pip-install-7c_agz67\dash_11e4957ed35f4091bdc101aef9930efe'
  hint: core.useBuiltinFSMonitor will be deprecated soon; use core.fsmonitor instead
  hint: Disable this message with "git config advice.useCoreFSMonitorConfig false"
  WARNING: Did not find branch or tag 'typescript-component-generator', assuming revision or ref.
  Running command git checkout -q typescript-component-generator
  hint: core.useBuiltinFSMonitor will be deprecated soon; use core.fsmonitor instead
  hint: Disable this message with "git config advice.useCoreFSMonitorConfig false"
  error: pathspec 'typescript-component-generator' did not match any file(s) known to git
  error: subprocess-exited-with-error
  
  × git checkout -q typescript-component-generator did not run successfully.
  │ exit code: 1
  ╰─> See above for output.

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× git checkout -q typescript-component-generator did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

@Jordan-Hall
Copy link
Contributor

@b-long @rohitranjan017

I've just changed the requirements.txt file to the following:

git+https://github.com/plotly/dash@dev#egg=dash[dev]
wheel
build

This solved all issues for me and appears to build ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants