Skip to content

Commit 3916018

Browse files
committed
Merge branch 'dev' into feature/ecoclient
2 parents 4978446 + 3370fed commit 3916018

File tree

13 files changed

+353
-245
lines changed

13 files changed

+353
-245
lines changed

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ repos:
2323
args: [--branch, main, --branch, dev]
2424
- id: check-added-large-files
2525
- repo: https://github.com/astral-sh/ruff-pre-commit
26-
rev: v0.9.9
26+
rev: v0.9.10
2727
hooks:
2828
- id: ruff
2929
args: [ --fix, --exit-non-zero-on-fix, "--ignore=C901" ]

CHANGELOG.md

Lines changed: 38 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
# Change log
22

3-
## [v2.0.0-rc1](https://github.com/simvue-io/client/releases/tag/v2.0.0rc1) - 2025-03-06
3+
## [v2.0.0](https://github.com/simvue-io/python-api/releases/tag/v2.0.0) - 2025-03-07
44
* Add new example notebooks
55
* Update and refactor examples to work with v2.0
66
* Fix bug in offline artifacts using wrong file path
77
* Change names of sustainability metrics
88
* Fix `Self` being used in typing Generators so that Simvue works with Python 3.10 in Conda
9-
10-
## [v2.0.0-alpha3](https://github.com/simvue-io/client/releases/tag/v2.0.0a3) - 2025-03-04
119
* Updated codecarbon to work with new API
1210
* Codecarbon now works with offline mode
1311
* Codecarbon metadata dict is now nested
@@ -16,8 +14,6 @@
1614
* Fixed list of processes to add / remove from existing list of objects
1715
* Add step to resource metrics
1816
* Fix bug where process user alerts should not be overridden if manually set by the user
19-
20-
## [v2.0.0-alpha2](https://github.com/simvue-io/client/releases/tag/v2.0.0a2) - 2025-02-27
2117
* Removed 'no config file' and 'unstaged changes' warnings from Offline mode as they do not apply
2218
* Made `staging_check` not apply in Offline mode
2319
* Added heartbeat functionality to Offline mode
@@ -29,8 +25,6 @@
2925
* Added `name` option in `log_alert` and added tests
3026
* Fixed client `get_alerts` and improved tests
3127
* Removed all server config checks in Offline mode
32-
33-
## [v2.0.0-alpha1](https://github.com/simvue-io/client/releases/tag/v2.0.0a1) - 2025-02-19
3428
* Fixed `add_alerts` so that it now works with both IDs and names
3529
* Improved alert and folder deduplication methods to rely on 409 responses from server upon creation
3630
* Added `attach_to_run` option to create alerts methods so that alerts can be created without a run attached
@@ -47,9 +41,6 @@
4741
* Fixed bug where errors would be thrown if a traceback was logged as an event when a run was already terminated
4842
* Fixed hierarchical artifact retrieval to maintain directory structure
4943
* Loosened Numpy requirement to >2.0.0
50-
51-
## [v2.0.0-alpha0](https://github.com/simvue-io/client/releases/tag/v2.0.0a0) - 2025-02-10
52-
5344
* Add support for defining Simvue run defaults using `tool.simvue` in a project `pyproject.toml` file.
5445
* Drop support for INI based configuration files.
5546
* Retrieve all metric values if `max_points` is unspecified or set to `None`.
@@ -59,28 +50,29 @@
5950
* Separates `create_alert` into specific methods `create_event_alert` etc.
6051
* Adds additional functionality and support for offline mode.
6152
* Support for Simvue servers `>=3`.
62-
## [v1.1.4](https://github.com/simvue-io/client/releases/tag/v1.1.4) - 2024-12-11
53+
54+
## [v1.1.4](https://github.com/simvue-io/python-api/releases/tag/v1.1.4) - 2024-12-11
6355

6456
* Remove incorrect identifier reference for latest Simvue servers during reconnection.
6557
* Fixed missing online mode selection when retrieving configuration for `Client` class.
6658

67-
## [v1.1.3](https://github.com/simvue-io/client/releases/tag/v1.1.3) - 2024-12-09
59+
## [v1.1.3](https://github.com/simvue-io/python-api/releases/tag/v1.1.3) - 2024-12-09
6860

6961
* Fixed bug with `requirements.txt` metadata read.
7062
* Added Simvue server version check.
7163
* Remove checking of server version in offline mode and add default run mode to configuration options.
7264
* Fix offline mode class initialisation, and propagation of configuration.
7365

74-
## [v1.1.2](https://github.com/simvue-io/client/releases/tag/v1.1.2) - 2024-11-06
66+
## [v1.1.2](https://github.com/simvue-io/python-api/releases/tag/v1.1.2) - 2024-11-06
7567

7668
* Fix bug in offline mode directory retrieval.
7769

78-
## [v1.1.1](https://github.com/simvue-io/client/releases/tag/v1.1.1) - 2024-10-22
70+
## [v1.1.1](https://github.com/simvue-io/python-api/releases/tag/v1.1.1) - 2024-10-22
7971

8072
* Add missing `offline.cache` key to TOML config.
8173
* Fix repetition of server URL validation for each call to configuration.
8274

83-
## [v1.1.0](https://github.com/simvue-io/client/releases/tag/v1.1.0) - 2024-10-21
75+
## [v1.1.0](https://github.com/simvue-io/python-api/releases/tag/v1.1.0) - 2024-10-21
8476

8577
* Add option to specify a callback executed when an alert is triggered for a run.
8678
* Allow retrieval of all alerts when no constraints are specified.
@@ -91,35 +83,35 @@
9183
* Indicate the source used for token and URL.
9284
* Migrate to `simvue.toml` from `simvue.ini`, allowing more defaults to be set during runs.
9385

94-
## [v1.0.6](https://github.com/simvue-io/client/releases/tag/v1.0.6) - 2024-10-10
86+
## [v1.0.6](https://github.com/simvue-io/python-api/releases/tag/v1.0.6) - 2024-10-10
9587

9688
* Fix incorrect usage of `retry` when attempting connections to the server.
9789

98-
## [v1.0.5](https://github.com/simvue-io/client/releases/tag/v1.0.5) - 2024-10-09
90+
## [v1.0.5](https://github.com/simvue-io/python-api/releases/tag/v1.0.5) - 2024-10-09
9991

10092
* Ensure all functionality is deactivated when mode is set to `disabled`.
10193
* When an exception is thrown an event is sent to Simvue displaying the traceback.
10294
* If `add_process` is used and an exception is thrown, `.err` and `.out` files are still uploaded.
10395

104-
## [v1.0.4](https://github.com/simvue-io/client/releases/tag/v1.0.4) - 2024-09-24
96+
## [v1.0.4](https://github.com/simvue-io/python-api/releases/tag/v1.0.4) - 2024-09-24
10597

10698
* Set resource metrics to be recorded by default.
10799

108-
## [v1.0.3](https://github.com/simvue-io/client/releases/tag/v1.0.3) - 2024-09-23
100+
## [v1.0.3](https://github.com/simvue-io/python-api/releases/tag/v1.0.3) - 2024-09-23
109101

110102
* Fix issue of hanging threads when exception raised by script using the API.
111103

112-
## [v1.0.2](https://github.com/simvue-io/client/releases/tag/v1.0.2) - 2024-08-21
104+
## [v1.0.2](https://github.com/simvue-io/python-api/releases/tag/v1.0.2) - 2024-08-21
113105

114106
* Fix incorrect HTTP status code in `Client` when checking if object exists.
115107
* Fix issue with `running=False` when launching a `Run` caused by incorrect system metadata being sent to the server.
116108

117-
## [v1.0.1](https://github.com/simvue-io/client/releases/tag/v1.0.1) - 2024-07-16
109+
## [v1.0.1](https://github.com/simvue-io/python-api/releases/tag/v1.0.1) - 2024-07-16
118110

119111
* Fix to `add_process` with list of strings as arguments, the executable no longer returns the string `"None"`.
120112
* Fix callbacks and triggers for `add_process` being executed only on `Run` class termination, not on process completion.
121113

122-
## [v1.0.0](https://github.com/simvue-io/client/releases/tag/v1.0.0) - 2024-06-14
114+
## [v1.0.0](https://github.com/simvue-io/python-api/releases/tag/v1.0.0) - 2024-06-14
123115

124116
* Refactor and re-write of codebase to align with latest developments in version 2 of the Simvue server.
125117
* Added `Executor` to Simvue runs allowing users to start shell based processes as part of a run and handle termination of these.
@@ -129,119 +121,119 @@
129121
* Fixed issue whereby metrics would still have to wait for the next iteration of dispatch before being sent to the server, even if the queue was not full.
130122
* Added support for `'user'` alerts.
131123

132-
## [v0.14.3](https://github.com/simvue-io/client/releases/tag/v0.14.3) - 2023-06-29
124+
## [v0.14.3](https://github.com/simvue-io/python-api/releases/tag/v0.14.3) - 2023-06-29
133125

134126
* Ensure import of the `requests` module is only done if actually used.
135127

136-
## [v0.14.0](https://github.com/simvue-io/client/releases/tag/v0.14.0) - 2023-04-04
128+
## [v0.14.0](https://github.com/simvue-io/python-api/releases/tag/v0.14.0) - 2023-04-04
137129

138130
* Added a method to the `Client` class for retrieving events.
139131

140-
## [v0.13.3](https://github.com/simvue-io/client/releases/tag/v0.13.3) - 2023-04-04
132+
## [v0.13.3](https://github.com/simvue-io/python-api/releases/tag/v0.13.3) - 2023-04-04
141133

142134
* Allow files (`input` and `code` only) to be saved for runs in the `created` state.
143135
* Allow metadata and tags to be updated for runs in the `created` state.
144136

145-
## [v0.13.2](https://github.com/simvue-io/client/releases/tag/v0.13.2) - 2023-04-04
137+
## [v0.13.2](https://github.com/simvue-io/python-api/releases/tag/v0.13.2) - 2023-04-04
146138

147139
* Added `plot_metrics` method to the `Client` class to simplify plotting metrics.
148140
* (Bug fix) `reconnect` works without a uuid being specified when `offline` mode isn't being used.
149141
* (Bug fix) Restrict version of Pydantic to prevent v2 from accidentally being used.
150142

151-
## [v0.13.1](https://github.com/simvue-io/client/releases/tag/v0.13.1) - 2023-03-28
143+
## [v0.13.1](https://github.com/simvue-io/python-api/releases/tag/v0.13.1) - 2023-03-28
152144

153145
* Set `sample_by` to 0 by default (no sampling) in `get_metrics_multiple`.
154146

155-
## [v0.13.0](https://github.com/simvue-io/client/releases/tag/v0.13.0) - 2023-03-28
147+
## [v0.13.0](https://github.com/simvue-io/python-api/releases/tag/v0.13.0) - 2023-03-28
156148

157149
* Added methods to the `Client` class for retrieving metrics.
158150
* CPU architecture and processor obtained on Apple hardware.
159151
* Client now reports to server when files have been successfully uploaded.
160152
* `User-Agent` header now included in HTTP requests.
161153

162-
## [v0.12.0](https://github.com/simvue-io/client/releases/tag/v0.12.0) - 2023-03-13
154+
## [v0.12.0](https://github.com/simvue-io/python-api/releases/tag/v0.12.0) - 2023-03-13
163155

164156
* Add methods to the `Client` class for deleting runs and folders.
165157
* Confusing messages about `process no longer exists` or `NVML Shared Library Not Found` no longer displayed.
166158

167-
## [v0.11.4](https://github.com/simvue-io/client/releases/tag/v0.11.4) - 2023-03-13
159+
## [v0.11.4](https://github.com/simvue-io/python-api/releases/tag/v0.11.4) - 2023-03-13
168160

169161
* (Bug fix) Ensure `simvue_sender` can be run when installed from PyPI.
170162
* (Bug fix) Runs created in `offline` mode using a context manager weren't automatically closed.
171163

172-
## [v0.11.3](https://github.com/simvue-io/client/releases/tag/v0.11.3) - 2023-03-07
164+
## [v0.11.3](https://github.com/simvue-io/python-api/releases/tag/v0.11.3) - 2023-03-07
173165

174166
* Added logging messages for debugging when debug level set to `debug`.
175167

176-
## [v0.11.2](https://github.com/simvue-io/client/releases/tag/v0.11.2) - 2023-03-06
168+
## [v0.11.2](https://github.com/simvue-io/python-api/releases/tag/v0.11.2) - 2023-03-06
177169

178170
* Raise exceptions in `Client` class methods if run does not exist or artifact does not exist.
179171
* (Bug fix) `list_artifacts` optional category restriction now works.
180172

181-
## [v0.11.1](https://github.com/simvue-io/client/releases/tag/v0.11.1) - 2023-03-05
173+
## [v0.11.1](https://github.com/simvue-io/python-api/releases/tag/v0.11.1) - 2023-03-05
182174

183175
* Support different runs having different metadata in `get_runs` dataframe output.
184176
* (Bug fix) Error message when creating a duplicate run is now more clear.
185177
* (Bug fix) Correction to stopping the worker thread in situations where the run never started.
186178

187-
## [v0.11.0](https://github.com/simvue-io/client/releases/tag/v0.11.0) - 2023-03-04
179+
## [v0.11.0](https://github.com/simvue-io/python-api/releases/tag/v0.11.0) - 2023-03-04
188180

189181
* Support optional dataframe output from `get_runs`.
190182

191-
## [v0.10.1](https://github.com/simvue-io/client/releases/tag/v0.10.1) - 2023-03-03
183+
## [v0.10.1](https://github.com/simvue-io/python-api/releases/tag/v0.10.1) - 2023-03-03
192184

193185
* The worker process now no longer gives a long delay when a run has finished (now at most ~1 second).
194186
* The worker process ends when the `Run()` context ends or `close` is called, rather than only when the main process exits.
195187

196-
## [v0.10.0](https://github.com/simvue-io/client/releases/tag/v0.10.0) - 2023-02-07
188+
## [v0.10.0](https://github.com/simvue-io/python-api/releases/tag/v0.10.0) - 2023-02-07
197189

198190
* The `client` class can now be used to retrieve runs.
199191

200-
## [v0.9.1](https://github.com/simvue-io/client/releases/tag/v0.9.1) - 2023-01-25
192+
## [v0.9.1](https://github.com/simvue-io/python-api/releases/tag/v0.9.1) - 2023-01-25
201193

202194
* (Bug fix) Retries in POST/PUTs to REST APIs didn't happen.
203195
* Warn users if `allow_pickle=True` is required.
204196

205-
## [v0.9.0](https://github.com/simvue-io/client/releases/tag/v0.9.0) - 2023-01-25
197+
## [v0.9.0](https://github.com/simvue-io/python-api/releases/tag/v0.9.0) - 2023-01-25
206198

207199
* Set status to `failed` or `terminated` if the context manager is used and there is an exception.
208200

209-
## [v0.8.0](https://github.com/simvue-io/client/releases/tag/v0.8.0) - 2023-01-23
201+
## [v0.8.0](https://github.com/simvue-io/python-api/releases/tag/v0.8.0) - 2023-01-23
210202

211203
* Support NumPy arrays, PyTorch tensors, Matplotlib and Plotly plots and picklable Python objects as artifacts.
212204
* (Bug fix) Events in offline mode didn't work.
213205

214-
## [v0.7.2](https://github.com/simvue-io/client/releases/tag/v0.7.2) - 2023-01-08
206+
## [v0.7.2](https://github.com/simvue-io/python-api/releases/tag/v0.7.2) - 2023-01-08
215207

216208
* Pydantic model is used for input validation.
217209
* Support NaN, -inf and inf in metadata and metrics.
218210

219-
## [v0.7.0](https://github.com/simvue-io/client/releases/tag/v0.7.0) - 2022-12-05
211+
## [v0.7.0](https://github.com/simvue-io/python-api/releases/tag/v0.7.0) - 2022-12-05
220212

221213
* Collect CPU, GPU and memory resource metrics.
222214
* Automatically delete temporary files used in offline mode once runs have entered a terminal state.
223215
* Warn users if their access token has expired.
224216
* Remove dependency on the randomname module, instead handle name generation server side.
225217

226-
## [v0.6.0](https://github.com/simvue-io/client/releases/tag/v0.6.0) - 2022-11-07
218+
## [v0.6.0](https://github.com/simvue-io/python-api/releases/tag/v0.6.0) - 2022-11-07
227219

228220
* `offline` and `disabled` options replaced with single `mode` flag.
229221

230-
## [v0.5.0](https://github.com/simvue-io/client/releases/tag/v0.5.0) - 2022-11-03
222+
## [v0.5.0](https://github.com/simvue-io/python-api/releases/tag/v0.5.0) - 2022-11-03
231223

232224
* Added option to disable all monitoring.
233225

234-
## [v0.4.0](https://github.com/simvue-io/client/releases/tag/v0.4.0) - 2022-11-03
226+
## [v0.4.0](https://github.com/simvue-io/python-api/releases/tag/v0.4.0) - 2022-11-03
235227

236228
* Offline mode added, enabling tracking of simulations running on worker nodes without outgoing network access.
237229
* Argument to `init` enabling runs to be left in the `created` state changed from `status="created"` to `running=True`.
238230
* Improvements to error handling.
239231

240-
## [v0.3.0](https://github.com/simvue-io/client/releases/tag/v0.3.0) - 2022-10-31
232+
## [v0.3.0](https://github.com/simvue-io/python-api/releases/tag/v0.3.0) - 2022-10-31
241233

242234
* Update `add_alert` method to support either metrics or events based alerts.
243235

244-
## [v0.2.0](https://github.com/simvue-io/client/releases/tag/v0.2.0) - 2022-10-26
236+
## [v0.2.0](https://github.com/simvue-io/python-api/releases/tag/v0.2.0) - 2022-10-26
245237

246238
* The previous `Simvue` class has been split into `Run` and `Client`. When creating a run use the new `Run` class rather than `Simvue`.
247239

CITATION.cff

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@ keywords:
4242
- alerting
4343
- simulation
4444
license: Apache-2.0
45-
commit: effbd2e88fa12a181bf33721eae599d4245e1484
46-
version: 2.0.0rc1
47-
date-released: '2025-03-06'
45+
commit: 88bdd861e01153a2853191c0a8d1bb64dfabe296
46+
version: 2.0.0
47+
date-released: '2025-03-07'
4848
references:
4949
- title: mlco2/codecarbon
5050
version: v2.8.2

notebooks/non_python_example.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"metadata": {},
3535
"source": [
3636
"### Install dependencies\n",
37-
"While you can use Simvue and Multiparser individually to achieve the tracking and monitoring of Non-Python files, we recommend using the `simvue-integrations` package which wraps these both together into a handy `WrappedRun` class. Install this if you have not done so already:"
37+
"While you can use Simvue and Multiparser individually to achieve the tracking and monitoring of Non-Python files, we recommend using the `simvue-connector` package which wraps these both together into a handy `WrappedRun` class. Install this if you have not done so already:"
3838
]
3939
},
4040
{
@@ -43,7 +43,7 @@
4343
"metadata": {},
4444
"outputs": [],
4545
"source": [
46-
"!pip install git+https://github.com/simvue-io/integrations.git"
46+
"!pip install simvue-connector"
4747
]
4848
},
4949
{
@@ -94,7 +94,7 @@
9494
"metadata": {},
9595
"outputs": [],
9696
"source": [
97-
"from simvue_integrations.connectors.generic import WrappedRun\n",
97+
"from simvue_connector.connector import WrappedRun\n",
9898
"import multiparser.parsing.tail as mp_tail_parser\n",
9999
"import time\n",
100100
"import pathlib\n",

0 commit comments

Comments
 (0)