Help Needed: Issue Updating initial_drawing Field in Drawing XBlock

Hi everyone,

I’m developing an “amazing” Drawing XBlock that uses a React-based frontend. The XBlock allows users to draw various shapes and submit their work. I’ve successfully implemented functionality to send an initial drawing to the canvas and also users to draw their own. The final plan is to grade the drawing using algorithm or by hand.

However, I’m currently stuck on updating the initial drawing in the Studio view. When I test it in my Open edX instance (running on a VPS using the latest Tutor), the updated initial_drawing field saves correctly in Studio but doesn’t appear in the canvas on the Student view.

Interestingly, other fields—such as canvas height and width—update and reflect as expected.

If anyone has encountered a similar issue or can provide some guidance, I’d really appreciate your help!

Here’s the repository:

Thanks in advance

I will edit my request since my initial request is asking too much: What is the best way to debug studioview code since the studioview is not viewable in the xblock sdk? Each time I work on the studioview code, I have to install the xblock to my openedx instance in my VPS to test it if it works and that is time consuming.

The problem was a json object field was not updating the field in the studio edit. Once I put the json object in .json file in url and changed the field to a url as string, the problem get solved.