easyhttp-python 0.3.2__tar.gz → 0.3.3__tar.gz
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.
- {easyhttp_python-0.3.2/easyhttp_python.egg-info → easyhttp_python-0.3.3}/PKG-INFO +3 -3
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/README.md +20 -49
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/README_PY.md +2 -2
- {easyhttp_python-0.3.2/easyhttp → easyhttp_python-0.3.3/easyhttp_python}/__init__.py +1 -1
- {easyhttp_python-0.3.2/easyhttp → easyhttp_python-0.3.3/easyhttp_python}/core.py +1 -1
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3/easyhttp_python.egg-info}/PKG-INFO +3 -3
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/easyhttp_python.egg-info/SOURCES.txt +3 -3
- easyhttp_python-0.3.3/easyhttp_python.egg-info/top_level.txt +1 -0
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/pyproject.toml +2 -2
- easyhttp_python-0.3.2/easyhttp_python.egg-info/top_level.txt +0 -1
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/LICENSE +0 -0
- {easyhttp_python-0.3.2/easyhttp → easyhttp_python-0.3.3/easyhttp_python}/wrapper.py +0 -0
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/easyhttp_python.egg-info/dependency_links.txt +0 -0
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/easyhttp_python.egg-info/requires.txt +0 -0
- {easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: easyhttp-python
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.3
|
|
4
4
|
Summary: Simple HTTP-based P2P framework for IoT
|
|
5
5
|
Author-email: slpuk <yarik6052@gmail.com>
|
|
6
6
|
License: MIT
|
|
@@ -36,7 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
# EasyHTTP
|
|
37
37
|
|
|
38
38
|
[](https://github.com/slpuk/easyhttp-python)
|
|
39
|
-

|
|
40
40
|

|
|
41
41
|

|
|
42
42
|

|
|
@@ -86,7 +86,7 @@ EasyHTTP uses a simple JSON-based command system:
|
|
|
86
86
|
### Basic Example with Callbacks (synchronous)
|
|
87
87
|
```python
|
|
88
88
|
import time
|
|
89
|
-
from
|
|
89
|
+
from easyhttp_python import EasyHTTP
|
|
90
90
|
|
|
91
91
|
# Callback function
|
|
92
92
|
def handle_data(sender_id, data, timestamp):
|
|
@@ -2,57 +2,32 @@
|
|
|
2
2
|
[EN README](README.md) | [RU README](README_RU.md)
|
|
3
3
|
> **A lightweight HTTP-based P2P framework for IoT and device-to-device communication**
|
|
4
4
|
|
|
5
|
-

|
|
6
6
|

|
|
7
7
|

|
|
8
8
|

|
|
9
9
|
|
|
10
10
|
> [!WARNING]
|
|
11
|
-
> **Breaking Changes from 0.2
|
|
11
|
+
> **Breaking Changes from 0.3.2**
|
|
12
12
|
>
|
|
13
13
|
> ### API Changes
|
|
14
|
-
> | 0.2.0 | 0.3.2 | Notes |
|
|
15
|
-
> |--------|--------|-------|
|
|
16
|
-
> | `get()` | `fetch()` | Same functionality |
|
|
17
|
-
> | `pull()` | `push()` | Same functionality |
|
|
18
|
-
> | `'on_get'` | `'on_fetch'` | Callback name |
|
|
19
|
-
> | `'on_data_response'` | `'on_data'` | Callback name |
|
|
20
|
-
> | `'on_pull'` | `'on_push'` | Callback name |
|
|
21
|
-
>
|
|
22
|
-
> ### Migration Example
|
|
23
14
|
> ```python
|
|
24
|
-
> # 0.2
|
|
25
|
-
>
|
|
26
|
-
> easy.get("ABC123")
|
|
27
|
-
> easy.pull("ABC123", data)
|
|
28
|
-
>
|
|
29
|
-
> # 0.3.2 (NEW):
|
|
30
|
-
> # Sync
|
|
31
|
-
> easy = EasyHTTP()
|
|
32
|
-
> easy.fetch("ABC123")
|
|
33
|
-
> easy.push("ABC123", data)
|
|
15
|
+
> # 0.3.2 (OLD)
|
|
16
|
+
> from easyhttp import ...
|
|
34
17
|
>
|
|
35
|
-
> #
|
|
36
|
-
>
|
|
37
|
-
|
|
38
|
-
> await easy.push("ABC123", data)
|
|
39
|
-
> ```
|
|
40
|
-
|
|
18
|
+
> # 0.3.3 (NEW)
|
|
19
|
+
> from easyhttp_python import ...
|
|
20
|
+
>```
|
|
41
21
|
|
|
42
22
|
## 🚀 Quick Start
|
|
43
23
|
|
|
44
24
|
### Installation
|
|
45
|
-
> [!NOTE]
|
|
46
|
-
> Both methods require **Git** to be installed.<br>
|
|
47
|
-
> PyPI upload is **preparing**
|
|
48
25
|
|
|
49
26
|
```bash
|
|
50
|
-
#
|
|
51
|
-
|
|
52
|
-
cd easyhttp-python
|
|
53
|
-
pip install -e .
|
|
27
|
+
# Install by PyPI
|
|
28
|
+
pip install easyhttp-python
|
|
54
29
|
|
|
55
|
-
# Or
|
|
30
|
+
# Or from GitHub
|
|
56
31
|
pip install git+https://github.com/slpuk/easyhttp-python.git
|
|
57
32
|
```
|
|
58
33
|
|
|
@@ -60,7 +35,7 @@ pip install git+https://github.com/slpuk/easyhttp-python.git
|
|
|
60
35
|
Syntax with context managers and full code is supported
|
|
61
36
|
|
|
62
37
|
```python
|
|
63
|
-
from
|
|
38
|
+
from easyhttp_python import EasyHTTP
|
|
64
39
|
|
|
65
40
|
def main():
|
|
66
41
|
# Initialize a device with context manager
|
|
@@ -93,7 +68,7 @@ if __name__ == "__main__":
|
|
|
93
68
|
|
|
94
69
|
```python
|
|
95
70
|
import asyncio
|
|
96
|
-
from
|
|
71
|
+
from easyhttp_python import EasyHTTPAsync
|
|
97
72
|
|
|
98
73
|
async def main():
|
|
99
74
|
# Initialize a device
|
|
@@ -143,7 +118,7 @@ easyhttp-python/
|
|
|
143
118
|
├── docs/
|
|
144
119
|
│ ├── EasyHTTP.md # Sync API reference
|
|
145
120
|
│ └── EasyHTTPAsync.md # Async API reference
|
|
146
|
-
├──
|
|
121
|
+
├── easyhttp_python/
|
|
147
122
|
│ ├── __init__.py
|
|
148
123
|
│ ├── core.py # Main framework file/core
|
|
149
124
|
│ └── wrapper.py # Synchronous wrapper
|
|
@@ -163,6 +138,7 @@ easyhttp-python/
|
|
|
163
138
|
├── .gitignore
|
|
164
139
|
├── LICENSE # MIT license
|
|
165
140
|
├── pyproject.toml # Project config
|
|
141
|
+
├── README_PY.md # Documentation for PyPI
|
|
166
142
|
├── README_RU.md # Russian documentation
|
|
167
143
|
├── README.md # This file
|
|
168
144
|
└── requirements.txt # Project dependencies
|
|
@@ -209,25 +185,20 @@ sequenceDiagram
|
|
|
209
185
|
|
|
210
186
|
## 📦 Installation & Setup
|
|
211
187
|
|
|
212
|
-
###
|
|
213
|
-
> [!NOTE]
|
|
214
|
-
> Both methods require **Git** to be installed.<br>
|
|
215
|
-
> PyPI upload is **preparing**
|
|
188
|
+
### Installation
|
|
216
189
|
|
|
217
190
|
```bash
|
|
218
|
-
# Install
|
|
219
|
-
pip install
|
|
191
|
+
# Install from PyPI
|
|
192
|
+
pip install easyhttp-python
|
|
220
193
|
|
|
221
|
-
# Or
|
|
222
|
-
|
|
223
|
-
cd easyhttp-python
|
|
224
|
-
pip install -e .
|
|
194
|
+
# Or from GitHub
|
|
195
|
+
pip install git+https://github.com/slpuk/easyhttp-python.git
|
|
225
196
|
```
|
|
226
197
|
|
|
227
198
|
### Basic Example with Callbacks(Synchronous)
|
|
228
199
|
```python
|
|
229
200
|
import time
|
|
230
|
-
from
|
|
201
|
+
from easyhttp_python import EasyHTTP
|
|
231
202
|
|
|
232
203
|
# Callback function
|
|
233
204
|
def handle_data(sender_id, data, timestamp):
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# EasyHTTP
|
|
2
2
|
|
|
3
3
|
[](https://github.com/slpuk/easyhttp-python)
|
|
4
|
-

|
|
5
5
|

|
|
6
6
|

|
|
7
7
|

|
|
@@ -51,7 +51,7 @@ EasyHTTP uses a simple JSON-based command system:
|
|
|
51
51
|
### Basic Example with Callbacks (synchronous)
|
|
52
52
|
```python
|
|
53
53
|
import time
|
|
54
|
-
from
|
|
54
|
+
from easyhttp_python import EasyHTTP
|
|
55
55
|
|
|
56
56
|
# Callback function
|
|
57
57
|
def handle_data(sender_id, data, timestamp):
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: easyhttp-python
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.3
|
|
4
4
|
Summary: Simple HTTP-based P2P framework for IoT
|
|
5
5
|
Author-email: slpuk <yarik6052@gmail.com>
|
|
6
6
|
License: MIT
|
|
@@ -36,7 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
# EasyHTTP
|
|
37
37
|
|
|
38
38
|
[](https://github.com/slpuk/easyhttp-python)
|
|
39
|
-

|
|
40
40
|

|
|
41
41
|

|
|
42
42
|

|
|
@@ -86,7 +86,7 @@ EasyHTTP uses a simple JSON-based command system:
|
|
|
86
86
|
### Basic Example with Callbacks (synchronous)
|
|
87
87
|
```python
|
|
88
88
|
import time
|
|
89
|
-
from
|
|
89
|
+
from easyhttp_python import EasyHTTP
|
|
90
90
|
|
|
91
91
|
# Callback function
|
|
92
92
|
def handle_data(sender_id, data, timestamp):
|
|
@@ -2,9 +2,9 @@ LICENSE
|
|
|
2
2
|
README.md
|
|
3
3
|
README_PY.md
|
|
4
4
|
pyproject.toml
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
easyhttp_python/__init__.py
|
|
6
|
+
easyhttp_python/core.py
|
|
7
|
+
easyhttp_python/wrapper.py
|
|
8
8
|
easyhttp_python.egg-info/PKG-INFO
|
|
9
9
|
easyhttp_python.egg-info/SOURCES.txt
|
|
10
10
|
easyhttp_python.egg-info/dependency_links.txt
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
easyhttp_python
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "easyhttp-python"
|
|
7
|
-
version = "0.3.
|
|
7
|
+
version = "0.3.3"
|
|
8
8
|
authors = [
|
|
9
9
|
{name = "slpuk", email = "yarik6052@gmail.com"},
|
|
10
10
|
]
|
|
@@ -48,4 +48,4 @@ dev = [
|
|
|
48
48
|
]
|
|
49
49
|
|
|
50
50
|
[tool.setuptools]
|
|
51
|
-
packages = ["
|
|
51
|
+
packages = ["easyhttp_python"]
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
easyhttp
|
|
File without changes
|
|
File without changes
|
{easyhttp_python-0.3.2 → easyhttp_python-0.3.3}/easyhttp_python.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|