OpenRoberta / openroberta-lab

The programming environment »Open Roberta Lab« by Fraunhofer IAIS enables children and adolescents to program robots. A variety of different programming blocks are provided to program motors and sensors of the robot. Open Roberta Lab uses an approach of graphical programming so that beginners can seamlessly start coding. As a cloud-based application, the platform can be used without prior installation of specific software but runs in any popular browser, independent of operating system and device.
Apache License 2.0
124 stars 118 forks source link

Blocks placement crash #1599

Open Sinclair732 opened 6 months ago

Sinclair732 commented 6 months ago

When loading/import the attached program (Nepo4Arduino Uno) and try to add more blocks (or copy), the blocks placement is crashed and the code view is wrong. I have equal problems too when saving the project to my programs (online) or export and try to reload it.

Steps to reproduce the behavior:

  1. Import the attached Nepo4Arduino Uno project
  2. Show and refresh the source code view (everything fine)
  3. Copy the last if-block of the main-loop (if ... jetztVorwaerts or statusVorwaerts)-block
  4. move the copied block directly behind the original if-block (directly before the 100ms wait)
  5. Show and refresh (1-2 times) the source code view (Blocks-view placement completely wrong, code view is old state)

or:

  1. Import the attached Nepo4Arduino Uno project
  2. Show and refresh the source code view (everything fine)
  3. Copy the last if-block of the main-loop
  4. export the program without online-saving or refreshing the code-view
  5. import the program shows Warning message: ist kein gültiges NEPO Programm und kann nicht hochgeladen werden!

Project export NEPOprog3.xml.txt (remove .txt extension before import)

Screenshots grafik

Expected behavior

Device information

Please ask if more information is helpful. Local server (Debian VM) with current git clone is also available, but i'm not a java expert, so debugging is not as simple.

(sry of not so good english...)

rbudde commented 6 months ago

I reduced the program to the one attached. The error is in blockly. There is a difference between 'drag vom toolbox' and 'copy'. Load the program attached and then:

NEPOprog3-reduced.xml.txt

I expected, I could reproduce this error with other plugins or with other Arduino blocks. But I couldn't. Probably a defect with the arduino call method block

rbudde commented 6 months ago

should be solved with the next release mid Februar.

AyaMoussa commented 5 months ago

Not Solved. Copying blocks still makes the program crash.