Pause deployment/execution of code

I think it would be a big help if one were able to pause the auto-saving, auto-updating of code – this morning I was working on a project (with the project visible in the sidebar) and accidentally created an infinite loop because it updated before I could finish typing, crashing the browser. When I would try to reopen the project, it would crash again.

I think that this can currently be avoided by not showing the page that you’re working on, but it would be a really cool addition (and a great help) if we had, say, a button to pause/resume the updating.

Did you type in “infinite loop but --” and it went off before you put in the exception, an infinite loop of buts?

I agree this would be a good enhancement :slight_smile:

PRETTY MUCH hahaha! I was getting this weird, extremely stubborn error message around a for loop that I’d written. I couldn’t get it to go away, but I also for the life of me couldn’t find any syntax errors, so I figured – eh, maybe the editor is just hiccuping, I’ll just write this as a while loop. So I defined a const for the number of times I wanted the loop to run, initialized a counter at zero, threw together the while loop as while (counter < timesToExecute) …and it started running before I could increment the counter :joy:

The joy of coding while running live! Thanks for your story :heart_eyes:

I saw a video of two people editing the same file in Glitch, the app was restarting like every second with errors, no time for either of them to test if anything worked.

(ooh a song I like has turned up … it was only just a dream … ) :musical_note::musical_note:

A combination of the poorly-documented watch.json file and turning off “Refresh on changes” can help with this issue by delaying the restart-on-type feature. There’s also, which can help with this as well.

We have a lot of thoughts and plans around making Glitch a better place to support a full software development lifecycle which might include things around not auto-restarting “production” versions of projects and better deployment patterns; this request may fall into that future work. This is also substantially similar to Save button feature.


Oh rad! That’s exciting. Is there a place where I can contribute to the documentation? I saw that there’s a glitch project presenting the glitch API documentation but wasn’t sure if that was considered the source of truth.

We’re in the midst of rethinking documentation on a whole bunch of fronts, but we don’t have a place where non-staff can help with that yet, sorry. Depending on what the eventual plan is we may be able to open up docs for some outside help, but that’s yet to be determined.