Skip to content
This repository was archived by the owner on Oct 29, 2024. It is now read-only.

Commit 764e09f

Browse files
committed
PEP8 indentation
1 parent 11b20c5 commit 764e09f

3 files changed

Lines changed: 15 additions & 14 deletions

File tree

examples/tutorial.py

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,14 @@ def main(host=None, port=None):
1010
dbuser = 'smly'
1111
dbuser_password = 'my_secret_password'
1212
query = 'select column_one from foo;'
13-
json_body = [
14-
{
15-
"points": [
16-
["1", 1, 1.0],
17-
["2", 2, 2.0]
18-
],
19-
"name": "foo",
20-
"columns": ["column_one", "column_two", "column_three"]
21-
}
22-
]
23-
13+
json_body = [{
14+
"points": [
15+
["1", 1, 1.0],
16+
["2", 2, 2.0]
17+
],
18+
"name": "foo",
19+
"columns": ["column_one", "column_two", "column_three"]
20+
}]
2421

2522
client = InfluxDBClient(host, port, user, password, dbname)
2623

setup.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@
1717

1818

1919
with open(os.path.join(os.path.dirname(__file__),
20-
'influxdb', '__init__.py')) as f:
21-
version = re.search("__version__ = '([^']+)'", f.read()).group(1)
20+
'influxdb',
21+
'__init__.py')) as f:
22+
version = re.search("__version__ = '([^']+)'", f.read()).group(1)
2223

2324
with open('requirements.txt', 'r') as f:
2425
requires = [x.strip() for x in f if x.strip()]

tests/influxdb/client_test.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,10 @@ def test_remove_scheduled_delete(self):
100100
cli.remove_scheduled_delete(1)
101101

102102
def test_query(self):
103-
expected = """[{"name":"foo","columns":["time","sequence_number","column_one"],"points":[[1383876043,16,"2"],[1383876043,15,"1"],[1383876035,14,"2"],[1383876035,13,"1"]]}]"""
103+
expected = ('[{"name":"foo",'
104+
'"columns":["time","sequence_number","column_one"],'
105+
'"points":[[1383876043,16,"2"],[1383876043,15,"1"],'
106+
'[1383876035,14,"2"],[1383876035,13,"1"]]}]')
104107
with patch.object(session, 'get') as mocked_get:
105108
mocked_get.return_value = _build_response_object(
106109
status_code=200,

0 commit comments

Comments
 (0)