Editor blanked out file and lost code for the third time

For the third time in as many days, the editor just randomly blanked out a file while I was editing. Each time, all my work was lost. This is extremely frustrating and a huge productivity loss.

I was thinking of using Glitch for teaching kids coding for some very large classes, but my confidence level in this platform is zero. I tried connecting it to GitHub and the UI said it was, but there is in fact, no branch in my GitHub repo, so I don’t even have any way to restore my code.

This is a critical bug. There are no specific steps to reproduce. While editing a file in Glitch, the entire contents of the file just disappear.

  • No…I did not press Select All - Delete
  • Yes…I have an excellent 150 Mbps Internet connection
  • Yes…I am on a modern MBPr with plenty of storage and memory
  • I am using Chrome and am having no other issues with other apps in the browser

Arrgh…just happened again for the fourth time. Thankfully, now I am downloading the project every five minutes.

I have verified that the problem can be reproduced as follows:

  • Paste something into the editor that is in excess of 180 lines
  • Purple toast “Reconnecting” appears
  • Green toast “Connected” appears
  • All code is wiped out

My test case is a JSON file of 215 lines. If I paste in chunks, it keeps working until the overall file length is more than 180 lines. At this point, it blows up and wipes out all the data.

This seems to be a fairly critical clipboard-related bug…hopefully it can be fixed quickly.

Sorry to hear you’ve been having problems. There is a size limit on copying+pasting data in the editor (see https://glitch.com/faq#restrictions) but unfortunately the editor makes no attempt to explain that to people at this time, something we definitely need to work on. It should, however, take chunked pastes ok and only balk when pasting items larger than the paste size limit. Similarly, it should revert to the previous content of the file before the paste rather than blanking it. Note that you can import files using wget or similar via the console to get around this copy/paste limit.

In terms of exporting to GitHub, the repo has to be an initialized repo. The easiest way to do that is to select the initialize with readme option when creating the repo on GitHub. That may be the cause of your problem. If not, try revoking access and re-granting permissions.

The problem is not that it won’t paste items of a certain size. The problem is that it COMPLETELY wipes out whatever was in your file prior to pasting.

I have tried exporting using the following scenarios…none worked:

  1. Repo exists, but no branch
  2. Repo exists, branch exists with file

The paste problem is critical…I can’t imagine continuing to use the platform knowing that Ctrl-V is going to wipe out my file and there is no Undo. :frowning:

Can you let us know the name of your project so we can take a closer look as I haven’t been able to reproduce the issue you’ve described. Thanks.

It’s https://botvinci-bot.glitch.me

Basically unusable at this point as paste commands are randomly wiping out the editor content. And the length of the clipboard content is irrelevant…seems to do it at random.

The project is set to private. Please make it public or share a join link with me. Also it’d be useful if you can confirm if it’s happening to any one specific file, or is it happening across the project? Thanks.

Sent a share link. It is happening project-wide.

Thanks.

Thanks, I’ve been able to reproduce this in a remix of that project, so we’ll take a look at the cause and get it fixed asap. Apologies for the hassle.

Good to know that you can reproduce. Thank you.

1 Like

Same problem here in my project

Any edit wipes the file blank. Github import doesn’t work either.

Thanks for the report, we believe we can do a manual fix when this problem occurs and we’ll continue to investigate the root causes. Please let us know if you see anything like this continuing to occur.

related: Auto-saving is cool - as long as you never make mistakes!

Same thing happened to me. This is my third time doing a project. Friday was the last time I was able to fully complete a project. Every time I try to go and edit it deletes the whole file while glitch says its trying to reconnect.

This deleted both my routes.js and server.js files

Thanks for the reports, it seems this is much more widespread than we thought. Investigating this and solving it is one of our top priorities this week.

For anyone else that is affected please share any project names that exhibit the symptoms. Any information will be helpful to us in tracking down this behavior.

This kind of thing has happened to me when my project’s disk was full.

(Maybe that’s not what’s happening here though.)

It’s not, but thanks for the suggestion.

Hi,
I’d like to report an interesting behavior.

My project allows user to upload a file to the server. The app would take file of any format and send back the file size as JSON. (https://glitch.com/edit/#!/filesizeget)

Not sure if its the cause but the editor acted strange and I lost my code after I uploaded an .exe file.
This persist even if I remix the project to a new one, everything I edit become blank.

I deleted the .exe using the terminal and everything went back to normal. What’s lost still not found but at least I could continue writting.

Hello everyone,

I investigated a little bit, found the following:

  • The reason why @wgutierrez74’s and @lcb931023’s files are being wiped out is that they reached 100% disk usage. We can’t do much for this, except suggesting to make up space again in your projects; we’ll make sure this situation is clearly stated in the editor so that you can avoid losing work because of this kind of errors :slight_smile:

  • I couldn’t reproduce the issue on @techbubble’s project, and Gareth reported his disk was not full. @techbubble, can you please tell us if you can reproduce the issue again? If so, can you tell us a full list of steps to consistently reproduce the bug? Thanks!

If you have any more questions/concern, please ask! :slight_smile:

Hello,

we just deployed a fix to:

  • show a warning message when your project is at high disk usage
  • prevent the editor from wiping out all of your code when the file can’t be written

Let us know if you see anything suspicious :slight_smile:

Happy Glitching!

1 Like

My editor is not blanking out or anything, but I’ve been getting this error in the console of my project during the last few hours:

ERROR: Your project is almost out of disk space (10.3/128 MB).

It's still running but might stop working once you hit the limit. You can fix
this by removing some files and then making an edit in a file to trigger a
project rebuild.

For more help, hit us up at support.glitch.com

Is this suspicious? It seems like I’m only using 10.3 MB?

Thanks for the report. It should be fine if it keeps working. In the meantime we’ll look into making sure that the log message is accurate, it could be having a strange interaction with our disk compression leading to incorrect results.

1 Like

Hi @braden337,

that error is the way in which we tell you that you’re running out of disk space. It’s probably not clear enough: 10.3/128 MB means that only 10.3 MB are available out of 128 MB, not that you’re using only 10.3MB. We’ll fix the message so that it is clearer :slight_smile:

Thanks for the report!

1 Like

Thanks @etamponi, I just downloaded the project from the advanced options menu and the folder is only 12.1 KB, does this make sense?

I did have a test sqlite3 database file (that only had 10 rows) in the .data folder, but I deleted it the first time I saw that log message.

I haven’t seen that log message for a while now.

Here are my dependencies (would this have anything to do with it?):

"dependencies": {
    "express": "^4.15.4",
    "sqlite3": "^3.1.9",
    "node-pre-gyp": "^0.6.36"
}

And here is my disk space:

$ df -BM
Filesystem     1M-blocks   Used Available Use% Mounted on
none              50261M 23513M    24604M  49% /
tmpfs             15332M     0M    15332M   0% /dev
tmpfs             15332M     0M    15332M   0% /sys/fs/cgroup
/dev/rbd2           128M    51M       39M  58% /app
/dev/xvda1        50261M 23513M    24604M  49% /etc/hosts
shm                  64M     0M       64M   0% /dev/shm
udev              15312M     0M    15312M   0% /dev/tty

Hi braden,

the zip file that you download had several files stripped off (like the node_modules and .git folders), which take up a lot of space. If you are not getting the error message in the log, it means that your disk utilisation is fine (as you can see using the df command you posted).

I’ve increased the warning threshold to 97%, and updated the message so that it is clearer.

Check that your .git directory has a reasonable size (it should be smaller that 1MB), otherwise it might be good to remove it (if you don’t care about your git history so far). It will be created again by our auto-commit code.

1 Like