27 replies · 939 views · thread synced · 7 days ago
· View on torn.com
About this thread
Posts archived:28 / 28 posts (100%) · the total is Torn's reply count + the opening post at the last fetch
Counted by TornLife from the archived posts.
Archived posts
28
Discussion span
→
Authority score
62 / 100
Historical score
42 / 100
Story score
54 / 100
Engagement score
73 / 100
People posting, likes and official posts are not counted for this thread yet: on threads longer than one page they come from a periodic pass over the archive, which has not covered it.
Most-liked replies
GenShinigami[2664617]Reporter
· 15 likes · I'd like to add in my experience. The last 3 days or so, as soon as new day rolls around, the API becomes basically non-functional. My service runs checks against the Attacks and Bars calls (as well as Basic) to …
GalacticShrimp[2802829]Reporter
· 7 likes · the response times I saw for user and market endpoints over the last 4 days (time in tct+1): [image: cdn.discordapp.com] The peaks are when most/all requests timeout (timeout is set to 33s). On the 15th we see the usual API …
sicko691[2174615]
· 7 likes · yep, API screwed again...
It's a lot of days that Torn API is unstable because I often get this error from Torn backend: Backend error occurred, please try again
Another error was: Server side error code: 0, Message: Http failure response for https://api.torn.com/user/?selections=log&from=1687132801&to=1700468152&cat=217&key=MYAPIKEY: 0 Unknown Error
The log in the browser console is: Access to XMLHttpRequest at 'https://api.torn.com/user/?selections=log&from=1687132801&to=1700805679&cat=217&key=[API key removed]' from origin 'http://localhost:4200' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
I don't know why Torn raises a CORS error from time to time.
You refer to the entire API and even the whole game being 'unstable', however the information provided only specifically relates to the 'log' selection. Can you confirm that this is only seen on the 'log' selection please?
If so, how often are you hitting this selection from your account / IP address? There would be pretty strict rate limits there.
yes I confirm that it's the log selection and I was requesting 1 log api per second (I tried also 1 log api call every 650 milliseconds).
Now I made my source code more robust in order to detect those errors and retry the API calls (that way I'm able to get all the logs I need, but without those retry attempts it's very difficult to get all the logs I need without being interrupted by a Torn backend failure).
Anyway it's failing also when I try to get the personal stats of all the members of a faction: 1 personal stats API request every 650 millisecond (it's a lot of months that I use those api without errors, but it's some days that I'm getting several error along the process).
Even when I use personalstats API it seems that it's slow.
Also when I get the bazaar prices API it's very slow: before (before halloween?) I got that data instantly, while now it sometimes takes several seconds.
To add the data I have: In the last 11h40m (since 0tct) of all my requests (about 18 per minute), 12% take over 33s (the timeout I use), 70% take on average 18s to complete (the 10% percentile is 14.2s, the 50% percentile is 18.9s, the 90% percentile 24.5s for successful calls) and 3% end in an 5xx error. This is using mostly user and market endpoints.
edit: This is in contrast to the median response time of 0.1s on the 15h between 1tct and 23tct
I agree: I don't know why this bug report has still the status "info required" if it occurs very often and it lasts long enough for the developers to investigate the issue.
I'd like to add in my experience. The last 3 days or so, as soon as new day rolls around, the API becomes basically non-functional. My service runs checks against the Attacks and Bars calls (as well as Basic) to verify outgoing attacks and losses.
The last three days, consistently, at new-day rollover the API starts crawling in its response speed, if we even get a response. New Day Friday is when it appears to have begun.
If I understand right, this change seems to have occurred at the same time that Ched said he was changing the new-day updates to be slightly staggered. I don't know if anything in that change would impact the API. But all of the communities I'm in that make heavy use of the API have noticed it too. YATA, Torn Stats, TornTools, faction bots, and so on.
The first day, it went for nearly 12 hours. The second day, closer to 6 or so. It's started today, and maybe we'll be lucky enough for it to keep reducing.
I've never been someone to make umbrella statements claiming the API is broken, but something has changed, it is operating MUCH less effectively than it was less than a week ago, specifically after new-day rollover, and for multiple hours following. I recognize it's a weekend, so there likely won't be anyone to try and do a deep dive to fix things until the morning. But I look forward to the problem being addressed in some way.
the response times I saw for user and market endpoints over the last 4 days (time in tct+1): [image: cdn.discordapp.com]
The peaks are when most/all requests timeout (timeout is set to 33s). On the 15th we see the usual API drop on the new day, on the following 3 days we can see how the API is practically unusable for multiple hours (0tct to about 12tct on the 16th, 0tct to 6tct on the 17th and 18th).