neuronum 5.5.0__py3-none-any.whl → 5.6.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.

Potentially problematic release.


This version of neuronum might be problematic. Click here for more details.

cli/main.py CHANGED
@@ -494,7 +494,7 @@ asyncio.run(main())
494
494
  if app and nodeID:
495
495
 
496
496
  descr = f"{nodeID} App"
497
- partners = ["public"]
497
+ partners = ["private"]
498
498
  stxID = await cell.create_stx(descr, partners)
499
499
 
500
500
 
@@ -504,7 +504,7 @@ asyncio.run(main())
504
504
  }
505
505
  STX = stxID
506
506
  label = "say:hello"
507
- partners = ["public"]
507
+ partners = ["private"]
508
508
  txID = await cell.create_tx(descr, key_values, STX, label, partners)
509
509
 
510
510
 
@@ -919,6 +919,47 @@ async def async_activate(tx, data):
919
919
  click.echo(tx_response)
920
920
 
921
921
 
922
+ @click.command()
923
+ @click.option('--ctx', required=True, help="Circuit ID")
924
+ @click.argument('label', nargs=-1)
925
+ def load(ctx, label):
926
+ if len(label) > 1 and all(Path(x).exists() for x in label):
927
+ label = "*"
928
+ else:
929
+ label = " ".join(label)
930
+
931
+ asyncio.run(async_load(ctx, label))
932
+
933
+
934
+ async def async_load(ctx, label):
935
+ credentials_folder_path = Path.home() / ".neuronum"
936
+ env_path = credentials_folder_path / ".env"
937
+ env_data = {}
938
+
939
+ try:
940
+ with open(env_path, "r") as f:
941
+ for line in f:
942
+ key, value = line.strip().split("=")
943
+ env_data[key] = value
944
+ except FileNotFoundError:
945
+ click.echo("No cell connected. Try: neuronum connect-cell")
946
+ return
947
+ except Exception as e:
948
+ click.echo(f"Error reading .env: {e}")
949
+ return
950
+
951
+ cell = neuronum.Cell(
952
+ host=env_data.get("HOST", ""),
953
+ password=env_data.get("PASSWORD", ""),
954
+ network=env_data.get("NETWORK", ""),
955
+ synapse=env_data.get("SYNAPSE", "")
956
+ )
957
+
958
+ print(label, ctx)
959
+ data = await cell.load(label, ctx)
960
+ click.echo(data)
961
+
962
+
922
963
  cli.add_command(create_cell)
923
964
  cli.add_command(connect_cell)
924
965
  cli.add_command(view_cell)
@@ -932,6 +973,7 @@ cli.add_command(update_node)
932
973
  cli.add_command(disconnect_node)
933
974
  cli.add_command(delete_node)
934
975
  cli.add_command(activate)
976
+ cli.add_command(load)
935
977
 
936
978
 
937
979
  if __name__ == "__main__":
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: neuronum
3
- Version: 5.5.0
3
+ Version: 5.6.0
4
4
  Summary: Official client library to interact with the Neuronum Network
5
5
  Home-page: https://neuronum.net
6
6
  Author: Neuronum Cybernetics
@@ -33,7 +33,7 @@ Dynamic: summary
33
33
  <h1 align="center">
34
34
  <img src="https://neuronum.net/static/neuronum.svg" alt="Neuronum" width="80">
35
35
  </h1>
36
- <h4 align="center">Build, connect, and automate serverless data infrastructures with Neuronum</h4>
36
+ <h4 align="center">Neuronum: A Serverless Data Network in Pure Python</h4>
37
37
 
38
38
  <p align="center">
39
39
  <a href="https://neuronum.net">
@@ -44,7 +44,7 @@ Dynamic: summary
44
44
  </a>
45
45
  <a href="https://pypi.org/project/neuronum/">
46
46
  <img src="https://img.shields.io/pypi/v/neuronum.svg" alt="PyPI Version">
47
- </a>
47
+ </a><br>
48
48
  <img src="https://img.shields.io/badge/Python-3.8%2B-yellow" alt="Python Version">
49
49
  <a href="https://github.com/neuronumcybernetics/neuronum/blob/main/LICENSE.md">
50
50
  <img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License">
@@ -54,15 +54,15 @@ Dynamic: summary
54
54
  ---
55
55
 
56
56
  ### **About Neuronum**
57
- Neuronum is a python framework to build serverless connected app & data gateways automating the processing and distribution of real-time data transmission, storage, and streaming.
57
+ Neuronum empowers developers to build & connect apps, services, and devices into serverless networks able to exchange data in real time
58
58
 
59
59
 
60
60
  ### **Features**
61
61
  **Cell & Nodes**
62
62
  - Cell: Account to connect and interact with Neuronum. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/cell)
63
- - Nodes: Soft- and Hardware components hosting gateways. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/nodes)
63
+ - Nodes: Soft- and Hardware components hosting Neuronum data gateways. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/nodes)
64
64
 
65
- **Gateways**
65
+ **Data Gateways**
66
66
  - Transmitters (TX): Securely transmit and receive data packages. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/transmitters)
67
67
  - Circuits (CTX): Store data in cloud-based key-value-label databases. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/circuits)
68
68
  - Streams (STX): Stream, synchronize, and control data in real time. [Learn More](https://github.com/neuronumcybernetics/neuronum/tree/main/features/streams)
@@ -97,7 +97,7 @@ neuronum connect-cell # connect Cell
97
97
  ### **Build On Neuronum** **[(Build with Node Examples)](https://github.com/neuronumcybernetics/neuronum/tree/main/features/nodes)**
98
98
  Initialize a Node (app template):
99
99
  ```sh
100
- neuronum init-node --app # initialize a Node with app template
100
+ neuronum init-node --app # initialize a Node with app template -> creates a folder named node_<node_id> containing all relevant files
101
101
  ```
102
102
 
103
103
  Change into Node folder
@@ -143,6 +143,6 @@ asyncio.run(main())
143
143
 
144
144
  #### **CLI-based**
145
145
  ```sh
146
- neuronum activate --tx id::tx say:hello
146
+ neuronum activate --tx id::tx 'say:hello'
147
147
  ```
148
148
 
@@ -0,0 +1,10 @@
1
+ cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ cli/main.py,sha256=WIU5suB-SFPzLswA0i6UyDuNhdevl3vWRAbuh0v4QQY,29888
3
+ neuronum/__init__.py,sha256=Drsm263_w3_VWgl1YsKLUr8WwVodqV3TSjqpxLjyq_M,46
4
+ neuronum/neuronum.py,sha256=L8Oz1qcTyOiYMTGfiSKgN5Nu9jcl25jFeJOh0XItPjw,17201
5
+ neuronum-5.6.0.dist-info/licenses/LICENSE.md,sha256=zGst0rjgnp6oFuRVwFwB1Ql4sDXt_nw9xbUR49Gf99A,2008
6
+ neuronum-5.6.0.dist-info/METADATA,sha256=OyxgpKzGQNooCDdXYmOSb58cS18w-Zo3axD9WgPjSwQ,5096
7
+ neuronum-5.6.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
+ neuronum-5.6.0.dist-info/entry_points.txt,sha256=XKYBcRNxGeJpZZkDPsa8HA_RaJ7Km_R_JaUq5T9Nk2U,42
9
+ neuronum-5.6.0.dist-info/top_level.txt,sha256=ru8Fr84cHm6oHr_DcJ8-uaq3RTiuCRFIr6AC8V0zPu4,13
10
+ neuronum-5.6.0.dist-info/RECORD,,
@@ -1,10 +0,0 @@
1
- cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- cli/main.py,sha256=eCsEMdN0pbMjmKrIsMfH8auPtJdqMDHseBpZM_CeiUE,28704
3
- neuronum/__init__.py,sha256=Drsm263_w3_VWgl1YsKLUr8WwVodqV3TSjqpxLjyq_M,46
4
- neuronum/neuronum.py,sha256=L8Oz1qcTyOiYMTGfiSKgN5Nu9jcl25jFeJOh0XItPjw,17201
5
- neuronum-5.5.0.dist-info/licenses/LICENSE.md,sha256=zGst0rjgnp6oFuRVwFwB1Ql4sDXt_nw9xbUR49Gf99A,2008
6
- neuronum-5.5.0.dist-info/METADATA,sha256=IHW67Dn-byFuRrUAyjWvxLD9CMP3DgpQkXHXcyQCyOk,5068
7
- neuronum-5.5.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
- neuronum-5.5.0.dist-info/entry_points.txt,sha256=XKYBcRNxGeJpZZkDPsa8HA_RaJ7Km_R_JaUq5T9Nk2U,42
9
- neuronum-5.5.0.dist-info/top_level.txt,sha256=ru8Fr84cHm6oHr_DcJ8-uaq3RTiuCRFIr6AC8V0zPu4,13
10
- neuronum-5.5.0.dist-info/RECORD,,