Steps to reproduce

  1. Have an image of size at least x on your computer, where x is somewhere between 4088 KB and 4277 KB. (I haven't gone to the trouble of finding the smallest filesize x that triggers this behavior, but I'd imagine it's 4096 or 4097 KB.)
  2. Click on the "Image Ctrl+G" button in the Markdown editor.
  3. Select the "From my computer" radio button.
  4. Click on "Choose File" and select the image mentioned in step 1.
  5. Click on "Add Picture".

What happens

  • A dialog box pops up that reads "For security reasons, framing is not allowed; click OK to remove the frames."
    • If you click "OK", and your post contains unsaved work, a "Confirm Navigation" box pops up that reads "You have started writing or editing a post. Are you sure you want to leave this page?", with options "Leave this Page" and "Stay on this Page".
    • If you click "OK", and your post does not contain unsaved work, you are taken to a very undescriptive error page at at https://stackoverflow.com/error?aspxerrorpath=/upload/image.
    • If you cancel out of the dialog box, the "Uploading" animation on the "Add Image" box runs forever and does nothing.

What should happen

The user should be shown some sort of useful error message like "You cannot upload images larger than x kilobytes in size", and the "Uploading" animation shouldn't spin forever. (Also, the warning about frames and security looks bizarre if you don't know what's going on.)

Sites tested

  • MSO
  • SO
  • Anime.SE

Browse other questions tagged .