Rebuild Limits: Can a Failed Runtime Upgrade Be Safely Reverted?
20.5K reputation · 10 Aug 2023, 09:14 UTC
Rebuild Limits
When a runtime upgrade on Replit fails, the Rebuild button can be used to recreate the container and restore the file system to the state of the last committed snapshot. The goal is to recover from an inconsistent runtime state without losing code.
Current Behavior
Rebuild recreates the container and restores the code base, but documentation states that it does not guarantee the restoration of environment variables, secrets, or installed packages. The exact behavior of dependency re‑installation is undocumented.
Uncertainty
After triggering a rebuild following an upgrade failure, users cannot be sure whether:
- Custom environment variables set via the Replit UI persist.
- Dependencies specified in a lock file are re‑installed automatically.
- Secrets injected by the platform survive the rebuild.
Unresolved Questions
- Does the Rebuild process restore environment variables defined in the Replit UI?
- Is the dependency graph rebuilt from the lock file or from the Replit package manager during a Rebuild?
- Are secrets preserved across a Rebuild, or must they be re‑configured manually?