-
Notifications
You must be signed in to change notification settings - Fork 22
Display NotImplementedBlock when an unknown block type is encountered #1228
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
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1228 +/- ##
=======================================
Coverage 74.42% 74.42%
=======================================
Files 66 66
Lines 4520 4520
=======================================
Hits 3364 3364
Misses 1156 1156 🚀 New features to boost your workflow:
|
datalab
|
Project |
datalab
|
Branch Review |
bc/unknow-blocktype
|
Run status |
|
Run duration | 07m 38s |
Commit |
|
Committer | Ben Charmes |
View all properties for this run ↗︎ |
Test results | |
---|---|
|
0
|
|
0
|
|
0
|
|
0
|
|
504
|
View all changes introduced in this branch ↗︎ |
6018322
to
e3fef71
Compare
e3fef71
to
fae15d6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @BenjaminCharmes, I've struggled a bit to get this working locally, I seem to just hit can't access property "attributes", $options.blockInfo is undefined
every time and it doesn't seem to put any block_implementation_errors
in the store. Does it still work for you locally?
I didn't manage to reproduce your issue, and everything still works for me locally. But I've added an extra verification if blockInfo is undefined, which should solve your issue. If it still doesn't work, we can discuss it. |
Still not quite working for me, let's catch up on it next week! |
I'm not sure what the desired behaviour is, when loading a sample with a block not defined in resources.js it loads a default bokehblock and doesn't throw any errors. Weirdly to test this when I removed the blocks from resources.js they still appeared in the dropdown menu as available blocks, even when they simply defaulted to a bokeh block after I created them. |
915e701
to
0f69c1b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what the desired behaviour is, when loading a sample with a block not defined in resources.js it loads a default bokehblock and doesn't throw any errors.
Weirdly to test this when I removed the blocks from resources.js they still appeared in the dropdown menu as available blocks, even when they simply defaulted to a bokeh block after I created them.
resources.js
is now only used as an override for custom components, the web app will try to show any block defined in /info/blocks
so to test out this PR you have to make a block that is not defined there.
My previous problem seems to have gone away and this now works nicely for me, so I'm going to merge! Thanks @BenjaminCharmes!
Closes #1159
Could also add an alert from #1212 when an unknow block type is ancountered