Skip to content

Commit

Permalink
tidy up imports
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-hammant committed Mar 26, 2018
1 parent 74188a9 commit c6c10ac
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 26 deletions.
23 changes: 3 additions & 20 deletions README.md
Expand Up @@ -50,19 +50,12 @@ You'll also need to make a cron job for it - see below

## Installation Prerequisites

If on Raspbian:
Python 3.6 or above:

```
sudo apt install libffi-dev python-backports.ssl
# one of the pips/wheels below needs it
```

Python 2.7.13 or above:

```
brew install python
brew install python3
# (you might have to force link that)
# apt-get for Linux
# you might have to force link that
pip install lxml
pip install BeautifulSoup4
Expand All @@ -76,11 +69,6 @@ pip install jsonpickle

# Running it on the Pi Zero for $1.10 a year in electricity

Note for the Pi's Raspbian, which is running a slightly older version of Python, **install an older version** of IMAPClient:

```
pip install IMAPClient==0.13
```

In `/home/pi`, git clone the repo, and cd into that folder in order to copy a shell script (make it executable too):

Expand Down Expand Up @@ -138,11 +126,6 @@ off the verification of the certificate for the IMAP server
If your IMAP server isn't over SSL (port 993) at all, then you can specify `--notifications-no-ssl` and `--digest-no-ssl`
to unencrypted IMAP (port 143).

# Plans to go to Python3.

... are paused for the time being - I consistently experience a segfault with Python 3.5.1 or above and IMAPClient 1.0.2.
Refer [issue 207](https://github.com/mjs/imapclient/issues/207) for IMAPClient.

# Digest emails are available for these services

## Credit Card usages.
Expand Down
10 changes: 4 additions & 6 deletions digest_emails.py
@@ -1,18 +1,17 @@
import getpass
import os
import sys
import time
import imp
from sys import version_info
import os
from optparse import OptionParser
from socket import gaierror
import backports.ssl as ssl

import imapclient
import sys
import time
from imapclient import IMAPClient

from digesters.digestion_processor import DigestionProcessor


def get_command():
retval = None

Expand Down Expand Up @@ -51,7 +50,6 @@ def check_for_command(cmd):
if __name__ == '__main__':

imp.reload(sys)
# sys.setdefaultencoding('utf8')

# Command Line Args

Expand Down

0 comments on commit c6c10ac

Please sign in to comment.