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

Not sending X-Requested-With header #1

Open
jankrueger opened this issue Apr 5, 2011 · 15 comments
Open

Not sending X-Requested-With header #1

jankrueger opened this issue Apr 5, 2011 · 15 comments
Labels

Comments

@jankrueger
Copy link

Hi there,

Authorization isn't working as it should. I get an error that says "Twitter: Not sending X-Requested-With header" and i think it comes from get_request_token().
After that the request fails because of "Unauthorized".

Do you have any suggestions on this?

Regards Jan

@jpurcell
Copy link
Owner

jpurcell commented Apr 5, 2011

Hey Jan, I'm glad you're trying this out!

Hmm... interesting. I haven't had that issue. Couple questions:

  1. Can I assume you are using Android? If so, what version SDK and what Ti Mobile SDK?
  2. Where are you getting the "Twitter: X-Requested-With header" error? Is it a pop-up or does it show in Titanium's console/error log?
  3. Are you using the debug branch or master?

If it's not apparent, there are basically 3 functions that do all the authenticating and they occur in order. And get_request_token() is the first in the sequence, and all it does is send an XHR request.

-Joseph

@jankrueger
Copy link
Author

Hey Joseph,

thanks for your quick reply!

  1. Yes, i am on Android, Titanium Mobile SDK 1.6.1 using an Android 1.6 device. Other XHR Request in my App are working, so it might not be version related.
  2. The Output is on shown on the console, no pop-up. After the message the XHR request ends in xhr.onerror with an httpreqponseexeption: "Unauthorized".
  3. I'm on the master branch but i'll have a look at the debug version.

I'm unsure whether or not he needs the X-Requested-With header. I tried setting this header manualy by doing XHR.setRequestHeader("X-Requested-With","") but nothing changed (not sure about that call anyway ;))

Jan

@jpurcell
Copy link
Owner

jpurcell commented Apr 5, 2011

Ahhh yes, okay, I know exactly what's going on. No need to go to the debug version for this, but if you wan't to know what's happening at every step feel free.

I'm not an expert on OAuth or how Twitter's API works, but the "Unauthorized" error is coming from Twitter's server and they send it if the data sent to Twitter isn't correct or it is missing. Incorrect data would be a bad signature, incorrect keys, etc.

My first guess is an incorrect "consumer_key" and/or "consumer_secret". Can you confirm they are set?

Also, it will help to have some more info:

  1. What method of the BirdHouse class are you calling? There are 5 functions you can call as listed in the ReadMe.

@jankrueger
Copy link
Author

Yes, i have to admitt that it looks like the keys are wrong. I'll have to confirm that and will come back to you after i did. Thanks for the support! Great work.

@jpurcell
Copy link
Owner

jpurcell commented Apr 5, 2011

Thanks! I appreciate you trying this out!

Also, in your comment where you posted the error log it had your consumer_key and consumer_secret. Be SURE you never do that, lol. I deleted it for ya. It should only print out in the debug version, though.

Keep me posted, please post back if it was the keys.

@jpurcell
Copy link
Owner

jpurcell commented Apr 5, 2011

Your MODIFIED error log was:

D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[18,135665] fn-load_access_token: no file found D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[3,135668] initialization: authorized is false D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[3,135671] fn-tweet: authorized is: false D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[2,135673] fn-tweet: we are not authorized, so initiate authorization seq uence I/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[3,135676] ----- Initializing Authorization Sequence ----- D/NetworkLocationProvider( 76): getLocation(): triggering a wifi scan D/NetworkLocationProvider( 76): updateWifIScanResults(): 1 APs D/LocationMasfClient( 76): getNetworkLocation(): Returning cache location with accuracy 60.0 D/dalvikvm(15413): GC freed 25976 objects / 1635160 bytes in 461ms D/dalvikvm(15413): GC freed 16068 objects / 1135496 bytes in 216ms D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[3116,138792] fn-get_request_token: the message is {"method":"POST","acti on":"https://api.twitter.com/oauth/request_token","parameters": [ ["oauth_consumer_key","THECONSUMERKEY"], ["oauth_signature_method","H MAC-SHA1"], ["oauth_timestamp","1302012974"], ["oauth_nonce","ZHi5BcGBx9K7evoDZJyMQlNsGLioN"], ["oauth_signature","PlZRUtVIEbYHoo51ucSq2nCYY="]]} D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[52,138844] fn-get_request_token: the url is https://api.twitter.com/oaut h/request_token?oauth_consumer_key=THECONSUMERKEY&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1302012974&oauth_nonce=ZHi5BcGBx9 K7evoDZAZ3KQlNsN&oauth_signature=PlZRUtVIEbYHoY%3D D/TiHttpClient(15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[10,138854] Setting ready state to 1 I/TiHttpClient(15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[1,138855] Twitter: not sending X-Requested-With header W/DefaultRequestDirector(15413): Authentication error: Unable to respond to any of these challenges: {} D/TiHttpClient(15413): (TiHttpClient-27)
[1399,140254] Setting ready state to 2 D/TiHttpClient(15413): (TiHttpClient-27)
[1,140255] Setting ready state to 3 D/TiHttpClient(15413): (TiHttpClient-27)
[6,140261] clearing the expired and idle connections W/IdleConnectionHandler(15413): Removing a connection that never existed! W/IdleConnectionHandler(15413): Removing a connection that never existed! E/TiHttpClient(15413): (TiHttpClient-27)
[15,140276] HTTP Error (org.apache.http.client.HttpResponseException): Unauthorized E/TiHttpClient(15413): org.apache.http.client.HttpResponseException: Unauthorized E/TiHttpClient(15413): at ti.modules.titanium.network.TiHTTPClient$LocalResponseHandler.handleResponse(TiHTTPClient.java:209) E/TiHttpClient(15413): at ti.modules.titanium.network.TiHTTPClient$LocalResponseHandler.handleResponse(TiHTTPClient.java:169) E/TiHttpClient(15413): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:657) E/TiHttpClient(15413): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:637) E/TiHttpClient(15413): at ti.modules.titanium.network.TiHTTPClient$ClientRunnable.run(TiHTTPClient.java:1000) E/TiHttpClient(15413): at java.lang.Thread.run(Thread.java:1060) I/TiHttpClient(15413): (TiHttpClient-27)
[11,140287] Sending error Unauthorized D/TiAPI (15413): (kroll$3: file:///android_asset/Resources/main_windows/function.js)
[5,140292] fn-get_request_token: XHR request has failed! 3 { 'source' :
[Ti.Network.HTTPClient] 'error' : 'Unauthorized' , } I/ActivityManager( 76): Stopping service: com.google.android.apps.maps/com.google.googlenav.friend.android.LocationFriendService D/dalvikvm(15463): GC freed 3062 objects / 343600 bytes in 119ms

@jankrueger
Copy link
Author

Thanks for that but i shortened them before posting :)
I will try and comfirm things with another pair of keys in a moment, hope that helps.

Oh and i forgot to say that i call the tweet() method without authorizing before.

@jpurcell
Copy link
Owner

jpurcell commented Apr 5, 2011

Ok, well if the keys are correct then we have another issue going on. If your keys are coming from your app's config on Twitter's site then they are certainly correct.

It looks like you are using the tweet() function and the device hasn't authorized with Twitter yet, so the error is throwing when the authorization sequence happens, specifically when it's trying to get the request tokens. If the "Unauthorized" error is coming from something other than wrong consumer keys then I'll need to beat my head against the wall some more, hahahaha! We'll get this working, just let me know what's up.

@jpurcell jpurcell closed this as completed Apr 6, 2011
@jpurcell jpurcell reopened this Apr 7, 2011
@jpurcell jpurcell closed this as completed Apr 7, 2011
@Umair
Copy link

Umair commented Jun 1, 2011

I am getting the same issue while request sent from get_access token , my logs are as follow,
DEBUG] [2732,374689] the API request message: {"action":"https://api.twitter.com/oauth/access_token","method":"POST","parameters":[["oauth_token","SfPuTqrS8rrndOcwxCHWYqoPBfmxMmxxq9vq1gZBxI"],["oauth_verifier","7Kxy9184IVgLtP08tB2t69RFoumosMBtwGdK72Xtd0"],["oauth_consumer_key","I2l0Ko4cBWuO4k5PInrgA"],["oauth_signature_method","HMAC-SHA1"],["oauth_timestamp","1306944767"],["oauth_nonce","LC8x6arbi3gmPiu8Z5LEa4CzyE791vCHsxCR5MPneP"],["oauth_version","1.0"],["oauth_signature","t0Dv1/lbs8QZBzlGwQxekIsJW6s="]]}
[DEBUG] [43,374732] api url: https://api.twitter.com/oauth/access_token?oauth_token=SfPuTqrS8rrndOcwxCHWYqoPBfmxMmxxq9vq1gZBxI&oauth_verifier=7Kxy9184IVgLtP08tB2t69RFoumosMBtwGdK72Xtd0&oauth_consumer_key=I2l0Ko4cBWuO4k5PInrgA&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1306944767&oauth_nonce=LC8x6arbi3gmPiu8Z5LEa4CzyE791vCHsxCR5MPneP&oauth_version=1.0&oauth_signature=t0Dv1%2Flbs8QZBzlGwQxekIsJW6s%3D
[INFO] [11,374743] var_dump: responseText (object):
[TRACE] D/TiHttpClient( 1205): (kroll$3: app://twitter/login.js) [10,374753] Setting ready state to 1
[TRACE] I/TiHttpClient( 1205): (kroll$3: app://twitter/login.js) [0,374753] Twitter: not sending X-Requested-With header

Every thing is correct , but I dont know why its giving this error , I am trying to resolved it for several hours :(

@jpurcell jpurcell reopened this Jun 1, 2011
@jpurcell
Copy link
Owner

jpurcell commented Jun 1, 2011

Ok, I haven't had this issue, and I can't replicate it either. That said, can you try something?

Try what I found here: http://bugs.jquery.com/ticket/1623, which is setting the X-Requested-With to 'XMLHttpRequest'.

XHR.setRequestHeader("X-Requested-With", "XMLHttpRequest");

Should be around line 580 on birdhouse-debug.js, before the XHR.send() line. Can you try that and let us know if that fixes the issue?

@Umair
Copy link

Umair commented Jun 1, 2011

Yes I tried this and set this
XHR.setRequestHeader("X-Requested-With", "XMLHttpRequest");
also tried
XHR.setRequestHeader("X-Requested-With", "");
But same problem continue occurring.
I even tried after setting the above valuse
XHR.getRequestHeader("X-Requested-With")
but it didnt show me and showed an exception that readyState should be greater than 1 to get the value of header
I am trying it 1.7.0 titanium sdk and 2.2 android sdk

@jpurcell
Copy link
Owner

jpurcell commented Jun 2, 2011

Can you see if this comment fixed anything:
#9 (comment)

There is a supposed issue with the window?

@mathieugerard
Copy link

I just would like to share that I always get a "Twitter: not sending X-Requested-With header" message in the console; in particular when the authorization succeeds!
So this might not be the reason why authorization is not working for you guys... ???

Here is a piece of the log I get in case of success:
D/TiAPI ( 386): (kroll$1: app://app.js) [36,31605] api url: https://api.twitter.com/oauth/access_token?oauth_token=xxxxxxxxxxxxxxxxxx&oauth_verifier=xxxxxxxxxxxxx&oauth_consumer_key=xxxxxxxxxxx&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1307360506&oauth_nonce=xxxxxxxxxxxx&oauth_version=1.0&oauth_signature=xxxxxxxxxxxxxxxxxx%3D
D/TiHttpClient( 386): (kroll$1: app://app.js) [10,31615] Setting ready state to 1
I/TiHttpClient( 386): (kroll$1: app://app.js) [1,31616] Twitter: not sending X-Requested-With header
D/TitaniumModule( 386): (kroll$1: app://app.js) [8,31624] calling timeout timer 0 @1307360509213
I/TiAPI ( 386): (kroll$1: app://app.js) [2,31626] ====================check status

I'm using Titanium 1.7.0.RC1, with Android 2.2.

For me, the problem I had with authorization was solved with the solution proposed by jgoslin in #9 (comment)

Regards

@rjsteele
Copy link

rjsteele commented Jul 2, 2011

I have the same problem (Twitter: not sending X-Requested-With header). I am using the following code.

Ti.include('birdhouse.js');

var BH = new BirdHouse({
consumer_key: "the_key",
consumer_secret: "the_secret",
callback_url : "the_call_back"
});
BH.tweet('Trying something out....');

I would like to post "Try something out ..." to my twitter page, but nothing post. Do I need more code? When I run the emulator in Titanium, I get Twitter's authorization page with my apps information. I click 'Authorize app" and another Twitter page pops up "Redirecting you back to the application", but nothing post my twitter account.

I am using Android API 2.3.3 on the Titanium 1.7

I/ActivityManager( 62): Starting: Intent { cmp=com.palmvalleychurch.mainapp/org.appcelerator.titanium.TiModalActivity (has extras) } from pid 337
I/ActivityManager( 62): Displayed com.palmvalleychurch.mainapp/org.appcelerator.titanium.TiModalActivity: +451ms
I/ARMAssembler( 62): generated scanline__00000077:03010104_00000504_00000000 [ 18 ipp](37 ins) at [0x45fb5a08:0x45fb5a9c] in 441467 ns
D/dalvikvm( 337): GC_CONCURRENT freed 754K, 46% free 4649K/8583K, external 1646K/1828K, paused 6ms+17ms
D/dalvikvm( 337): GC_CONCURRENT freed 1052K, 45% free 4772K/8583K, external 1646K/1828K, paused 7ms+6ms
D/dalvikvm( 337): GC_CONCURRENT freed 1226K, 44% free 4879K/8711K, external 1646K/1828K, paused 7ms+16ms
D/TitaniumModule( 337): (kroll$6: app://twitter.js) [26004,49736] calling timeout timer 0 @1309623090716
D/dalvikvm( 337): GC_CONCURRENT freed 1129K, 43% free 5102K/8839K, external 1646K/1828K, paused 8ms+7ms
D/TiAPI ( 337): (kroll$6: app://twitter.js) [2285,52021] signing key is ************************_&
W/OrientationEventListener( 337): Cannot detect sensors. Invalid disable
E/TiBaseActivity( 337): (main) [60,52081] Layout cleanup.
I/dalvikvm( 337): Jit: resizing JitTable from 2048 to 4096
D/TiAPI ( 337): (kroll$6: app://twitter.js) [284,52365] baseString is POST&https%3A%2F%2Fapi.twitter.com%2Foauth%2Faccess_token&oauth_consumer_key%3D_
%26oauth_nonce%3DselupfcgPhdg7oRlrZFkXETQtfTspHa07xEIln5Mxz%26oauth_signature_method%3DHMAC-SHA1%26oauth_timestamp%3D1309623092%26oauth_token%3DwVb0VGEbVSLZwqMXh4KoCh1eIcOnq8BMKWR17NFqY%26oauth_verifier%3DDcdGcPr4cDbZbtwTgCTl0kTagWpjbSoMCQTpYxQjI%26oauth_version%3D1.0
D/dalvikvm( 337): GC_CONCURRENT freed 1645K, 47% free 4911K/9159K, external 1646K/1828K, paused 7ms+5ms
D/TiAPI ( 337): (kroll$6: app://twitter.js) [1822,54187] signature is rb72k5Vc0KJGD9YKJu2FxBQDpHs=
D/TiHttpClient( 337): (kroll$6: app://twitter.js) [47,54234] Setting ready state to 1
I/TiHttpClient( 337): (kroll$6: app://twitter.js) [1,54235] Twitter: not sending X-Requested-With header
D/dalvikvm( 337): GC_FOR_MALLOC freed 1031K, 50% free 4649K/9159K, external 1646K/1828K, paused 77ms
D/TiHttpClient( 337): (TiHttpClient-2) [508,54743] Setting ready state to 2
D/TiHttpClient( 337): (TiHttpClient-2) [1,54744] Setting ready state to 3
D/TiHttpClient( 337): (TiHttpClient-2) [4,54748] Setting ready state to 4
W/MessageQueue( 337): Handler{4059ce70} sending message to a Handler on a dead thread
W/MessageQueue( 337): java.lang.RuntimeException: Handler{4059ce70} sending message to a Handler on a dead thread
W/MessageQueue( 337): at android.os.MessageQueue.enqueueMessage(MessageQueue.java:196)
W/MessageQueue( 337): at android.os.Handler.sendMessageAtTime(Handler.java:457)
W/MessageQueue( 337): at android.os.Handler.sendMessageDelayed(Handler.java:430)
W/MessageQueue( 337): at android.os.Handler.post(Handler.java:248)
W/MessageQueue( 337): at org.appcelerator.titanium.kroll.KrollCallback.callAsync(KrollCallback.java:162)
W/MessageQueue( 337): at org.appcelerator.titanium.kroll.KrollCallback.callAsync(KrollCallback.java:96)
W/MessageQueue( 337): at org.appcelerator.titanium.kroll.KrollCallback.callAsync(KrollCallback.java:91)
W/MessageQueue( 337): at ti.modules.titanium.network.TiHTTPClient.fireCallback(TiHTTPClient.java:483)
W/MessageQueue( 337): at ti.modules.titanium.network.TiHTTPClient.fireCallback(TiHTTPClient.java:474)
W/MessageQueue( 337): at ti.modules.titanium.network.TiHTTPClient.setReadyState(TiHTTPClient.java:506)
W/MessageQueue( 337): at ti.modules.titanium.network.TiHTTPClient$ClientRunnable.run(TiHTTPClient.java:1022)
W/MessageQueue( 337): at java.lang.Thread.run(Thread.java:1019)
W/KeyCharacterMap( 337): No keyboard for id 0
W/KeyCharacterMap( 337): Using default keymap: /system/usr/keychars/qwerty.kcm.bin

@mEstrazulas
Copy link

Hi,

Sorry to bother you, but what happens is the following:

In the emulator, the window opens on Twitter to authenticate properly. However, when I put the device does not open. By DDMS I managed to get this log:

10-26 13:36:18.608: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [211,14333] fn-load_access_token: no file found
10-26 13:36:18.616: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [3,14336] initialization: authorized is false
10-26 13:36:18.616: INFO/TiAPI(26790): (kroll$3: app://windows/enviar.js) [2,14338] ----- Initializing Authorization Sequence -----
10-26 13:36:18.616: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [2,14340] fn-authorize: use this callback function: "org.appcelerator.titanium.kroll.KrollCallback@45ad1130"
10-26 13:36:18.624: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [5,14345] fn-api: callback sent is "org.appcelerator.titanium.kroll.KrollCallback@45ab6258"
10-26 13:36:18.624: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [2,14347] fn-api: force authorization is false
10-26 13:36:18.624: INFO/TiAPI(26790): (kroll$3: app://windows/enviar.js) [0,14347] ----- Initializing API Request Sequence -----
10-26 13:36:18.624: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [2,14349] access_token is XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX typof: string
10-26 13:36:18.694: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [63,14412] fn-api: accessor is {"tokenSecret":"GH6PDx1lNzGnqWIkp21IntGHmVhhoFdixLhwmU1AKk","consumerSecret":"1eOqy7lIkRwEdNfBQc2OUdDUnGliMENVhUAztG0"}
10-26 13:36:19.202: DEBUG/dalvikvm(26790): GC_FOR_MALLOC freed 13621 objects / 828336 bytes in 57ms
10-26 13:36:19.436: DEBUG/dalvikvm(26790): GC_FOR_MALLOC freed 12613 objects / 894912 bytes in 54ms
10-26 13:36:19.655: DEBUG/dalvikvm(26790): GC_FOR_MALLOC freed 12302 objects / 869016 bytes in 54ms
10-26 13:36:19.679: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [991,15403] the API request message: {"action":"https://api.twitter.com/oauth/request_token","method":"POST","parameters":[["oauth_callback","http://transitoce.com"],["oauth_token","XXXXXXXXXXXXXXXXXXXXX"],["oauth_consumer_key","XXXXXXXXXXXXXXXX"],["oauth_signature_method","HMAC-SHA1"],["oauth_timestamp","1319643378"],["oauth_nonce","gkMpU5DT5aNDNIWbIXqJhoPDBrLVhXmzUm4m4ACmhZ"],["oauth_version","1.0"],["oauth_signature","mefYfA/TbZIkIONcMY+gEGXpp8o="]]}
10-26 13:36:19.718: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [34,15437] api url: https://api.twitter.com/oauth/request_token?oauth_callback=http%3A%2F%2Ftransitoce.com&oauth_token=278998996-sBObwBbSt0Ho0Nwv7ATsAh5eacafmF4lGFFxAOAN&oauth_consumer_key=zKALiOJb76frbIju4st9QQ&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1319643378&oauth_nonce=gkMpU5DT5aNDNIWbIXqJhoPDBrLVhXmzUm4m4ACmhZ&oauth_version=1.0&oauth_signature=mefYfA%2FTbZIkIONcMY%2BgEGXpp8o%3D
10-26 13:36:19.725: DEBUG/TiHttpClient(26790): (kroll$3: app://windows/enviar.js) [14,15451] Setting ready state to 1
10-26 13:36:19.725: INFO/TiHttpClient(26790): (kroll$3: app://windows/enviar.js) [0,15451] Twitter: not sending X-Requested-With header
10-26 13:36:19.733: DEBUG/TiUIScrollView(26790): (main) [7,15458] creating vertical scroll view
10-26 13:36:21.640: DEBUG/dalvikvm(26790): GC_EXPLICIT freed 3517 objects / 234072 bytes in 91ms
10-26 13:36:21.765: DEBUG/dalvikvm(26790): GC_FOR_MALLOC freed 1273 objects / 96968 bytes in 54ms
10-26 13:36:21.765: INFO/dalvikvm-heap(26790): Grow heap (frag case) to 5.472MB for 131088-byte allocation
10-26 13:36:21.827: DEBUG/dalvikvm(26790): GC_FOR_MALLOC freed 140 objects / 7568 bytes in 55ms
10-26 13:36:22.421: INFO/Resources(26790): Loaded time zone names for en_US in 269ms.
10-26 13:36:22.429: INFO/dalvikvm(26790): Jit: resizing JitTable from 8192 to 16384
10-26 13:36:22.452: WARN/DefaultRequestDirector(26790): Authentication error: Unable to respond to any of these challenges: {}
10-26 13:36:22.452: DEBUG/TiHttpClient(26790): (TiHttpClient-1) [2714,18172] Setting ready state to 2
10-26 13:36:22.452: DEBUG/TiHttpClient(26790): (TiHttpClient-1) [0,18172] Setting ready state to 3
10-26 13:36:22.452: DEBUG/TiHttpClient(26790): (TiHttpClient-1) [5,18177] clearing the expired and idle connections
10-26 13:36:22.460: WARN/IdleConnectionHandler(26790): Removing a connection that never existed!
10-26 13:36:22.460: ERROR/TiHttpClient(26790): (TiHttpClient-1) [4,18181] HTTP Error (org.apache.http.client.HttpResponseException): Unauthorized
10-26 13:36:22.460: ERROR/TiHttpClient(26790): org.apache.http.client.HttpResponseException: Unauthorized
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at ti.modules.titanium.network.TiHTTPClient$LocalResponseHandler.handleResponse(TiHTTPClient.java:211)
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at ti.modules.titanium.network.TiHTTPClient$LocalResponseHandler.handleResponse(TiHTTPClient.java:171)
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:657)
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:637)
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at ti.modules.titanium.network.TiHTTPClient$ClientRunnable.run(TiHTTPClient.java:1002)
10-26 13:36:22.460: ERROR/TiHttpClient(26790): at java.lang.Thread.run(Thread.java:1096)
10-26 13:36:22.460: INFO/TiHttpClient(26790): (TiHttpClient-1) [3,18184] Sending error Unauthorized
10-26 13:36:22.468: DEBUG/TiAPI(26790): (kroll$3: app://windows/enviar.js) [4,18188] API request failed because the access token and token secret must be wrong. Error: { 'source' : [Ti.Network.HTTPClient] 'error' : 'Unauthorized' , }
10-26 13:36:23.999: DEBUG/dalvikvm(26790): GC_EXPLICIT freed 7105 objects / 659376 bytes in 73ms
10-26 13:36:49.043: DEBUG/SntpClient(1378): request time failed: java.net.SocketTimeoutException: Connection timed out

I did what was recommended in issues # 1, but failed. Can you help me.

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

No branches or pull requests

6 participants