vantage6 4.7.0rc2__tar.gz → 4.7.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.

Potentially problematic release.


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

Files changed (80) hide show
  1. {vantage6-4.7.0rc2 → vantage6-4.7.1}/PKG-INFO +28 -9
  2. {vantage6-4.7.0rc2 → vantage6-4.7.1}/tests_cli/test_node_cli.py +6 -1
  3. vantage6-4.7.1/vantage6/cli/__build__ +1 -0
  4. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/_version.py +1 -1
  5. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/start.py +7 -3
  6. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/configuration_wizard.py +21 -8
  7. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/create.py +10 -8
  8. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/globals.py +0 -5
  9. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/start.py +4 -4
  10. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/template/server_config.j2 +1 -1
  11. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/test/feature_tester.py +4 -1
  12. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/test/integration_test.py +6 -6
  13. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/PKG-INFO +28 -9
  14. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/requires.txt +2 -2
  15. vantage6-4.7.0rc2/vantage6/cli/__build__ +0 -1
  16. {vantage6-4.7.0rc2 → vantage6-4.7.1}/setup.cfg +0 -0
  17. {vantage6-4.7.0rc2 → vantage6-4.7.1}/setup.py +0 -0
  18. {vantage6-4.7.0rc2 → vantage6-4.7.1}/tests_cli/__init__.py +0 -0
  19. {vantage6-4.7.0rc2 → vantage6-4.7.1}/tests_cli/test_example.py +0 -0
  20. {vantage6-4.7.0rc2 → vantage6-4.7.1}/tests_cli/test_server_cli.py +0 -0
  21. {vantage6-4.7.0rc2 → vantage6-4.7.1}/tests_cli/test_wizard.py +0 -0
  22. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/__init__.py +0 -0
  23. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algorithm/create.py +0 -0
  24. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algorithm/update.py +0 -0
  25. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/attach.py +0 -0
  26. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/files.py +0 -0
  27. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/list.py +0 -0
  28. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/new.py +0 -0
  29. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/remove.py +0 -0
  30. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/algostore/stop.py +0 -0
  31. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/cli.py +0 -0
  32. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/common/decorator.py +0 -0
  33. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/common/start.py +0 -0
  34. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/common/utils.py +0 -0
  35. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/configuration_manager.py +0 -0
  36. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/context/__init__.py +0 -0
  37. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/context/algorithm_store.py +0 -0
  38. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/context/base_server.py +0 -0
  39. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/context/node.py +0 -0
  40. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/context/server.py +0 -0
  41. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/data/olympic_athletes_2016.csv +0 -0
  42. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/remove.py +0 -0
  43. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/start.py +0 -0
  44. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/stop.py +0 -0
  45. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/dev/utils.py +0 -0
  46. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/attach.py +0 -0
  47. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/clean.py +0 -0
  48. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/common/__init__.py +0 -0
  49. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/create_private_key.py +0 -0
  50. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/files.py +0 -0
  51. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/list.py +0 -0
  52. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/new.py +0 -0
  53. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/remove.py +0 -0
  54. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/set_api_key.py +0 -0
  55. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/start.py +0 -0
  56. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/stop.py +0 -0
  57. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/node/version.py +0 -0
  58. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/rabbitmq/__init__.py +0 -0
  59. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/rabbitmq/definitions.py +0 -0
  60. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/rabbitmq/queue_manager.py +0 -0
  61. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/rabbitmq/rabbitmq.config +0 -0
  62. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/attach.py +0 -0
  63. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/common/__init__.py +0 -0
  64. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/files.py +0 -0
  65. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/import_.py +0 -0
  66. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/list.py +0 -0
  67. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/new.py +0 -0
  68. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/remove.py +0 -0
  69. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/shell.py +0 -0
  70. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/stop.py +0 -0
  71. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/server/version.py +0 -0
  72. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/template/algo_store_config.j2 +0 -0
  73. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/template/node_config.j2 +0 -0
  74. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/template/server_import_config.j2 +0 -0
  75. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/test/common/diagnostic_runner.py +0 -0
  76. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6/cli/utils.py +0 -0
  77. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/SOURCES.txt +0 -0
  78. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/dependency_links.txt +0 -0
  79. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/entry_points.txt +0 -0
  80. {vantage6-4.7.0rc2 → vantage6-4.7.1}/vantage6.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: vantage6
3
- Version: 4.7.0rc2
3
+ Version: 4.7.1
4
4
  Summary: vantage6 command line interface
5
5
  Home-page: https://github.com/vantage6/vantage6
6
6
  Requires-Python: >=3.10
@@ -44,13 +44,24 @@ You can find more (user) documentation at [readthedocs (docs.vantage6.ai)](https
44
44
 
45
45
  ![Vantage6 architecture overview](docs/images/overview-infrastructure.png)
46
46
 
47
- _A High level overview of the vantage6 infrastructure. Vantage6 has both a client-server and peer-to-peer architecture. The client is used by the researcher to create (PET) computation requests. It is also used to manage users, organizations and collaborations. The server contains users, organizations, collaborations, tasks and their results. It provides a central access point for both the clients and nodes. The nodes have access to privacy sensitive data and handle computation requests retrieved from the server. Computation request are executed as separate containers on the node. These containers are connected to containers at other nodes by a VPN network._
47
+ _A High level overview of the vantage6 infrastructure. Vantage6 has both a
48
+ client-server and peer-to-peer architecture. The client is used by the researcher to
49
+ create (PET) computation requests. It is also used to manage users, organizations and
50
+ collaborations. The server contains users, organizations, collaborations, tasks and
51
+ their results. It provides a central access point for both the clients and nodes. The
52
+ nodes have access to privacy sensitive data and handle computation requests retrieved
53
+ from the server. Computation request are executed as separate containers on the node.
54
+ These containers are connected to containers at other nodes by a VPN network._
48
55
 
49
56
  ## :books: Quickstart
50
57
 
51
58
  ### Requirements
52
59
 
53
- The **vantage6** infrastructure is delivered in Docker images. To run these images, you need to have [Docker](https://docs.docker.com/get-docker/) installed. To install the latest version of the vantage6 CLI, you need to have [Python](https://www.python.org/downloads/), we recommend using an environment manager like [mini-conda](https://docs.conda.io/en/latest/miniconda.html).
60
+ The **vantage6** infrastructure is delivered in Docker images. To run these images, you
61
+ need to have [Docker](https://docs.docker.com/get-docker/) installed. To install the
62
+ latest version of the vantage6 CLI, you need to have
63
+ [Python](https://www.python.org/downloads/), we recommend using an environment manager
64
+ like [mini-conda](https://docs.conda.io/en/latest/miniconda.html).
54
65
 
55
66
  Install the latest version of the vantage6 CLI by using:
56
67
 
@@ -86,7 +97,9 @@ v6 node attach
86
97
  v6 server attach
87
98
  ```
88
99
 
89
- From here you can use the [vantage6-client](https://pypi.org/project/vantage6-client) to interact with the server. The demo network has a pre-configured organization with the following credentials:
100
+ From here you can use the [vantage6-client](https://pypi.org/project/vantage6-client)
101
+ to interact with the server. The demo network has a pre-configured organization with
102
+ the following credentials:
90
103
 
91
104
  - Username: `dev_admin`
92
105
  - Password: `password`
@@ -96,7 +109,7 @@ For example, you can create a new organization by running:
96
109
  ```python
97
110
  from vantage6.client import Client
98
111
 
99
- client = Client('http://127.0.0.1', 5000, '/api', log_level='debug')
112
+ client = Client('http://127.0.0.1', 7601, '/api', log_level='debug')
100
113
  client.authenticate('dev_admin', 'password')
101
114
  client.setup_encryption(None)
102
115
 
@@ -110,7 +123,8 @@ client.organization.create(
110
123
  )
111
124
  ```
112
125
 
113
- You can find more (user) documentation at [readthedocs (docs.vantage6.ai)](https://docs.vantage6.ai)
126
+ You can find more (user) documentation at
127
+ [readthedocs (docs.vantage6.ai)](https://docs.vantage6.ai)
114
128
 
115
129
  ## Project structure
116
130
 
@@ -135,14 +149,16 @@ easily.
135
149
 
136
150
  ### Docker images
137
151
 
138
- The vantage6 infrastructure is delivered in Docker images. All Docker images are stored in our private [Harbor](https://goharbor.io/) registry. The most important images are:
152
+ The vantage6 infrastructure is delivered in Docker images. All Docker images are stored
153
+ in our private [Harbor](https://goharbor.io/) registry. The most important images are:
139
154
 
140
155
  - `harbor2.vantage6.ai/infrastructure/node:VERSION` -> _Node application Docker image_
141
156
  - `harbor2.vantage6.ai/infrastructure/server:VERSION` -> _Server application Docker image_
142
157
  - `harbor2.vantage6.ai/infrastructure/ui:VERSION` -> _User interface Docker image_
143
158
  - `harbor2.vantage6.ai/infrastructure/algorithm-store:VERSION` -> _Algorithm store Docker image_
144
159
 
145
- with `VERSION` being the full semantic version of the vantage6 infrastructure, e.g. `4.0.0` or `4.1.0rc0`.
160
+ with `VERSION` being the full semantic version of the vantage6 infrastructure, e.g.
161
+ `4.0.0` or `4.1.0rc0`.
146
162
 
147
163
  Several other images are used to support the infrastructure:
148
164
 
@@ -160,7 +176,10 @@ And finally there are some images released for algorithm development:
160
176
 
161
177
  ## :gift_heart: Join the community!
162
178
 
163
- We hope to continue developing, improving, and supporting **vantage6** with the help of the federated learning community. If you are interested in contributing, first of all, thank you! Second, please take a look at our [contributing guidelines](https://docs.vantage6.ai/en/main/devops/contribute.html)
179
+ We hope to continue developing, improving, and supporting **vantage6** with the help of
180
+ the federated learning community. If you are interested in contributing, first of all,
181
+ thank you! Second, please take a look at our
182
+ [contributing guidelines](https://docs.vantage6.ai/en/main/devops/contribute.html)
164
183
 
165
184
  <a href="https://github.com/vantage6/vantage6/graphs/contributors">
166
185
  <img src="https://contrib.rocks/image?repo=vantage6/vantage6" />
@@ -9,6 +9,7 @@ from io import BytesIO, StringIO
9
9
  from click.testing import CliRunner
10
10
  from docker.errors import APIError
11
11
 
12
+ from vantage6.common.globals import Ports
12
13
  from vantage6.cli.globals import APPNAME
13
14
  from vantage6.common import STRING_ENCODING
14
15
  from vantage6.cli.common.utils import print_log_worker
@@ -408,7 +409,11 @@ class NodeCLITest(unittest.TestCase):
408
409
  @patch("vantage6.cli.node.common.q")
409
410
  def test_client(self, q, client, error, debug, info):
410
411
  ctx = MagicMock(
411
- config={"server_url": "localhost", "port": 5000, "api_path": ""}
412
+ config={
413
+ "server_url": "localhost",
414
+ "port": Ports.DEV_SERVER.value,
415
+ "api_path": "",
416
+ }
412
417
  )
413
418
 
414
419
  # should not trigger an exception
@@ -0,0 +1 @@
1
+ 0
@@ -7,7 +7,7 @@ with open(os.path.join(here, "__build__")) as fp:
7
7
  __build__ = json.load(fp)
8
8
 
9
9
  # Module version
10
- version_info = (4, 7, 0, "candidate", __build__, 0)
10
+ version_info = (4, 7, 1, "final", __build__, 0)
11
11
 
12
12
  # Module version stage suffix map
13
13
  _specifier_ = {"alpha": "a", "beta": "b", "candidate": "rc", "final": ""}
@@ -1,7 +1,12 @@
1
1
  import click
2
2
 
3
3
  from vantage6.common import info
4
- from vantage6.common.globals import APPNAME, DEFAULT_ALGO_STORE_IMAGE, InstanceType
4
+ from vantage6.common.globals import (
5
+ APPNAME,
6
+ DEFAULT_ALGO_STORE_IMAGE,
7
+ InstanceType,
8
+ Ports,
9
+ )
5
10
  from vantage6.cli.common.start import (
6
11
  attach_logs,
7
12
  check_for_start,
@@ -11,7 +16,6 @@ from vantage6.cli.common.start import (
11
16
  mount_source,
12
17
  pull_infra_image,
13
18
  )
14
- from vantage6.cli.globals import AlgoStoreGlobals
15
19
  from vantage6.cli.context.algorithm_store import AlgorithmStoreContext
16
20
  from vantage6.cli.common.decorator import click_insert_context
17
21
 
@@ -80,7 +84,7 @@ def cli_algo_store_start(
80
84
  info(cmd)
81
85
 
82
86
  info("Run Docker container")
83
- port_ = str(port or ctx.config["port"] or AlgoStoreGlobals.PORT)
87
+ port_ = str(port or ctx.config["port"] or Ports.DEV_ALGO_STORE.value)
84
88
  container = docker_client.containers.run(
85
89
  image,
86
90
  command=cmd,
@@ -3,7 +3,7 @@ import questionary as q
3
3
  from pathlib import Path
4
4
 
5
5
  from vantage6.common import generate_apikey
6
- from vantage6.common.globals import DATABASE_TYPES, InstanceType, NodePolicy
6
+ from vantage6.common.globals import DATABASE_TYPES, InstanceType, NodePolicy, Ports
7
7
  from vantage6.common.client.node_client import NodeClient
8
8
  from vantage6.common.context import AppContext
9
9
  from vantage6.common import error, warning, info
@@ -12,7 +12,6 @@ from vantage6.cli.configuration_manager import (
12
12
  NodeConfigurationManager,
13
13
  ServerConfigurationManager,
14
14
  )
15
- from vantage6.cli.globals import AlgoStoreGlobals, ServerGlobals
16
15
 
17
16
 
18
17
  def node_configuration_questionaire(dirs: dict, instance_name: str) -> dict:
@@ -40,11 +39,25 @@ def node_configuration_questionaire(dirs: dict, instance_name: str) -> dict:
40
39
  "message": "The base-URL of the server:",
41
40
  "default": "http://localhost",
42
41
  },
42
+ ]
43
+ )
44
+ # remove trailing slash from server_url if entered by user
45
+ config["server_url"] = config["server_url"].rstrip("/")
46
+
47
+ # set default port to the https port if server_url is https
48
+ default_port = (
49
+ str(Ports.HTTPS.value)
50
+ if config["server_url"].startswith("https")
51
+ else str(Ports.DEV_SERVER.value)
52
+ )
53
+
54
+ config = config | q.prompt(
55
+ [
43
56
  {
44
57
  "type": "text",
45
58
  "name": "port",
46
59
  "message": "Enter port to which the server listens:",
47
- "default": "5000",
60
+ "default": default_port,
48
61
  },
49
62
  {
50
63
  "type": "text",
@@ -107,12 +120,12 @@ def node_configuration_questionaire(dirs: dict, instance_name: str) -> dict:
107
120
  "Do you want to enter a list of allowed algorithms?"
108
121
  ).ask()
109
122
  if ask_single_algorithms:
110
- policies[NodePolicy.ALLOWED_ALGORITHMS] = _get_allowed_algorithms()
123
+ policies[NodePolicy.ALLOWED_ALGORITHMS.value] = _get_allowed_algorithms()
111
124
  ask_algorithm_stores = q.confirm(
112
125
  "Do you want to allow algorithms from specific algorithm stores?"
113
126
  ).ask()
114
127
  if ask_algorithm_stores:
115
- policies[NodePolicy.ALLOWED_ALGORITHM_STORES] = (
128
+ policies[NodePolicy.ALLOWED_ALGORITHM_STORES.value] = (
116
129
  _get_allowed_algorithm_stores()
117
130
  )
118
131
  if ask_single_algorithms and ask_algorithm_stores:
@@ -291,9 +304,9 @@ def _get_common_server_config(
291
304
  "message": "Enter port to which the server listens:",
292
305
  "default": (
293
306
  # Note that .value is required in YAML to get proper str value
294
- ServerGlobals.PORT.value
307
+ str(Ports.DEV_SERVER.value)
295
308
  if instance_type == InstanceType.SERVER
296
- else AlgoStoreGlobals.PORT.value
309
+ else str(Ports.DEV_ALGO_STORE.value)
297
310
  ),
298
311
  },
299
312
  ]
@@ -489,7 +502,7 @@ def algo_store_configuration_questionaire(instance_name: str) -> dict:
489
502
  InstanceType.ALGORITHM_STORE, instance_name, include_api_path=False
490
503
  )
491
504
 
492
- default_v6_server_uri = "http://localhost:5000/api"
505
+ default_v6_server_uri = f"http://localhost:{Ports.DEV_SERVER.value}/api"
493
506
  default_root_username = "root"
494
507
 
495
508
  v6_server_uri = q.text(
@@ -7,7 +7,7 @@ import pandas as pd
7
7
  from jinja2 import Environment, FileSystemLoader
8
8
  from colorama import Fore, Style
9
9
 
10
- from vantage6.common.globals import APPNAME, InstanceType
10
+ from vantage6.common.globals import APPNAME, InstanceType, Ports
11
11
  from vantage6.common import info, error, generate_apikey
12
12
 
13
13
  import vantage6.cli.dev.data as data_dir
@@ -479,20 +479,22 @@ def demo_network(
479
479
  "-p",
480
480
  "--server-port",
481
481
  type=int,
482
- default=7601,
483
- help="Port to run the server on. Default is 7601.",
482
+ default=Ports.DEV_SERVER.value,
483
+ help=f"Port to run the server on. Default is {Ports.DEV_SERVER.value}.",
484
484
  )
485
485
  @click.option(
486
486
  "--ui-port",
487
487
  type=int,
488
- default=7600,
489
- help="Port to run the UI on. Default is 7600.",
488
+ default=Ports.DEV_UI.value,
489
+ help=f"Port to run the UI on. Default is {Ports.DEV_UI.value}.",
490
490
  )
491
491
  @click.option(
492
492
  "--algorithm-store-port",
493
493
  type=int,
494
- default=7602,
495
- help="Port to run the algorithm store on. Default is 7602.",
494
+ default=Ports.DEV_ALGO_STORE.value,
495
+ help=(
496
+ f"Port to run the algorithm store on. Default is {Ports.DEV_ALGO_STORE.value}."
497
+ ),
496
498
  )
497
499
  @click.option(
498
500
  "-i",
@@ -580,7 +582,7 @@ def create_demo_network(
580
582
  )
581
583
  info(
582
584
  "Development network was set up successfully! You can now start the "
583
- f"server and nodes with {Fore.GREEN}v6 server start-demo-network"
585
+ f"server and nodes with {Fore.GREEN}v6 dev start-demo-network"
584
586
  f"{Style.RESET_ALL}"
585
587
  )
586
588
  # find user credentials to print. Read from server import file
@@ -33,9 +33,6 @@ DATA_FOLDER = PACKAGE_FOLDER / APPNAME / "_data"
33
33
  # Maximum time to start up RabbitMQ in seconds
34
34
  RABBIT_TIMEOUT = 300
35
35
 
36
- # Default port to start the UI on
37
- DEFAULT_UI_PORT = 5001
38
-
39
36
  # Location of repository to create new algorithm templates from
40
37
  ALGORITHM_TEMPLATE_REPO = "gh:vantage6/v6-algorithm-template.git"
41
38
 
@@ -58,7 +55,6 @@ class ServerGlobals(str, Enum):
58
55
 
59
56
  DB_URI_ENV_VAR = "VANTAGE6_DB_URI"
60
57
  CONFIG_NAME_ENV_VAR = "VANTAGE6_CONFIG_NAME"
61
- PORT = "5000"
62
58
 
63
59
 
64
60
  class AlgoStoreGlobals(str, Enum):
@@ -66,4 +62,3 @@ class AlgoStoreGlobals(str, Enum):
66
62
 
67
63
  DB_URI_ENV_VAR = "VANTAGE6_ALGO_STORE_DB_URI"
68
64
  CONFIG_NAME_ENV_VAR = "VANTAGE6_ALGO_STORE_CONFIG_NAME"
69
- PORT = "5002" # 5001 is the default UI port
@@ -11,7 +11,7 @@ from vantage6.common.globals import (
11
11
  InstanceType,
12
12
  )
13
13
 
14
- from vantage6.cli.globals import DEFAULT_UI_PORT, ServerGlobals
14
+ from vantage6.common.globals import Ports
15
15
  from vantage6.cli.context.server import ServerContext
16
16
  from vantage6.cli.rabbitmq.queue_manager import RabbitMQManager
17
17
  from vantage6.cli.server.common import stop_ui
@@ -151,7 +151,7 @@ def cli_server_start(
151
151
  info(cmd)
152
152
 
153
153
  info("Run Docker container")
154
- port_ = str(port or ctx.config["port"] or ServerGlobals.PORT)
154
+ port_ = str(port or ctx.config["port"] or Ports.DEV_SERVER.value)
155
155
  container = docker_client.containers.run(
156
156
  image,
157
157
  command=cmd,
@@ -222,9 +222,9 @@ def _start_ui(client: DockerClient, ctx: ServerContext, ui_port: int) -> None:
222
222
  if not isinstance(ui_port, int) or not 0 < ui_port < 65536:
223
223
  warning(
224
224
  f"UI port '{ui_port}' is not valid! Using default port "
225
- f"{DEFAULT_UI_PORT}"
225
+ f"{Ports.DEV_UI.value}"
226
226
  )
227
- ui_port = DEFAULT_UI_PORT
227
+ ui_port = str(Ports.DEV_UI.value)
228
228
 
229
229
  # find image to use
230
230
  image = get_image(None, ctx, "ui", DEFAULT_UI_IMAGE)
@@ -30,6 +30,6 @@ dev:
30
30
  host_uri: {{ host_uri }}
31
31
  server_url: http://localhost:{{ port }}/api
32
32
  ui:
33
- enable: true
33
+ enabled: true
34
34
  port: {{ ui_port }}
35
35
  {{ user_provided_config }}
@@ -1,6 +1,7 @@
1
1
  import sys
2
2
  import click
3
3
 
4
+ from vantage6.common.globals import Ports
4
5
  from vantage6.client import UserClient
5
6
  from vantage6.cli.utils import error
6
7
  from vantage6.cli.test.common.diagnostic_runner import DiagnosticRunner
@@ -8,7 +9,9 @@ from vantage6.cli.test.common.diagnostic_runner import DiagnosticRunner
8
9
 
9
10
  @click.command()
10
11
  @click.option("--host", type=str, default="http://localhost", help="URL of the server")
11
- @click.option("--port", type=int, default=5000, help="Port of the server")
12
+ @click.option(
13
+ "--port", type=int, default=Ports.DEV_SERVER.value, help="Port of the server"
14
+ )
12
15
  @click.option("--api-path", type=str, default="/api", help="API path of the server")
13
16
  @click.option(
14
17
  "--username",
@@ -1,6 +1,7 @@
1
1
  from pathlib import Path
2
2
  import click
3
3
 
4
+ from vantage6.common.globals import Ports
4
5
  from vantage6.cli.utils import info
5
6
  from vantage6.cli.dev.create import create_demo_network
6
7
  from vantage6.cli.dev.start import start_demo_network
@@ -74,7 +75,7 @@ def cli_test_integration(
74
75
  name=name,
75
76
  num_nodes=3,
76
77
  server_url=server_url,
77
- server_port=5000,
78
+ server_port=Ports.DEV_SERVER.value,
78
79
  image=image,
79
80
  extra_server_config=extra_server_config,
80
81
  extra_node_config=extra_node_config,
@@ -84,7 +85,6 @@ def cli_test_integration(
84
85
  click_ctx.invoke(
85
86
  start_demo_network,
86
87
  name=name,
87
- system_folders=True,
88
88
  server_image=image,
89
89
  node_image=image,
90
90
  )
@@ -98,7 +98,7 @@ def cli_test_integration(
98
98
  diagnose_results = click_ctx.invoke(
99
99
  cli_test_features,
100
100
  host="http://localhost",
101
- port=5000,
101
+ port=Ports.DEV_SERVER.value,
102
102
  api_path="/api",
103
103
  username="dev_admin",
104
104
  password="password",
@@ -110,12 +110,12 @@ def cli_test_integration(
110
110
  )
111
111
 
112
112
  # clean up the test resources
113
- click_ctx.invoke(stop_demo_network, name=name, system_folders=True)
113
+ click_ctx.invoke(stop_demo_network, name=name)
114
114
  if not keep:
115
- click_ctx.invoke(remove_demo_network, name=name, system_folders=True)
115
+ click_ctx.invoke(remove_demo_network, name=name)
116
116
  else:
117
117
  info(
118
- "Keeping the demo network {name}. You can start it with `v6 dev "
118
+ f"Keeping the demo network {name}. You can start it with `v6 dev "
119
119
  "start-demo-network`"
120
120
  )
121
121
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: vantage6
3
- Version: 4.7.0rc2
3
+ Version: 4.7.1
4
4
  Summary: vantage6 command line interface
5
5
  Home-page: https://github.com/vantage6/vantage6
6
6
  Requires-Python: >=3.10
@@ -44,13 +44,24 @@ You can find more (user) documentation at [readthedocs (docs.vantage6.ai)](https
44
44
 
45
45
  ![Vantage6 architecture overview](docs/images/overview-infrastructure.png)
46
46
 
47
- _A High level overview of the vantage6 infrastructure. Vantage6 has both a client-server and peer-to-peer architecture. The client is used by the researcher to create (PET) computation requests. It is also used to manage users, organizations and collaborations. The server contains users, organizations, collaborations, tasks and their results. It provides a central access point for both the clients and nodes. The nodes have access to privacy sensitive data and handle computation requests retrieved from the server. Computation request are executed as separate containers on the node. These containers are connected to containers at other nodes by a VPN network._
47
+ _A High level overview of the vantage6 infrastructure. Vantage6 has both a
48
+ client-server and peer-to-peer architecture. The client is used by the researcher to
49
+ create (PET) computation requests. It is also used to manage users, organizations and
50
+ collaborations. The server contains users, organizations, collaborations, tasks and
51
+ their results. It provides a central access point for both the clients and nodes. The
52
+ nodes have access to privacy sensitive data and handle computation requests retrieved
53
+ from the server. Computation request are executed as separate containers on the node.
54
+ These containers are connected to containers at other nodes by a VPN network._
48
55
 
49
56
  ## :books: Quickstart
50
57
 
51
58
  ### Requirements
52
59
 
53
- The **vantage6** infrastructure is delivered in Docker images. To run these images, you need to have [Docker](https://docs.docker.com/get-docker/) installed. To install the latest version of the vantage6 CLI, you need to have [Python](https://www.python.org/downloads/), we recommend using an environment manager like [mini-conda](https://docs.conda.io/en/latest/miniconda.html).
60
+ The **vantage6** infrastructure is delivered in Docker images. To run these images, you
61
+ need to have [Docker](https://docs.docker.com/get-docker/) installed. To install the
62
+ latest version of the vantage6 CLI, you need to have
63
+ [Python](https://www.python.org/downloads/), we recommend using an environment manager
64
+ like [mini-conda](https://docs.conda.io/en/latest/miniconda.html).
54
65
 
55
66
  Install the latest version of the vantage6 CLI by using:
56
67
 
@@ -86,7 +97,9 @@ v6 node attach
86
97
  v6 server attach
87
98
  ```
88
99
 
89
- From here you can use the [vantage6-client](https://pypi.org/project/vantage6-client) to interact with the server. The demo network has a pre-configured organization with the following credentials:
100
+ From here you can use the [vantage6-client](https://pypi.org/project/vantage6-client)
101
+ to interact with the server. The demo network has a pre-configured organization with
102
+ the following credentials:
90
103
 
91
104
  - Username: `dev_admin`
92
105
  - Password: `password`
@@ -96,7 +109,7 @@ For example, you can create a new organization by running:
96
109
  ```python
97
110
  from vantage6.client import Client
98
111
 
99
- client = Client('http://127.0.0.1', 5000, '/api', log_level='debug')
112
+ client = Client('http://127.0.0.1', 7601, '/api', log_level='debug')
100
113
  client.authenticate('dev_admin', 'password')
101
114
  client.setup_encryption(None)
102
115
 
@@ -110,7 +123,8 @@ client.organization.create(
110
123
  )
111
124
  ```
112
125
 
113
- You can find more (user) documentation at [readthedocs (docs.vantage6.ai)](https://docs.vantage6.ai)
126
+ You can find more (user) documentation at
127
+ [readthedocs (docs.vantage6.ai)](https://docs.vantage6.ai)
114
128
 
115
129
  ## Project structure
116
130
 
@@ -135,14 +149,16 @@ easily.
135
149
 
136
150
  ### Docker images
137
151
 
138
- The vantage6 infrastructure is delivered in Docker images. All Docker images are stored in our private [Harbor](https://goharbor.io/) registry. The most important images are:
152
+ The vantage6 infrastructure is delivered in Docker images. All Docker images are stored
153
+ in our private [Harbor](https://goharbor.io/) registry. The most important images are:
139
154
 
140
155
  - `harbor2.vantage6.ai/infrastructure/node:VERSION` -> _Node application Docker image_
141
156
  - `harbor2.vantage6.ai/infrastructure/server:VERSION` -> _Server application Docker image_
142
157
  - `harbor2.vantage6.ai/infrastructure/ui:VERSION` -> _User interface Docker image_
143
158
  - `harbor2.vantage6.ai/infrastructure/algorithm-store:VERSION` -> _Algorithm store Docker image_
144
159
 
145
- with `VERSION` being the full semantic version of the vantage6 infrastructure, e.g. `4.0.0` or `4.1.0rc0`.
160
+ with `VERSION` being the full semantic version of the vantage6 infrastructure, e.g.
161
+ `4.0.0` or `4.1.0rc0`.
146
162
 
147
163
  Several other images are used to support the infrastructure:
148
164
 
@@ -160,7 +176,10 @@ And finally there are some images released for algorithm development:
160
176
 
161
177
  ## :gift_heart: Join the community!
162
178
 
163
- We hope to continue developing, improving, and supporting **vantage6** with the help of the federated learning community. If you are interested in contributing, first of all, thank you! Second, please take a look at our [contributing guidelines](https://docs.vantage6.ai/en/main/devops/contribute.html)
179
+ We hope to continue developing, improving, and supporting **vantage6** with the help of
180
+ the federated learning community. If you are interested in contributing, first of all,
181
+ thank you! Second, please take a look at our
182
+ [contributing guidelines](https://docs.vantage6.ai/en/main/devops/contribute.html)
164
183
 
165
184
  <a href="https://github.com/vantage6/vantage6/graphs/contributors">
166
185
  <img src="https://contrib.rocks/image?repo=vantage6/vantage6" />
@@ -9,8 +9,8 @@ questionary==1.10.0
9
9
  rich==13.5.2
10
10
  schema==0.7.5
11
11
  SQLAlchemy==1.4.46
12
- vantage6-common==4.7.0rc2
13
- vantage6-client==4.7.0rc2
12
+ vantage6-common==4.7.1
13
+ vantage6-client==4.7.1
14
14
 
15
15
  [dev]
16
16
  coverage==6.4.4
@@ -1 +0,0 @@
1
- 2
File without changes
File without changes