-
Notifications
You must be signed in to change notification settings - Fork 27
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
"TypeError: 'NoneType' object is not subscriptable" for Android devices #50
Comments
@cmilando I've not seen that before – do you use the iOS or Android app? |
@bachya We're using iOS, and just updated the iphone software and refreshed the TILE app. |
Hmm, I'm using iOS as well and when I run the example, I get all the expected info back. I wonder if in the background, Tile's cloud is somehow matching your account to an "expected" version of the app. We'll need to see what the traffic looks like as your phone talks to the Tile app. How familiar are you with sniffing HTTP traffic (using something like Charles, Fiddler, etc.)? |
I'm not familiar with that technique, but happy to follow your suggestions. In addition to that, is there some version of "turn it off and turn it on again" that maybe I can try first? I turned on background app refresh and updated the phone to start. Perhaps I should try with the dev version of pytile rather than the pip version? Again happy to follow your lead |
@cmilando I don't think so – if the app wasn't working at all, I don't think we'd see that particular error. That said, two things to rule out:
If those don't work, let me know and I'll walk you through traffic sniffing 101. 👍 |
Hi @bachya just a quick update that 1) didn't work, trying to install dev branch now |
hi @bachya, sorry for the delay, I've tried the
then going to that url gives the same error as above: Ready for the 101 if you are open to it! Or any other advice of course. |
@cmilando Depending on your OS, there are several apps that you can use to sniff traffic; I happen to like Charles Proxy the best, so that's what I'll use for my instructions (note that you can get a free trial before having to buy). In general, what you'll be doing is using Charles on your computer as a proxy between the Tile app on your phone and Tile's cloud. Charles will record the requests/responses in sequence, which will allow us to see what's going on. Note that this traffic sniffing will contain sensitive information, like username/password, tokens, etc. So, it's crucial to make sure you redact sensitive info before posting anything here. Charles' documentation is the place to start; it will guide you from start to finish. Pay particular attention to the SSL Proxying section: because the Tile app communicates with the Tile cloud via HTTPS, you'll need to follow the instructions here to properly decrypt that traffic (otherwise, you won't be able to see the data). Take a spin through all this and let's see how you get on. If this ends up being too much or something you don't want to do, another (possibly bad) option is for you to email me your Tile credentials, I do the sniffing, then as soon as I'm done, I let you know and you can recycle those credentials. Totally up to you and I respect if that isn't something you want to do. Let me know! |
@bachya thanks for this -- will try and get back to you |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
@bachya so I finally got this to work, through the normal channels, with some caveats:
But thanks again for your responsiveness, and this app! |
Thanks for posting, @cmilando. Can you show me an example of the invalid data that you've found? That'll help me catch it appropriately. Thanks! |
This is the code (sanitized)
The states output looks like
And here is the error that comes when the
|
Thanks, @cmilando. That shows that the "get tile list" call is working, but the "get tile details" is throwing an exception. I need a bit more info to diagnose. I just pushed an updated logging.basicConfig(level=logging.DEBUG) ...and post the (scrubbed of sensitive output)? Thanks! |
Hopefully this is it?
|
@cmilando Very helpful! The "problem" appears to be that last child (with a redacted ID of |
@bachya yes, still active, however, as you can see, there is some issue with the location that is being recorded. This Tile device is actually a Samsung Galaxy J7 Star (I'm sure you've seen this but ids beginning with |
Fascinating. As you alluded to previously, there must be some difference between iOS and Android: my iPhone shows that information. At any rate, I can add appropriate logic to catch this and handle the exception. Thanks for your help! |
Hi @bachya,
Thanks so much for this helpful app. I'm trying to get set up to use it in a research study, but am having trouble getting off the ground.
When trying to run your example code, i get the following response:
{"version":1,"revision":1,"timestamp":"2020-06-30T13:16:15.732Z","timestamp_ms":1593522975732,"result_code":0,"result":{"message":"invalid app version, version=null, app_id=null"}}
Seems like DEFAULT_APP_VERSION is hard-coded in
client.py
? Admittedly an api novice, so any help is greatly appreciatedThe text was updated successfully, but these errors were encountered: