-
Notifications
You must be signed in to change notification settings - Fork 136
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
Timeout exeption message while running gmail.py #21
Comments
I'm also seeing this. |
I'm wondering whether plaintext authentication ( Anyone else having success with this script? Edit: some notes Plaintext auth is still allowed, however, I had to pull the
It's probaby worth noting that users will have to create an application-specific password if they have 2-factor auth turned on, either in the help text for the command or in errata? That said, this sleuthing doesn't seem to have eliminated the Timeout exception or allowed me to download my gmail. |
I have the same issue. Even after creating an app-specific password. It seems like the way the TimeoutException class is defined, whenever the gmail_slurper.py file is imported in a script, an error will be raised... |
The timeout exception shouldn't stop the script - it merely reconnects. Let On Thu, Feb 6, 2014 at 2:39 PM, Cédric Warny [email protected]:
Russell Jurney twitter.com/rjurney [email protected] datasyndrome.com |
Commenting out the following line in gmail_slurper.py solved it for me:
Looks like writing a stderr out stops the script. |
That can't be the case... are you sure the script is stopping? It is On Fri, Feb 7, 2014 at 8:23 AM, Cédric Warny [email protected]:
Russell Jurney twitter.com/rjurney [email protected] datasyndrome.com |
I've successfully run the script. Just as Russell describes ... I get the timeout exception. The script Kendall Waters
|
I was able to eventually get it to run by commenting out the exception try-catch blocks and fixing whatever Gmail is sending back as an error (first the app-specific password, then something else.) You might want to try experimenting with that approach as a way to get past it; I understand the reason for the try-catch blocks and don't think the main code needs to change for that since it seems like a subset of users have this problem. |
I have/had a similar problem as documented here. As I seldom use my gmail account, I had only 2 emails in the Inbox. The slurper program would only read one and then stop. The output was only a dict definition within the part-1.avro file - no email data was added. Reading the emails individually, I was able to read the 1st one, but the 2nd one - ID of 2 - returned: It appeared that I had weird/corrupted 2nd email (or something) which I deleted and then composed another to myself. This enabled the slurper to add the 1st email to the avro file, but not the 2nd. I then composed a 3rd email to myself. The slurper added the first 2 emails to the avro file, but not the 3rd. It seems to be losing the last email i.e. prematurely exiting. At all times, the slurper counts the total number of emails correctly in the ongoing output to the screen. |
changing lines 83 and 84 to: if hasattr(signal, 'SIGALRM'):
signal.signal(signal.SIGALRM, timeout_handler)
if hasattr(signal, 'alarm'):
signal.alarm(30) # triger alarm in 30 seconds
# from
signal.signal(signal.SIGALRM, timeout_handler)
signal.alarm(30) # triger alarm in 30 seconds in gmail_slurpy.py works for me on my windows machine. the signal object does not have the attributes sigalrm nor alarm |
Can you please send a pull request, and I'll merge it? On Wed, Aug 13, 2014 at 3:29 AM, Basil Muhammad [email protected]
Russell Jurney twitter.com/rjurney [email protected] datasyndrome.com |
Hello,
I have a problem when I execute the gmail.py script (ch03/gmail/gmail.py): the email collection does not occur and the "Timeout exception occured!" message is displayed (tested on Mac OS X 10.6 and Linux Debian in a virtual machine running Windows).
Note that the timeout error is displayed even when running the script without specifying any parameters (to display the usage message).
Jean-Baptiste
The text was updated successfully, but these errors were encountered: