Custom fields in my plugin: after upgrading from 1.19 to 1.26, a PATCH request doesn't populate derived fields anymore. I suspect a front-end issue

My baserow plugin adds language translation functionality. After adding a new row and populating a field, the “derived fields” are supposed to get filled in as well, as part of the PATCH request. And this used to work correctly on version 1.19.1, but stopped working after upgrading baserow to 1.26.1. I see the PATCH request in developer tools properly returns the value for the derived fields, but they are not displayed in the grid.

In the screenshot below, columns 2 and 3 are supposed to get populated when new chinese text is entered, but this is not happening properly. But you can see that the PATCH request has included data for fields ids 5191, 5192. So I expected those fields to be populated in the grid.

I suspect there’s been a change in the frontend between baserow 1.19.1 and baserow 1.26.1 and I probably need to find out what it is. I’ll going de debugging this, but is there a baserow frontend export who could point me in the right direction ? Or maybe think of a recent change that might be behind this problem ? I was thinking of adding more debugging to the base FieldType to see what’s going on at the nuxt level. Unfortunately i’m much better and debugging backend code than frontend.

frontend field type:

backend field type:

Here’s another illustration of the problem, after installing the VueJS extension:
on this first screenshot, the row has a value for the “english translation” (row property in GridViewRow component) and everything looks normal.


on this second screenshot, the row has an empty value for the “english translation” field. How does the setting of the row value work ? Can someone show me a code path where I could add some debug statements in hopes of figuring out the issue ?

@davide I randomly picked your name here, can I ask you who is best baserow developer to ask ? the PATCH request returns values for the derived fields, however the Vue state doesn’t seem to get properly set. Could someone point me in the right direction here, where is the processing of the PATCH request (modify row) on the front-end and what’s the best way to trace it to understand why the Vue rows property is not getting updated the way I expect ?

Hey @lucw, I apologize for the delay in getting back to you. We’re pretty busy with the next release.

Are the translation fields read-only or can they be modified? I would need to verify the exact version, but relatively recently, we made some changes in the frontend to ensure that the server updates only the read-only fields. Before this change, the following could happen:

  • The user modifies a field.
  • They move to the adjacent field and change another value, triggering a second request to the server.
  • The server responds to the first request and overwrites all other fields in the row, erasing the user’s latest modification.
  • The server then responds to the second request, restoring the value the user entered.

To avoid this flickering, we decided to overwrite only the read-only fields. These fields cannot be modified by the user and are recalculated by the server based on formulas. If your fields are not read-only, this might be causing your issue.

edit: that’s pretty much it, my fields start working once I set the readOnly attribute. I’m going to be studying the implication of setting them readonly as it’s not super clear to me yet.