Skip to content

Commit 831bece

Browse files
committed
Merge pull request influxdata#128 from influxdb/dual_lib
Bring back 0.8 support
2 parents 08f1c3d + f95bd82 commit 831bece

File tree

11 files changed

+2298
-9
lines changed

11 files changed

+2298
-9
lines changed

README.rst

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,10 @@ InfluxDB is an open-source distributed time series database, find more about Inf
3636

3737
.. _installation:
3838

39-
InfluxDB < 0.9.0
40-
================
39+
InfluxDB v0.8.X users
40+
=====================
4141

42-
This library only supports InfluxDB>=0.9.0. Users of previous versions of InfluxDB may use the influxdb_0.8 branch.
43-
44-
You may install it from pip with the following command::
45-
46-
$ pip install https://github.com/influxdb/influxdb-python/archive/influxdb_0.8.zip
42+
Influxdb >=0.9.0 brings many breaking changes to the API. InfluxDB 0.8.X users may use the legacy client by using ``from influxdb.influxdb08 import InfluxDBClient`` instead.
4743

4844
Installation
4945
============

influxdb/influxdb08/__init__.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# -*- coding: utf-8 -*-
2+
from .client import InfluxDBClient
3+
from .dataframe_client import DataFrameClient
4+
from .helper import SeriesHelper
5+
6+
7+
__all__ = [
8+
'InfluxDBClient',
9+
'DataFrameClient',
10+
'SeriesHelper',
11+
]

influxdb/influxdb08/chunked_json.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# -*- coding: utf-8 -*-
2+
3+
#
4+
# Author: Adrian Sampson <adrian@radbox.org>
5+
# Source: https://gist.github.com/sampsyo/920215
6+
#
7+
8+
import json
9+
10+
_decoder = json.JSONDecoder()
11+
12+
13+
def loads(s):
14+
"""A generator reading a sequence of JSON values from a string."""
15+
while s:
16+
s = s.strip()
17+
obj, pos = _decoder.raw_decode(s)
18+
if not pos:
19+
raise ValueError('no JSON object found at %i' % pos)
20+
yield obj
21+
s = s[pos:]

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy