Skip to content

Commit

Permalink
Enforce flake8 check
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Kukushkin committed Jul 10, 2015
1 parent dcad7a3 commit 71fce31
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Expand Up @@ -9,5 +9,6 @@ install:
- pip install coveralls
script:
- python setup.py test
- python setup.py flake8
after_success:
- coveralls
4 changes: 2 additions & 2 deletions helpers/aws.py
@@ -1,5 +1,4 @@
import logging
import re
import requests
from requests.exceptions import RequestException
import yaml
Expand All @@ -9,6 +8,7 @@


class AWSConnection:

def __init__(self, config):
self.available = False
self.config = config
Expand Down Expand Up @@ -43,7 +43,7 @@ def _tag_ebs(self, role):
if not self.available:
return False

tags = {'Name': 'spilo_'+self.cluster_name, 'Role': role, 'Instance': self.instance_id}
tags = {'Name': 'spilo_' + self.cluster_name, 'Role': role, 'Instance': self.instance_id}
try:
conn = boto.ec2.connect_to_region(self.region)
volumes = conn.get_all_volumes(filters={'attachment.instance-id': self.instance_id})
Expand Down
4 changes: 3 additions & 1 deletion helpers/postgresql.py
Expand Up @@ -9,6 +9,7 @@

if sys.hexversion >= 0x03000000:
from urllib.parse import urlparse
long = int
else:
from urlparse import urlparse

Expand Down Expand Up @@ -169,7 +170,8 @@ def should_use_s3_to_create_replica(self, master_connection):

try:
latest_backup = subprocess.check_output(self.wal_e_path.split() + ['backup-list', '--detail', 'LATEST'])
# name last_modified expanded_size_bytes wal_segment_backup_start wal_segment_offset_backup_start wal_segment_backup_stop wal_segment_offset_backup_stop
# name last_modified expanded_size_bytes wal_segment_backup_start wal_segment_offset_backup_start
# wal_segment_backup_stop wal_segment_offset_backup_stop
# base_00000001000000000000007F_00000040 2015-05-18T10:13:25.000Z
# 20310671 00000001000000000000007F 00000040
# 00000001000000000000007F 00000240
Expand Down
2 changes: 1 addition & 1 deletion tests/test_postgresql.py
Expand Up @@ -118,7 +118,7 @@ def set_up(self):
'password': 'rep-pass',
'network': '127.0.0.1/32'},
'parameters': {'foo': 'bar'}, 'recovery_conf': {'foo': 'bar'}},
on_change_callback=lambda state: True)
on_change_callback=lambda state: True)
psycopg2.connect = psycopg2_connect
if not os.path.exists(self.p.data_dir):
os.makedirs(self.p.data_dir)
Expand Down

0 comments on commit 71fce31

Please sign in to comment.