Returns HTML instead of JSON in case of a HTTP 404 response #4

Open
opened 2023-01-06 21:25:15 +01:00 by paul · 0 comments
Owner

It should not return HTML. For example, if you do a request just after starting, you get:

$ curl http://localhost:2356/
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>404 Not Found</title>
</head>
<body align="center">
    <div role="main" align="center">
        <h1>404: Not Found</h1>
        <p>The requested resource could not be found.</p>
        <hr />
    </div>
    <div role="contentinfo" align="center">
        <small>Rocket</small>
    </div>
</body>
</html>
It should not return HTML. For example, if you do a request just after starting, you get: ```console $ curl http://localhost:2356/ <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>404 Not Found</title> </head> <body align="center"> <div role="main" align="center"> <h1>404: Not Found</h1> <p>The requested resource could not be found.</p> <hr /> </div> <div role="contentinfo" align="center"> <small>Rocket</small> </div> </body> </html> ```
paul added the
bug
label 2023-01-06 21:25:15 +01:00
paul changed title from Does not return JSON in case of a 404 to Returns HTML instead of JSON in case of a HTTP 404 response 2023-01-06 21:25:42 +01:00
This repo is archived. You cannot comment on issues.
No Milestone
No Assignees
1 Participants
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: paul/autarco-scraper#4
No description provided.