My goal: I need to make some minor UI changes to an existing internal tool (renaming fields, visually reorganizing the layout, and adding one new dropdown). The app is already completed and in use by our team.
Issue: I am new to Retool and do not have access to a dedicated staging environment. My plan was to duplicate the app to create a "sandbox" version where I can play with the layout freely.
However, I am worried that the duplicated app will still be connected to our database. I want to ensure that if I accidentally click a button or trigger a query while moving things around in my duplicate, I won't be writing, deleting or even exporting a lot of data.
I’m from Ops and the dev team does not have any time to assist us with that so it would be of great value if I could step in and help, I’m sure it’s something simple.
Steps I've taken to troubleshoot: I haven't started yet because I want to be 100% safe.
Is duplicating the app the right way to create a safe playground?
How can I easily "disconnect" or disable the write queries in the copy so I can edit the UI without risk to the backend data?
Without using a staging environment, I believe you already pretty much have the right idea for how to get a clean version of the app for you to toy around with.
To prevent any of the write/update queries from firing in your app you would want to disable them. To do this you can go to each query’s Advanced tab and add ‘true’ to the Disable Query section:
Do you need any of the actual queries to be in your copy? For maximum “I don’t want to break things in production” protection you could consider making a new app or module from scratch and then just copying all of the components in the live app over with the editor’s Copy/Paste commands in the component tree in the app:
As another option, if you can eke out a little bit of time from a dev to verify, you might consider using the idea of disabling the queries in a more bespoke fashion and add yourself to the check of disabling the queries you are worried about triggering. For example, if a writeToDB query needed to be protected from you specifically editing the application you could add {{ current_user.email === '<youremailhere>' && retoolContext.inEditorMode }} to the Disable Query section and it would only be disabled if you are the current user and the app is being edited.
If there are any other concerns you can think of I’m sure there’s a good way to address them.