RemoteRF 2.0.0__tar.gz → 2.0.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.
Files changed (38) hide show
  1. {remoterf-2.0.0/src/remoteRF.egg-info → remoterf-2.0.1}/PKG-INFO +1 -1
  2. {remoterf-2.0.0 → remoterf-2.0.1}/setup.py +1 -1
  3. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/grpc_client.py +33 -5
  4. {remoterf-2.0.0 → remoterf-2.0.1/src/remoteRF.egg-info}/PKG-INFO +1 -1
  5. {remoterf-2.0.0 → remoterf-2.0.1}/LICENSE +0 -0
  6. {remoterf-2.0.0 → remoterf-2.0.1}/MANIFEST.in +0 -0
  7. {remoterf-2.0.0 → remoterf-2.0.1}/README.md +0 -0
  8. {remoterf-2.0.0 → remoterf-2.0.1}/setup.cfg +0 -0
  9. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/__init__.py +0 -0
  10. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/__init__.py +0 -0
  11. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/grpc/__init__.py +0 -0
  12. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/grpc/grpc_pb2.py +0 -0
  13. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/grpc/grpc_pb2_grpc.py +0 -0
  14. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/tos_notice.txt +0 -0
  15. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/utils/__init__.py +0 -0
  16. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/utils/ansi_codes.py +0 -0
  17. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/utils/api_token.py +0 -0
  18. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/utils/list_string.py +0 -0
  19. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/common/utils/process_arg.py +0 -0
  20. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/config/__init__.py +0 -0
  21. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/config/cert_fetcher.py +0 -0
  22. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/config/config.py +0 -0
  23. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/__init__.py +0 -0
  24. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/acc_login.py +0 -0
  25. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/app.py +0 -0
  26. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/banner_note.txt +0 -0
  27. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/core/grpc_acc.py +0 -0
  28. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/drivers/__init__.py +0 -0
  29. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/drivers/adalm_pluto/__init__.py +0 -0
  30. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/drivers/adalm_pluto/pluto_remote.py +0 -0
  31. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/drivers/dynamic_device.py +0 -0
  32. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/remoterf_cli.py +0 -0
  33. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF/version.py +0 -0
  34. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF.egg-info/SOURCES.txt +0 -0
  35. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF.egg-info/dependency_links.txt +0 -0
  36. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF.egg-info/entry_points.txt +0 -0
  37. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF.egg-info/requires.txt +0 -0
  38. {remoterf-2.0.0 → remoterf-2.0.1}/src/remoteRF.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: remoterf
3
- Version: 2.0.0
3
+ Version: 2.0.1
4
4
  Summary: A python API to remotely access signal centric hardware. Client-side only! Courtesy of Wireless Lab @ UCLA & Prof. Ian Roberts.
5
5
  Author: Ethan Ge
6
6
  Author-email: ethoGalaxy@gmail.com
@@ -6,7 +6,7 @@ with open("README.md", "r", encoding="utf-8") as fh:
6
6
 
7
7
  setup(
8
8
  name="remoterf",
9
- version="2.0.0",
9
+ version="2.0.1",
10
10
  author="Ethan Ge",
11
11
  author_email="ethoGalaxy@gmail.com",
12
12
  description="A python API to remotely access signal centric hardware. Client-side only! Courtesy of Wireless Lab @ UCLA & Prof. Ian Roberts.",
@@ -9,12 +9,40 @@ from ..common.grpc import grpc_pb2
9
9
  from ..common.grpc import grpc_pb2_grpc
10
10
  from ..common.utils import *
11
11
 
12
- load_dotenv(Path.home() / ".config" / "remoterf-client" / ".env")
13
- addr = os.getenv("REMOTERF_ADDR") # "host:port"
14
- ca_path = os.getenv("REMOTERF_CA_CERT") # path to saved CA cert
12
+ _CONFIG_PATH = Path.home() / ".config" / "remoterf-client" / ".env"
13
+ _CONFIG_HELP = (
14
+ "Run:\n"
15
+ " remoterf --config --addr <host:port>\n"
16
+ "Example:\n"
17
+ " remoterf --config --addr 123.45.654.321:12321"
18
+ )
19
+
20
+
21
+ def _load_client_config() -> tuple[str, str]:
22
+ load_dotenv(_CONFIG_PATH)
23
+ addr = (os.getenv("REMOTERF_ADDR") or "").strip().strip('"').strip("'")
24
+ ca_path = (os.getenv("REMOTERF_CA_CERT") or "").strip().strip('"').strip("'")
25
+
26
+ if not addr or not ca_path:
27
+ raise RuntimeError(
28
+ "RemoteRF client is not configured.\n"
29
+ f"Expected REMOTERF_ADDR and REMOTERF_CA_CERT in:\n {_CONFIG_PATH}\n"
30
+ f"{_CONFIG_HELP}"
31
+ )
32
+
33
+ certs_path = Path(ca_path).expanduser()
34
+ if not certs_path.exists():
35
+ raise RuntimeError(
36
+ "RemoteRF client config points to a missing CA certificate.\n"
37
+ f"REMOTERF_CA_CERT={ca_path}\n"
38
+ "Re-run RemoteRF client config to fetch the certificate again.\n"
39
+ f"{_CONFIG_HELP}"
40
+ )
41
+
42
+ return addr, ca_path
43
+
15
44
 
16
- addr = addr.strip().strip('"').strip("'")
17
- ca_path = ca_path.strip().strip('"').strip("'")
45
+ addr, ca_path = _load_client_config()
18
46
 
19
47
  options = [
20
48
  ('grpc.max_send_message_length', 100 * 1024 * 1024),
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: remoterf
3
- Version: 2.0.0
3
+ Version: 2.0.1
4
4
  Summary: A python API to remotely access signal centric hardware. Client-side only! Courtesy of Wireless Lab @ UCLA & Prof. Ian Roberts.
5
5
  Author: Ethan Ge
6
6
  Author-email: ethoGalaxy@gmail.com
File without changes
File without changes
File without changes
File without changes