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

Blocks become immovable and glitch out in workspace editor in blockly developer tools. #7385

Open
1 task done
rylid-umil opened this issue Aug 13, 2023 · 15 comments
Open
1 task done
Labels
component: devtools issue: bug Describes why the code or behaviour is wrong size: small Bugs that can be picked up and completed in 1-3 days

Comments

@rylid-umil
Copy link

rylid-umil commented Aug 13, 2023

Check for duplicates

  • I have searched for similar issues before opening a new one.

Description

SO, basically, when i created new blocks with no color input, aka black, i noticed they wouldn't move when they were put in workspace, and has been happening to every custom-made block since then. Every single one.

Reproduction steps

  1. make block (any)
  2. place it on the workspace in workspace factory
  3. try moving it. you cant.

Stack trace

No response

Screenshots

2023-08-13 15-25-27

Browsers

firefox

@rylid-umil rylid-umil added issue: bug Describes why the code or behaviour is wrong issue: triage Issues awaiting triage by a Blockly team member labels Aug 13, 2023
@maribethb maribethb added component: devtools size: small Bugs that can be picked up and completed in 1-3 days and removed issue: triage Issues awaiting triage by a Blockly team member labels Aug 16, 2023
@rachel-fenichel
Copy link
Collaborator

Are there any errors in the console, either when you create the block or when you try to drag it?

@rylid-umil
Copy link
Author

i havne't checked, let me check real quick

@rylid-umil
Copy link
Author

i don't see any big errors, but i did discover the custom blocks have problems connecting, too.
image

@rylid-umil
Copy link
Author

its odd, but i made a new custom block and it works normally as expected

@rachel-fenichel
Copy link
Collaborator

The JSON.parse error is a big error: it means that the blocks are not being loaded properly, which could explain why everything locks up. That might be due to malformed JSON. You can clear your local storage to get rid of saved block definitions that might be loading wrong (although beware that this will delete all of your local custom blocks).

I don't recognize the TypeError or the following script that failed to load.

@rylid-umil
Copy link
Author

oh so i will have to delete all my hard work, nevermind

@rylid-umil
Copy link
Author

but then why did the new block i had just created not lock up?

@rachel-fenichel
Copy link
Collaborator

If you have enough local custom blocks that you don't want to delete, you can do something more involved to find the bad block and delete only it. The blocks are in local storage under BlockLibraryStorage.blockLibrary.

Chrome developer tools lets you interact with (and modify) your local storage.

However, you shouldn't do this until you figure out what the broken block is and how it is broken.

@rylid-umil
Copy link
Author

How do i find the bad block(s)?

@rylid-umil
Copy link
Author

also as i specified, i don't use Chrome

@rachel-fenichel
Copy link
Collaborator

rachel-fenichel commented Aug 21, 2023

Firefox's developer tools have very similar functionality. Here's the documentation on the storage inspector and local storage.

SO, basically, when i created new blocks with no color input, aka black, i noticed they wouldn't move when they were put in workspace, and has been happening to every custom-made block since then. Every single one.

The new block with no color input is probably the trigger, but I can't say without more information. To debug further you can:

  • Share your block definition here so I can take a look
  • Load the block factory in a private window or in a different browser and try to create the same block, and see if it fails.
    • If you have many blocks, you can go through one at a time until you find a breaking block. I suggest starting with the one with no color input though.

@rylid-umil
Copy link
Author

I deleted the ones with no color input, still persists. theres one block i recently created that i think isn't affected by glitch. And how do i share all block defenitions at once?

@gonfunko
Copy link
Contributor

You can share the block definitions by copying the value of the BlockLibraryStorage.blockLibrary key in local storage from the Firefox web inspector:
Screenshot 2023-09-15 at 3 03 40 PM

@rylid-umil
Copy link
Author

rylid-umil commented Sep 23, 2023

@rylid-umil
Copy link
Author

I had just made new blocks ona school computer, and they all had color inputs. They still locked up, with no clear cause why. Can't even screenshot cuz my school disabled the inspection feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: devtools issue: bug Describes why the code or behaviour is wrong size: small Bugs that can be picked up and completed in 1-3 days
Projects
None yet
Development

No branches or pull requests

4 participants