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

Initial 400 error: 11103 Method Not Allowed before face recognition api runs normally #34

Closed
AveryTheDev opened this issue Mar 22, 2019 · 7 comments

Comments

@AveryTheDev
Copy link

I have an issue in which the first image or two URL address is not accepted and I am met with the following:

Failed to load resource: the server responded with a status of 400 (Bad Request)

When I click on the link provided, it leads to a page with this on a single line.

{"status":{"code":11103,"description":"Method not allowed","details":"Method Not Allowed"}}

However, if I try another image and then go back to the original image used the server accepts the image.

Why is my request not accepted until I try enough images?

@rok-povsic
Copy link
Contributor

rok-povsic commented Mar 22, 2019

@abrown945 Hi, I'm having trouble understanding what the problem is. From the response you get it seems that an incorrect GET/POST/PATCH/DELETE request method is being sent to the server, but I'm unsure where this is coming from.

Can you post a snippet of your JavaScript code where you use the Clarifai JS library, which produces this error?

Thanks

@AveryTheDev
Copy link
Author

Sure. The problem is that I initially get a 11103 error when I use the app integrated with the face recognition api after it open. However, the error goes away after using a couple of additional photos.

Screenshot (50)

I have the code associated with the error placed above the console. I see additional details above the red highlighted text in the console, that may help

@rok-povsic
Copy link
Contributor

@abrown945 Hi, if I understand this correctly, the issue occurs on first execution of the onButtonSubmit function, but not at any later point?

Can you print out imageUrl and check if, at all times, the value passed in as imageUrl is a valid image URL?

@AveryTheDev
Copy link
Author

Its always a valid address because when the error eventually goes away I can use the same URL to have the face detected.

@AveryTheDev
Copy link
Author

AveryTheDev commented Mar 29, 2019

And yes, @rok-povsic it occurs on the first execution of the onButtonSubmit function per launch. Once that execution error goes away, I no longer have any error with the api.

@rok-povsic
Copy link
Contributor

@abrown945 From the code snippet I don't see where the issue occurs. Can you please expand the data field in the response object? It may tell us the source of the error.

@AveryTheDev
Copy link
Author

I just opened up the app and now I can't reproduce the error. Due to this, I can't provide any additional information and will close this for now.

I appreciate your assistance and if this error occurs again as I have made no changes to my code, I will be sure to follow your additional instructions. Thank you for your time

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

No branches or pull requests

2 participants