sandzja / TreninuGramata

Trainingbook home page
1 stars 0 forks source link

The server (trainingbook.com) again sends invalid error codes. #33

Open sandzja opened 12 years ago

sandzja commented 12 years ago

Request was /iphone/2/sync?method=synchronize.

[14:11:31] Taavi Hein: The server (trainingbook.com) again sends invalid error codes. [14:11:34] Taavi Hein: 2012-04-03 14:10:01.289 TrainingBook[38052:207] <0xa0047c0 CommunicationHandler.m:(2950)> Response {"Response":"ERROR","ResponseCode":2,"ResponseMessage":"Invalid argument supplied for foreach() on line 75 in file \/var\/www\/TrainingBookSvn\/application\/Service\/Api2\/Sync.php"} [14:12:05] Taavi Hein: Code 2 is "Session invalid" in the app. [14:12:16 | Rediģēts 14:13:12] Taavi Hein: Request was /iphone/2/sync?method=synchronize. [14:13:39] Taavi Hein: I thought that was fixed once already.

sandzja commented 12 years ago

[2012.04.04. 11:41:06] Taavi Hein: Error codes in the app are: 0 //Access token is invalid 1 //Incorrect request parameters or server side issues 2 //Session is invalid 5 //Facebook API error 6 //Twitter API error 3 //User data is older on the server 4 //User data is newer on the server 7 //Database error 8 //Session has expired 9 //User not found 12 //Feed post is not a Workout post 13 //Feed post is not a note post 14 //Cannot cancel Workout, already finished 400 //Required method parameters missing 404 //Method name invalid [2012.04.04. 11:42:15] Taavi Hein: In no occasion these codes can be sent by the server when the actual error differs from the description.

sandzja commented 12 years ago

Signi, vai tev ir skaidrība par šo erroru? Ja ir, vai vari man lūdzu paskaidrot kur un pie kādiem apstākļiem viņi redz šo kļūdu un kā mēs viņiem varam palīdzēt?

signis commented 12 years ago

Vajag zināt kādi ir dati ko viņi sūta.

signis commented 12 years ago

75 rindiņa ir foreach ($data['Sports'] as $sport) { un tas izskatās, ka nav $data['Sports'] un $data nāk no izsaukuma.

sandzja commented 12 years ago

[15:05:43] Taavi Hein: The problem for us is if there are error codes that do not reflect actual error conditions. Most importantly "Session invalid" and "Session Expired" error codes that receive special treatment for all the requests. [15:09:11] Taavi Hein: Probably Signis needs to investigate where the error code value gets set to "2" and why. Maybe it's a default error code, maybe it's a code that some other server process (database for example) returns, maybe it's something else. But this has to be ruled out somehow. [15:10:24 | Rediģēts 15:12:04] Taavi Hein: Main point being that the error is not what the code says it is.

signis commented 12 years ago

Bet lai izpētītu kāpēc ir tāds kļūdas kods, man vajag centies reproducēt un redzēt pa kuru ceļu aiziet vai neaiziet.

signis commented 12 years ago

Iespējams, ka tas ir konkrētam lietotājam dēļ datiem, bet es neesmu tik dziļi iekšā tajā API, lai tā uzreiz spētu bez testēšanas atrast un novērst kļūdu.