Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make API error message more verbose #32

Open
sahildua2305 opened this issue Jul 21, 2016 · 27 comments
Open

Make API error message more verbose #32

sahildua2305 opened this issue Jul 21, 2016 · 27 comments

Comments

@sahildua2305
Copy link
Owner

I think we should make the error message more verbose explaining that it's API's fault and it's temporary.

For more details: See #31

@sahildua2305
Copy link
Owner Author

@bronwynbiro sorry for late reply. Are you still interested in tackling this issue?

@lawfets
Copy link

lawfets commented Nov 23, 2016

It would be my first time, but with some help I think I should manage

@sahildua2305
Copy link
Owner Author

@lawfets thanks for your interest in contributing to HackIDE.

Regarding this issue, it should be an easy one. We want to show better error messages to users in case API calls to HackerEarth fails. Please look into the main javascript file to find fail methods in ajax requests.

@lawfets
Copy link

lawfets commented Nov 23, 2016

I'll check it out
it would be good to know where the main javascript file is

@lawfets
Copy link

lawfets commented Nov 23, 2016

where can I find the main javascript file?

@sahildua2305
Copy link
Owner Author

Here - https://github.com/sahildua2305/hackIDE/blob/master/hackIDE/static/hackIDE/js/custom.js#L309

This is the error message we show if API request fails. We should be able to see the response and show the message according to the response message.

@lawfets
Copy link

lawfets commented Nov 23, 2016

what should I write?
This is an API request failure, this should only be temporary.
{"errors": {}, "code_id": "6879d1z", "message": "OK", "run_status": {"status": "CE", "status_detail": "Correct the compilation/syntax errors."}, "compile_status": "Error code: 1200", "web_link":

btw how do I adapt the file, do i fork it and than make a pull request?

@sahildua2305
Copy link
Owner Author

what should I write?

Depends. Can we see what error message is returned from the API request. It may also be a timeout. You will need to investigate how we can check what caused an Ajax request to fail.

btw how do I adapt the file, do i fork it and than make a pull request?

Yes, right!

@lawfets
Copy link

lawfets commented Nov 23, 2016

I don't think I can do anything at the moment as the original bug seems to be fixed and hacker earth has no bug with code_id": "6879d1z. So I cannot replicate any failures.

@lawfets
Copy link

lawfets commented Nov 23, 2016

I did find someone else with equal problem on github with a compiler but no answer there.
codehimanshu/compiler#4 also in connection with Hackerearth

@lawfets
Copy link

lawfets commented Nov 24, 2016

Is there anything I'm missing I should do to try to solve this issue

@sahildua2305
Copy link
Owner Author

@lawfets you need to do some search regarding what kind of response do we get when Ajax request fails. You will need to read a bit about Ajax for this. Accordingly, we can then handle the error cases.

@adi8
Copy link

adi8 commented Nov 26, 2016

I would be interested in working on this issue. Is this issue assigned to @lawfets ?

@lawfets
Copy link

lawfets commented Nov 26, 2016

feel free to hop in adi8, I'm still in learning mode for AJAX so at the moment, nothing I can do

@adi8
Copy link

adi8 commented Nov 26, 2016

Cool. I have a pretty good idea of what to do. Would like to know from @sahildua2305 what is exactly expected. You see I'm also new to open source projects.

@sahildua2305
Copy link
Owner Author

@adi8 Check this issue - #31 (comment)

Should be an easy fix.

@adi8
Copy link

adi8 commented Nov 27, 2016

This issue is very difficult to replicate. Based on the info that I could gather on HackerEarth API documentation(https://www.hackerearth.com/docs/api/developers/code/legacy/) and the #31 issue I made some changes in javascript. I'll issue a pull request.

@Bilalharoon
Copy link

I am new to open source but I would like to contribute

@Nayan-Das
Copy link

@sahildua2305 I want work on this issue it is not already solve.Should I take this up?

@manavendrasen
Copy link

I would like to work on this is this still open?

@MohammedBajuaifer
Copy link

Would like to work on this issue, is it still open?

@sahildua2305
Copy link
Owner Author

Yes, after staying on snooze for a while, it's up for grabs again.

@chandhu455
Copy link

@sahil865gupta can i look into this issue? Is this still valid one?

@parimalakettymuthu
Copy link

@sahildua2305 -- Is this issue still open ?

@soham-sagade
Copy link

is this open?

@Sophyia7
Copy link

Hello, is this issue still open? I am new to contributing and would love to take it on?

@0xClint
Copy link

0xClint commented Oct 8, 2022

Is this issue solved?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests