micromegas 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- micromegas/__init__.py +1 -0
- micromegas/request.py +18 -0
- micromegas-0.1.0.dist-info/METADATA +22 -0
- micromegas-0.1.0.dist-info/RECORD +5 -0
- micromegas-0.1.0.dist-info/WHEEL +4 -0
micromegas/__init__.py
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
from . import request
|
micromegas/request.py
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
import cbor2
|
2
|
+
import io
|
3
|
+
import pyarrow.parquet as pq
|
4
|
+
import requests
|
5
|
+
|
6
|
+
def request(url, args):
|
7
|
+
response = requests.post(
|
8
|
+
url,
|
9
|
+
data=cbor2.dumps(args),
|
10
|
+
)
|
11
|
+
if response.status_code != 200:
|
12
|
+
raise Exception(
|
13
|
+
"http request url={2} failed with code={0} text={1}".format(
|
14
|
+
response.status_code, response.text, url
|
15
|
+
)
|
16
|
+
)
|
17
|
+
table = pq.read_table(io.BytesIO(response.content))
|
18
|
+
return table.to_pandas()
|
@@ -0,0 +1,22 @@
|
|
1
|
+
Metadata-Version: 2.1
|
2
|
+
Name: micromegas
|
3
|
+
Version: 0.1.0
|
4
|
+
Summary:
|
5
|
+
Author: Marc-Antoine Desroches
|
6
|
+
Author-email: madesroches@gmail.com
|
7
|
+
Requires-Python: >=3.10,<4.0
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
9
|
+
Classifier: Programming Language :: Python :: 3.10
|
10
|
+
Classifier: Programming Language :: Python :: 3.11
|
11
|
+
Classifier: Programming Language :: Python :: 3.12
|
12
|
+
Requires-Dist: cbor2 (>=5.6.3,<6.0.0)
|
13
|
+
Requires-Dist: pandas (>=2.2.2,<3.0.0)
|
14
|
+
Requires-Dist: pyarrow (>=16.0.0,<17.0.0)
|
15
|
+
Requires-Dist: requests (>=2.31.0,<3.0.0)
|
16
|
+
Requires-Dist: tabulate (>=0.9.0,<0.10.0)
|
17
|
+
Description-Content-Type: text/markdown
|
18
|
+
|
19
|
+
# Micromegas
|
20
|
+
|
21
|
+
Python analytics client for https://github.com/madesroches/micromegas/
|
22
|
+
|
@@ -0,0 +1,5 @@
|
|
1
|
+
micromegas/__init__.py,sha256=rvF3SrKmB7TsdhKv_pURHaj8mEx2HQS0W6x_RONAQcI,22
|
2
|
+
micromegas/request.py,sha256=kdKG6MIffdanhulGafwDz9QLs0SySYHWgtOSKt3jMOs,474
|
3
|
+
micromegas-0.1.0.dist-info/METADATA,sha256=HNrU35LPYCbcom8ptVmzVCcQiE192PUZJnKFJgq2sxU,691
|
4
|
+
micromegas-0.1.0.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
5
|
+
micromegas-0.1.0.dist-info/RECORD,,
|