codewars / codewars.com

Issue tracker for Codewars
https://www.codewars.com
BSD 2-Clause "Simplified" License
2.09k stars 220 forks source link

Impossible to publish a translation : Publish button never appears #2072

Closed g964 closed 4 years ago

g964 commented 4 years ago

Describe the bug

Impossible to publish a translation : Publish button never appears

To Reproduce

Steps to reproduce the behavior:

  1. Go to a translation that you want to publish, fill all the tabs: solution, solution setup, test cases, sample test cases
  2. Click on 'Save'
  3. It says it saves No publish button

    Expected Behavior

    Be able to publish

Please complete the following information:

FArekkusu commented 4 years ago

A few translations were published today. You should probably mention the kata you couldn't translate.

g964 commented 4 years ago

Thanks for your post! It was a Fortran translation for "k-Primes".

Steffan153 commented 4 years ago

I see publish button for Fortran translation in k-Primes. Strange...

g964 commented 4 years ago

How can you see a publish button for Fortran translation when in https://www.codewars.com/kata/5726f813c8dcebf5ed000a6b/translations there is no Fortran translation? Please could you tell me how you can do that?

g964 commented 4 years ago

Another strange fact: Usually if you "SAVE" without having filled the "Solution Setup" tab you have a warning saying that this tab can't be "blank" but now you have no such warning, only something (bottom left) saying "Saving...".

Is there a link with #1608 ?

g964 commented 4 years ago

At last I have succeeded to do the translation of "k-primes" with MS Edge (usually I don't use it; can it be I have a problem with Chrome and Firefox?)

kazk commented 4 years ago

@g964 Do you have any browser extensions? Can you try without them?

I'm surprised that Chrome/Firefox doesn't work and MS Edge does. Maybe it's Windows only.

Steffan153 commented 4 years ago

@g964 I just made my own spam Fortran translation without actually publishing it.

Blind4Basics commented 4 years ago

Hi,

Seems I just ran into the same kind of troubles...

Just published (tried to) a translation to the switch bulbs kata. got the tests running when cliking "publish", tests passed, then waiting... (note: cw's icon does never roll, today...), still waiting... nothing happens. Finally, some time after that: "kumite published with failed tests" appears in orange, at the bottom of the page (-> wut!!!?? :o ). When going to the translation itself (outside of the edit panel), I see the edit button but not the other ones...

Using FF 74.0 on windows 7

cheers

kazk commented 4 years ago

@Blind4Basics Do you remember when was the last time it worked?

When going to the translation itself (outside of the edit panel), I see the edit button but not the other ones...

This is because your translation is in "draft" state. I'm not sure what happened yet.

note: cw's icon does never roll, today..

No spinning logo since March 9th. I've been updating the frontend stack and updated to use Turbolinks from a custom implementation based on jquery-pjax. The navigation is more efficient now, but the logo often just twitched so I decided to remove.

Blind4Basics commented 4 years ago

Do you remember when was the last time it worked?

no idea, since it's the first translation I published in months... :/

No spinning logo since March 9th.

Ok, good to know. Tho, the thin red bar is showing up for some operations, but not when trying to publish the translation. Weird? (if that's intended, I'd say it would be nice to have something telling the user that work is in progress x) )

EDIT: god... :o I tried with internet explorer: I cannot see the translation or even display the discourse sections of a kata (for example) x)

get this instead: image

(and it failed to log out... x)) )

anyway, that's ie...

Blind4Basics commented 4 years ago

@kazk: ok, I found the problem!

I'm printing shit tons of stuff to the console (I'm actually pretty close of the buffer limit error, when the tests succeed). I deactivated the canvas code and could publish normally. I'll reactivate the code later from the edit panel of the kata directly.

Tho, what's weird is that the tests execute perfectly in time (less than 7s, usually). Any idea why that makes the publication fail?

kazk commented 4 years ago

the thin red bar is showing up for some operations, but not when trying to publish the translation. Weird? (if that's intended, I'd say it would be nice to have something telling the user that work is in progress x) )

The progress bar is from Turbolinks so it's currently only shown on navigation. I'll add something for other operations.

god... :o I tried with internet explorer: I cannot see the translation or even display the discourse sections of a kata

IE support is not considered so that's not surprising. I can make Babel transpile to support it once I'm done migrating to the modern stack though.

Tho, what's weird is that the tests execute perfectly in time (less than 7s, usually). Any idea why that makes the publication fail?

Maybe the payload is exceeding the maximum allowed size set by the server since it includes the test output in JSON format and the code.

g964 commented 4 years ago

@kazk : I have no browser extensions; neither Chrome nor Firefox... nor MS Edge. I am surprised like you that MS Edge works so well:-)

g964 commented 4 years ago

Another Fortran translation that I have not been able to publish with Chrome: https://www.codewars.com/kata/5ce399e0047a45001c853c2b This time the "PUBLISH" button appears but when you push it, the kata validates but you can't "approve" it because this "APPROVE" button never appears. I publish it with MS Edge.

g964 commented 4 years ago

Another Fortran translation that I have not been able to publish with Chrome: https://www.codewars.com/kata/5613d06cee1e7da6d5000055 When I save, the page doesn't refresh and no "PUBLISH" button. Used MS Edge once more.

docgunthrop commented 4 years ago

I've run into an issue with publishing a kata translation. It's saved (so, in Draft), but when I click publish, I get the message "Something went wrong, please try republishing again". Tried this a few times, and clearing the browser cache didn't appear to make a difference.

This is for an Elixir translation to the "Alternate Capitalization" kata.

failed to publish

EDIT: To add more info, this is with using Firefox 74.0 (64-bit).

Blind4Basics commented 4 years ago

I've the same problem for publications of forks of solutions too.

Seems generalized to kumites in general (yet, I didn't try with a "kumite" kumite) and due to a recent change.

g964 commented 4 years ago

Using Chrome or Firefox:

FArekkusu commented 4 years ago

That's weird. I'm using Chrome v80.0.3987.149 (latest version as of now) on 64-bit Win 7 and having no issues: published a translation a couple days ago, all buttons are working correctly, and there're no errors/warning in the console.

Blind4Basics commented 4 years ago

cw has been "acting" for a bunch of hours only.

g964 commented 4 years ago

OS: win 10 Browser: Chrome(Version 80.0.3987.149 (Build officiel) (64 bits) Firefox: 74.0 (64 bits) Antivirus: Kaspersky

This has been happening for a few days. Example of warning by Chrome on the console:

Mixed Content: The page at '<URL>' was loaded over HTTPS, but requested an insecure image '<URL>'. This content should also be served over HTTPS.
discuss#5e79c943c1baac0033937f84:1 Mixed Content: The page at 'https://www.codewars.com/kata/56a5d994ac971f1ac500003e/discuss#5e79c943c1baac0033937f84' was loaded over HTTPS, but requested an insecure image 'http://graph.facebook.com/10155057140168426/picture?type=square'. This content should also be served over HTTPS.

In Firefox the lock in the address bar has a warning. In discourses page only the "reply" button works (sometimes) without refreshing. When trying to publish a new translation the "Run" or "Validate" button works but when I "save" nothing happens, no refresh of the page, no "Publish" button! Annoying because I can't get any more Chrome or Firefox to work... I have to use MS Edge...

kazk commented 4 years ago

@docgunthrop

I believe it's different from @g964's issue, but I was able to reproduce yours and found the cause. I should be able to deploy the fix soon. This is a bug that was introduced yesterday.


I was expecting some bugs to appear since I refactored the entire frontend and deployed that yesterday. The change is mostly refactoring all the code to ES modules and using Webpack to bundle them instead of file concatenation by Rails' asset pipeline. This improves the maintainability significantly and allows the use of modern tools.

kazk commented 4 years ago

@docgunthrop @Blind4Basics can you try again? I just deployed a fix for a bug that was causing publishing kumite to fail.

I can't reproduce @g964's original issue.

Blind4Basics commented 4 years ago

:+1: working perfectly on my side (and Doc just published his translation) :+1:

docgunthrop commented 4 years ago

@kazk yep, looks like it's fixed now. Just published the translation that was bugging out as well as another one I just wrote today.

kazk commented 4 years ago

Closing because it's not reproducible. Maybe related to https://github.com/codewars/codewars.com/issues/2017#issuecomment-607512316