how do you make those requests?
if works fine for me now when I test it in web3api interface
how do you make those requests?
if works fine for me now when I test it in web3api interface
It happens randomly I just had the case again with âhttps://deep-index.moralis.io/api/v2/0xe8a00ad589b5bda02c7bc9bba249445d1f53d50b/logs?chain=bsc&offset=0&to_date=2022-03-09%2014:01:01â => "cURL error 18: transfer closed with outstanding read data remaining "
This one just return 520 bad gateway âhttps://deep-index.moralis.io/api/v2/0x1460c3ebace5b85d19e868af01faa458baef76b1/logs?chain=bsc&offset=0&topic0=0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef&to_date=2022-03-09â
I just do normal requests with Guzzle PHP library and everything was working well but errors suddenly happened recently
I made 50 requests to this url now, I didnât get any errors, also it doesnât return data for this particular to_date
This one works well again⌠The other one still give me an error
@cryptokid This is what I get sometimes when I test within the interface. I never encountered that before this weekendâŚ
Undocumented errorâŚ
I tested with this https://deep-index.moralis.io/api/v2/0xe8a00ad589b5bda02c7bc9bba249445d1f53d50b/logs?chain=bsc&offset=0&to_date=2022-03-09%2014:01:01
100 times from a python script and I didnât get any error
it could be, how can I replicate that?
what do you do to replicate it?
Hum nothing fancy, I just use the parameters as shown above and try the request a few times. Sometimes work, sometimes notâŚ
I am still not able to replicate it.
someone else seems like also has a similar problem: Deep Index Errors: 520, 502
Yes I saw this one but no solution at the moment because you were not able to replicate as well. If someone else can have a look would be great, I donât think itâs an isolated case
this is the only endpoint that has this problem?
This works:
This doesnât:
Maybe itâs something related to response content length. I mostly use logs endpoint but I also get this error while fetching âpair createdâ event with the rest api
I still get some errors 502 Bad gateway from the Moralis interface itself as follow:
curl -X 'GET' \
'https://deep-index.moralis.io/api/v2/0x8482a932536fad492dcdbcedeb60cb9421ac384b/logs?chain=bsc' \
-H 'accept: application/json' \
-H 'X-API-Key
How is that possible?
Did you try to run the requests from another network/IP?
Yes and get the same error from another IP and network
When I debug the interface with the following simple query:
https://deep-index.moralis.io/api/v2/0x8482a932536fad492dcdbcedeb60cb9421ac384b/logs?chain=bsc
I get this error in my dev console:
ânet::ERR_HTTP2_PROTOCOL_ERROR 200â
Any change in your Nginx config or related to HTTP2 or content length response header recently?
I got this in response as headers:
Response
:status: 200
Content-Type: application/json; charset=utf-8
Access-Control-Allow-Origin: *
Content-Encoding: gzip
ETag: W/"4f78a-qioR7lLRxZrkIRJFzXaMZYwem9k"
Date: Wed, 06 Apr 2022 11:59:07 GMT
Vary: Accept-Encoding
x-rate-limit-limit: 25
x-rate-limit-used: 2
x-powered-by: Express
Server: cloudflare
x-request-weight: 2
cf-cache-status: DYNAMIC
expect-ct: max-age=604800, report-uri="https://report-uri.cloudflare.com/cdn-cgi/beacon/expect-ct"
x-rate-limit-remaining-ip-ttl: 1
cf-ray: 6f7a5b08db188ce2-EWR
x-rate-limit-remaining-ttl: 1
x-rate-limit-ip-used: 2
what do you do to get that error?
I found a workaround. I created a proxy API to communicate with your API rather than calling it directly and everything looks to work fine againâŚ
What is the difference?