-
Notifications
You must be signed in to change notification settings - Fork 34
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
AttributeError: 'NoneType' object has no attribute 'groups' #15
Comments
Yeah, that error will happen if the "re.search()" function isn't finding
anything, which is most likely an indicator that the interface has been
changed. Again.
I'll look into it more later this week and start on a workaround. You said
it was working fine before, though?
On Sun, May 14, 2017 at 12:26 AngelaKru ***@***.***> wrote:
Since about Thursday/Friday of last week, I've been getting this error
(worked fine the day before, nothing since, though I can download files
manually from Garmin Connect - have they changed their interface again?
Anyone have a workaround or solution?):
Downloading files for user *****
Login successful! Proceeding...
Traceback (most recent call last):
File "
*\download.py", line 261, in download_files_for_user(username, password,
output) File "*\download.py", line 210, in download_files_for_user
login(agent, username, password)
File "*****\download.py", line 98, in login
response_url = re.search("response_url\s*=\s*'(.*)';",
res.get_data()).groups()[0]
AttributeError: 'NoneType' object has no attribute 'groups'
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#15>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAIQ-QeSbbyEm87YEw04bncVZqOEKxQ-ks5r5ysbgaJpZM4NabKO>
.
--
iPhone'd
|
Yes, working fine earlier last week, then around Thursday or Friday suddenly the error cropped up, and I've been unable to download via this script since then. |
seems a single quotation was changed to double-quotation: changed: response_url = re.search("response_url\s*=\s*'(.*)';", res.get_data()).groups()[0] and that seems to be working for me |
Weird; that shouldn't work. The double quotes are now effectively closing
and re-opening the regex string argument to search(); it should throw a
syntax error.
I'll look today if I can, otherwise can probably check it out tomorrow.
On Mon, May 15, 2017 at 06:26 AngelaKru ***@***.***> wrote:
seems a single quotation was changed to double-quotation:
changed: response_url = re.search("response_url\s*=\s*'(.
*)';", res.get_data()).groups()[0] to: response_url =
re.search("response_url\s*=\s*"(.*)";", res.get_data()).groups()[0]
and that seems to be working for me
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAIQ-emsz5-9qcoygf7uaXynwOp2ZnAQks5r6ChOgaJpZM4NabKO>
.
--
iPhone'd
|
Looks like something got lost in the comment formatting: |
Ahhh, they're escaped, gotcha. Ok, that makes sense then. Though I'm kind
of curious why the single quotes were working until now.
On Mon, May 15, 2017 at 9:29 AM AngelaKru ***@***.***> wrote:
Looks like something got lost in the comment formatting:
response_url = re.search("response_url\s*=\s* \ "(.*) \ ";",
res.get_data()).groups()[0]
(minus spaces around the quotes)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#15 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAIQ-TN8Bq2m_0jQu6eZC_Mt414Tx8qbks5r6FNPgaJpZM4NabKO>
.
--
iPhone'd
|
Dear @AngelaKru |
@raffdoc - now take the single quotes around (.) and add escaped double-quote (there's some trouble pasting that here as the quotes seem to be seen as special characters here): '(.)' becomes \ "(.*)\ " (but remove spaces) |
Thanks @AngelaKru |
Since about Thursday/Friday of last week, I've been getting this error (worked fine the day before, nothing since, though I can download files manually from Garmin Connect - have they changed their interface again? Anyone have a workaround or solution?):
Downloading files for user *****
Login successful! Proceeding...
Traceback (most recent call last):
File "\download.py", line 261, in
download_files_for_user(username, password, output)
File "\download.py", line 210, in download_files_for_user
login(agent, username, password)
File "*****\download.py", line 98, in login
response_url = re.search("response_url\s*=\s*'(.*)';", res.get_data()).groups()[0]
AttributeError: 'NoneType' object has no attribute 'groups'
The text was updated successfully, but these errors were encountered: