cloud-python-vars 0.1.0__tar.gz → 0.1.1__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cloud-python-vars
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: To manage and create raw Python variables on cloud servers.
5
5
  Author-email: ThatOnePythonDev <khakhang2h5e@gmail.com>
6
6
  Classifier: Programming Language :: Python :: 3
@@ -16,7 +16,12 @@ Dynamic: license-file
16
16
 
17
17
  A Python module for managing Cloud Variables.
18
18
 
19
+ ## IMPORTANT NOTES
20
+
21
+ Since this module is built upon the package upstash-redis, you **MUST** visit the website right [here](https://console.upstash.com/redis) to create tokens and the link that are **nessecary** for the following examples.
22
+
19
23
  ## Examples:
24
+
20
25
  ### Example 1 for the `CloudVar` class.
21
26
 
22
27
  ```python
@@ -56,6 +61,7 @@ print(cloudvar.items()) # {}
56
61
  ```
57
62
 
58
63
  ### Example 2 for the class `AsyncCloudVar`.
64
+
59
65
  ```python
60
66
  import cloud_variables as cv
61
67
  import asyncio
@@ -67,29 +73,29 @@ async def main(): # Use asynchronous functions for full functionality access.
67
73
 
68
74
  # Basic assignment
69
75
  async_cloudvar["string"] = "Hello, World!"
70
-
76
+
71
77
  # Retrieving values
72
78
  print(async_cloudvar["string"]) # 'Hello, World!'
73
-
79
+
74
80
  # Advanced mutable objects
75
81
  async_cloudvar["list"] = [1, 2, 3]
76
82
  async_cloudvar["list"].append(4)
77
-
83
+
78
84
  print(async_cloudvar["list"]) # [1, 2, 3, 4]
79
-
85
+
80
86
  # Deleting and popping items
81
87
  async_cloudvar["key1"] = "value1"
82
88
  async_cloudvar["key2"] = "value2"
83
-
89
+
84
90
  del async_cloudvar["key1"] # Deleting keys.
85
91
  value = await async_cloudvar.pop("key2") # Popping keys
86
92
  print(value) # 'value2'
87
-
93
+
88
94
  # Some more methods
89
-
95
+
90
96
  # Retrieving Python key-value pairs as dictionaries
91
97
  print(await async_cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
92
-
98
+
93
99
  # Clearing everything
94
100
  await async_cloudvar.clear()
95
101
  print(await async_cloudvar.items()) # {}
@@ -100,6 +106,7 @@ asyncio.run(main())
100
106
  ## Installation
101
107
 
102
108
  You can easily install the module by typing the command:
109
+
103
110
  ```bash
104
111
  pip install cloud-python-vars
105
112
  ```
@@ -1,91 +1,98 @@
1
- ## Introduction
2
-
3
- A Python module for managing Cloud Variables.
4
-
5
- ## Examples:
6
- ### Example 1 for the `CloudVar` class.
7
-
8
- ```python
9
- import cloud_variables as cv
10
-
11
-
12
- cloudvar = cv.CloudVar("https://apparent-gopher-******.upstash.io", "******") # Use the actual values here.
13
-
14
- # Basic assignment
15
- cloudvar["string"] = "Hello, World!"
16
-
17
- # Retrieving values
18
- print(cloudvar["string"]) # 'Hello, World!'
19
-
20
- # Advanced mutable objects
21
- cloudvar["list"] = [1, 2, 3]
22
- cloudvar["list"].append(4)
23
-
24
- print(cloudvar["list"]) # [1, 2, 3, 4]
25
-
26
- # Deleting and popping items
27
- cloudvar["key1"] = "value1"
28
- cloudvar["key2"] = "value2"
29
-
30
- del cloudvar["key1"] # Deleting keys.
31
- value = cloudvar.pop("key2") # Popping keys
32
- print(value) # 'value2'
33
-
34
- # Some more methods
35
-
36
- # Retrieving Python key-value pairs as dictionaries
37
- print(cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
38
-
39
- # Clearing everything
40
- cloudvar.clear()
41
- print(cloudvar.items()) # {}
42
- ```
43
-
44
- ### Example 2 for the class `AsyncCloudVar`.
45
- ```python
46
- import cloud_variables as cv
47
- import asyncio
48
-
49
-
50
- async def main(): # Use asynchronous functions for full functionality access.
51
- async_cloudvar = cv.AsyncCloudVar("https://apparent-gopher-******.upstash.io", "******") # Use your actual values again.
52
- async_cloudvar.start()
53
-
54
- # Basic assignment
55
- async_cloudvar["string"] = "Hello, World!"
56
-
57
- # Retrieving values
58
- print(async_cloudvar["string"]) # 'Hello, World!'
59
-
60
- # Advanced mutable objects
61
- async_cloudvar["list"] = [1, 2, 3]
62
- async_cloudvar["list"].append(4)
63
-
64
- print(async_cloudvar["list"]) # [1, 2, 3, 4]
65
-
66
- # Deleting and popping items
67
- async_cloudvar["key1"] = "value1"
68
- async_cloudvar["key2"] = "value2"
69
-
70
- del async_cloudvar["key1"] # Deleting keys.
71
- value = await async_cloudvar.pop("key2") # Popping keys
72
- print(value) # 'value2'
73
-
74
- # Some more methods
75
-
76
- # Retrieving Python key-value pairs as dictionaries
77
- print(await async_cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
78
-
79
- # Clearing everything
80
- await async_cloudvar.clear()
81
- print(await async_cloudvar.items()) # {}
82
-
83
- asyncio.run(main())
84
- ```
85
-
86
- ## Installation
87
-
88
- You can easily install the module by typing the command:
89
- ```bash
90
- pip install cloud-python-vars
91
- ```
1
+ ## Introduction
2
+
3
+ A Python module for managing Cloud Variables.
4
+
5
+ ## IMPORTANT NOTES
6
+
7
+ Since this module is built upon the package upstash-redis, you **MUST** visit the website right [here](https://console.upstash.com/redis) to create tokens and the link that are **nessecary** for the following examples.
8
+
9
+ ## Examples:
10
+
11
+ ### Example 1 for the `CloudVar` class.
12
+
13
+ ```python
14
+ import cloud_variables as cv
15
+
16
+
17
+ cloudvar = cv.CloudVar("https://apparent-gopher-******.upstash.io", "******") # Use the actual values here.
18
+
19
+ # Basic assignment
20
+ cloudvar["string"] = "Hello, World!"
21
+
22
+ # Retrieving values
23
+ print(cloudvar["string"]) # 'Hello, World!'
24
+
25
+ # Advanced mutable objects
26
+ cloudvar["list"] = [1, 2, 3]
27
+ cloudvar["list"].append(4)
28
+
29
+ print(cloudvar["list"]) # [1, 2, 3, 4]
30
+
31
+ # Deleting and popping items
32
+ cloudvar["key1"] = "value1"
33
+ cloudvar["key2"] = "value2"
34
+
35
+ del cloudvar["key1"] # Deleting keys.
36
+ value = cloudvar.pop("key2") # Popping keys
37
+ print(value) # 'value2'
38
+
39
+ # Some more methods
40
+
41
+ # Retrieving Python key-value pairs as dictionaries
42
+ print(cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
43
+
44
+ # Clearing everything
45
+ cloudvar.clear()
46
+ print(cloudvar.items()) # {}
47
+ ```
48
+
49
+ ### Example 2 for the class `AsyncCloudVar`.
50
+
51
+ ```python
52
+ import cloud_variables as cv
53
+ import asyncio
54
+
55
+
56
+ async def main(): # Use asynchronous functions for full functionality access.
57
+ async_cloudvar = cv.AsyncCloudVar("https://apparent-gopher-******.upstash.io", "******") # Use your actual values again.
58
+ async_cloudvar.start()
59
+
60
+ # Basic assignment
61
+ async_cloudvar["string"] = "Hello, World!"
62
+
63
+ # Retrieving values
64
+ print(async_cloudvar["string"]) # 'Hello, World!'
65
+
66
+ # Advanced mutable objects
67
+ async_cloudvar["list"] = [1, 2, 3]
68
+ async_cloudvar["list"].append(4)
69
+
70
+ print(async_cloudvar["list"]) # [1, 2, 3, 4]
71
+
72
+ # Deleting and popping items
73
+ async_cloudvar["key1"] = "value1"
74
+ async_cloudvar["key2"] = "value2"
75
+
76
+ del async_cloudvar["key1"] # Deleting keys.
77
+ value = await async_cloudvar.pop("key2") # Popping keys
78
+ print(value) # 'value2'
79
+
80
+ # Some more methods
81
+
82
+ # Retrieving Python key-value pairs as dictionaries
83
+ print(await async_cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
84
+
85
+ # Clearing everything
86
+ await async_cloudvar.clear()
87
+ print(await async_cloudvar.items()) # {}
88
+
89
+ asyncio.run(main())
90
+ ```
91
+
92
+ ## Installation
93
+
94
+ You can easily install the module by typing the command:
95
+
96
+ ```bash
97
+ pip install cloud-python-vars
98
+ ```
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cloud-python-vars
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: To manage and create raw Python variables on cloud servers.
5
5
  Author-email: ThatOnePythonDev <khakhang2h5e@gmail.com>
6
6
  Classifier: Programming Language :: Python :: 3
@@ -16,7 +16,12 @@ Dynamic: license-file
16
16
 
17
17
  A Python module for managing Cloud Variables.
18
18
 
19
+ ## IMPORTANT NOTES
20
+
21
+ Since this module is built upon the package upstash-redis, you **MUST** visit the website right [here](https://console.upstash.com/redis) to create tokens and the link that are **nessecary** for the following examples.
22
+
19
23
  ## Examples:
24
+
20
25
  ### Example 1 for the `CloudVar` class.
21
26
 
22
27
  ```python
@@ -56,6 +61,7 @@ print(cloudvar.items()) # {}
56
61
  ```
57
62
 
58
63
  ### Example 2 for the class `AsyncCloudVar`.
64
+
59
65
  ```python
60
66
  import cloud_variables as cv
61
67
  import asyncio
@@ -67,29 +73,29 @@ async def main(): # Use asynchronous functions for full functionality access.
67
73
 
68
74
  # Basic assignment
69
75
  async_cloudvar["string"] = "Hello, World!"
70
-
76
+
71
77
  # Retrieving values
72
78
  print(async_cloudvar["string"]) # 'Hello, World!'
73
-
79
+
74
80
  # Advanced mutable objects
75
81
  async_cloudvar["list"] = [1, 2, 3]
76
82
  async_cloudvar["list"].append(4)
77
-
83
+
78
84
  print(async_cloudvar["list"]) # [1, 2, 3, 4]
79
-
85
+
80
86
  # Deleting and popping items
81
87
  async_cloudvar["key1"] = "value1"
82
88
  async_cloudvar["key2"] = "value2"
83
-
89
+
84
90
  del async_cloudvar["key1"] # Deleting keys.
85
91
  value = await async_cloudvar.pop("key2") # Popping keys
86
92
  print(value) # 'value2'
87
-
93
+
88
94
  # Some more methods
89
-
95
+
90
96
  # Retrieving Python key-value pairs as dictionaries
91
97
  print(await async_cloudvar.items()) # {'string': 'Hello, World!', 'list': [1, 2, 3, 4]}
92
-
98
+
93
99
  # Clearing everything
94
100
  await async_cloudvar.clear()
95
101
  print(await async_cloudvar.items()) # {}
@@ -100,6 +106,7 @@ asyncio.run(main())
100
106
  ## Installation
101
107
 
102
108
  You can easily install the module by typing the command:
109
+
103
110
  ```bash
104
111
  pip install cloud-python-vars
105
112
  ```
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "cloud-python-vars"
7
- version = "0.1.0"
7
+ version = "0.1.1"
8
8
  authors = [
9
9
  { name="ThatOnePythonDev", email="khakhang2h5e@gmail.com" },
10
10
  ]