question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Custom extensions cannot import models/widgets/widget

See original GitHub issue

As part of panel we are shipping various custom models, generally that works perfectly but it seems when I export a plot containing custom models to a static HTML file it fails to resolve certain modules, specifically this line raises errors:

      var widget_1 = require("models/widgets/widget"); 

while other imports seem to work just fine, e.g.:

      var p = require("core/properties");

I’m really not quite sure how best to provide a minimal reproducible example, so here is the exported HTML file, here is the custom model definition and here is the traceback:

Uncaught Error: Cannot find module 'models/widgets/widget'
    at s (Panel.html:93)
    at Object.custom/panel.models.widgets.audio (Panel.html:358)
    at s (Panel.html:93)
    at Object.custom/main (Panel.html:147)
    at s (Panel.html:93)
    at Object.t.Bokeh.r.register_plugin (Panel.html:93)
    at outer (Panel.html:137)
    at Panel.html:142
    at Panel.html:132
    at Panel.html:133

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:14 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
mattpapcommented, Mar 15, 2019

Actually I’m finishing a PR right now.

0reactions
philippjfrcommented, Mar 15, 2019

You’re amazing!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bokeh Custom Extension Issues - python - Stack Overflow
After all bokeh.models.sources. ... I did here for anyone who is new to creating custom extensions and is having trouble finding a solution....
Read more >
Troubleshooting custom widget extension import errors ... - PTC
Common errors when importing custom widget extensions; Error importing: error: Not Acceptable - [package: GoogleWidgets_ExtensionPackage, error: Source ...
Read more >
Error: Model 'Div' does not exist. This could be due to a widget ...
Hello, Bokeh widgets including Div, PreText, and Paragraph are not rendering in a jupyter notebook in VS Code or a browser.
Read more >
Merge request widget extensions - GitLab Docs
Extensions in the merge request widget enable you to add new features into the merge ... Register the imported extension registerExtension(issueExtension); ...
Read more >
Getting started building widgets ‒ Qlik Sense for developers
Use only HTML and CSS/LESS in your widgets. If you must use JavaScript code to create your custom visualization object, build a visualization...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found