This changelog is the most important one we've shipped so far - that's why it took more than two weeks for us to post it.
In these last few weeks, we've completely rebuilt our editor so it's more understandable, more reliable, and more flexible.
We've also introduced environment variables, which allow you to store information like settings, API keys, and database credentials securely. Then, you can reference these variables in your code without exposing them.
Before this change, our editor was more unstable than we'd like. Sometimes the editor would show different states than what was happening in the back-end. Refreshing the page also caused the editor to lose part of its state, like which blocks were running, or undergoing AI suggestions. All these issues are now gone, and we're glad to have received lots of positive feedback about the new editor.
The new editor we're rolling out for everyone today is more reliable, more flexible, and more understandable. We now manage and reconcile every single piece of state in the back-end. Consequently, the editor's state will be consistent across refreshes, and for all users and devices.
This change also comes with a bunch of very important improvements. Here are some of them:
Environment variables are a way to store information like API keys, database credentials, and other settings securely. That way, you can then reference these variables in your code without exposing them to viewers.
These environment variables are useful when you want your Python blocks to perform authenticated API requests, like when doing writebacks to your database, for example.
To create an environment variable, click the "Environment Variables" button on the bottom-left corner of the editor. Then, click the button at the bottom of the list to add a new variable. Once you're done, click the save button and restart your environment for the new environment variables to be available.
You can then reference this variable in your Python code by using the os.getenv
function.
By the way, we also added a button on the bottom right of the editor so you can restart your environment manually if you need that.
We know it's been somewhat annoying to lose your in-memory state when your environment restarts. We're working on a way to automatically re-run dependencies or persist this state across restarts, so you won't lose your dataframes, variables, and other in-memory state when your environment restarts.
Expect that by the next changelog.