Save failed in Google Colab

Question:

I opened a number of tabs at the same time. I think that’s why Google Colab was not able to support the heavy load. The message stated:

Save failed

This file could not be saved. Please use the File menu to download the .ipynb and upload the notebook to make a copy that includes your recent changes.

Is downloading the file and uploading again the only solution?

Asked By: nilsinelabore

||

Answers:

This can happen if you open the same notebook in multiple tabs and make incompatible edits to the notebook. At this point, the only way to save your work is to follow the advice in the dialog. To prevent this in the future, avoid simultaneously editing the same notebook in multiple browser windows.

Answered By: jakevdp

It turned out to be a network issue. Output is heavy and colab is not able to save it is not able to make a handshake because internet speed is poor. So just switch the internet source and see it working.

Answered By: nilsinelabore

I got the same issue and eventually I found it’s because I set up the hardware accelerator.
This would be fixed if reseting the ‘Runtime/Change runtime type’ to ‘None’.

Answered By: fwq

I had the same problem despite ”Runtime > Change runtime type’ being already set ‘None’ beforehand. As the OP I had no other instances of the notebook open.

In the end I did 3 things in the following order:

  1. File > Save a copy in Drive
  2. File > Save a copy in GitHub
  3. File > Save

Just picking the ‘Save’ from the drop down again did the trick for me. My variables were still loaded all is working as before.

enter image description here

Answered By: ilam engl

I deleted (heavy) outputs and it worked out, it started saving without fail notifications

Answered By: Nazgul Mamasheva

The answer from @Nazgul Mamasheva made me think about it.

I have a massive notebook and any little output means modifying a very large document.

Instead of removing outputs I went to

Edit > Notebook Settings

enter image description here

And select
Omit code cell output when saving this notebook

enter image description here

That reduces drastically the network traffic needed to keep the document Saved and the chances of it reaching ‘Save failed’.

Answered By: Rub
Categories: questions Tags: ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.