Error while uploading emoji breaks emoji upload feature


(PJH) #1

Summary:

  • Tried to upload an, admittedly silly, number of emoji (40x40px ones) at /admin/customize/emojis
  • Got “Sorry, there has been an error while storing the emoji” error
  • Couldn’t click away the dialog because the tab was busy.
  • Killed tab,
  • Went back to /admin/customize/emojis to notice a small number (~20) had actually uploaded
  • Deleted those that had uploaded with a view to find out how many uploaded emoji is ‘too many’
  • Tried to upload the first 20 again
  • Got 'Sorry, the name ‘<icon-name>’ is already used by another emoji numerous times
  • Hard-refresh. Note that while the emoji graphic is no longer there, the emoji name is.
    • Delete the emoji again - it disappears from the UI
    • Hard-refresh - it reappears
  • Try to upload again - same error
  • Try to upload a so-far ‘not present’ emoji, get "Sorry, there has been an error while storing the emoji.’

Full history on ours in Bugs under ‘Error with emoji uploading’ (/t/7893)


(Jeff Atwood) #2

@zogstrip can we force a limit here to reduce support requests?


(Kane York) #3

It looks like there’s several buggy behaviors here.

Removals seem to have not completed all the way?, duplicates should warn but overwrite, errors in the upload, and probably something else going wrong.


#4

Sounds very similar to the bug we encountered here:

https://meta.discourse.org/t/discourse-not-allowing-any-changes-to-custom-emojis/23883?source_topic_id=24867

(PJH) #5

Looks identical to me :wink:


(Jeff Atwood) #6

All stuff for you to improve @zogstrip in the run up to 1.2.

I definitely think we should be limiting emoji upload to some reasonable number.


(PJH) #7

Can anything be done to resolve the current state ours is in? I’m still unable to upload any new emoji and have the ‘half finished’ emoji hanging around.


(Régis Hanol) #8

Let’s try this :panda_face:

https://github.com/discourse/discourse/commit/1e6f886886ce469b114c737c9322bf7bc4acd50c


(PJH) #9

Beta8 - still cannot upload Emoji.


(PJH) #10

Beta 9:


(Soy) #11

I’m having issues uploading emojis as well! Is there a fix?


(Sam Saffron) #12

I think I just fixed this

@PJH I flushed your local cache, but there is a race condition that may reoccur till your next update

Closing, flag to reopen if still an issue.

https://github.com/discourse/discourse/commit/103d42a9d9887135871f1e8c1a60bff1120af882


(Sam Saffron) #13