Skip to content

Commit a438db7

Browse files
authored
✨ Client for public api v0.7 (#189)
1 parent 8c38544 commit a438db7

29 files changed

+339
-607
lines changed

.gitignore

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,3 @@ tmp*
8989
*ignore*
9090
!.dockerignore
9191
!.gitignore
92-
93-
94-
# api diffs
95-
api/openapi-*-diff.json
96-
api/openapi-dev.json

.vscode/settings.template.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,8 @@
1212
},
1313
"pylint.args": [
1414
"--rcfile=clients/python/.pylintrc"
15+
],
16+
"python.analysis.extraPaths": [
17+
"./clients/python/artifacts/client"
1518
]
1619
}

Makefile

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ PYTHON_DIR := $(CLIENTS_DIR)/python
44

55

66
.vscode/%.json: .vscode/%.template.json
7-
$(if $(wildcard $@), \
7+
-$(if $(wildcard $@), \
88
@echo "WARNING ##### $< is newer than $@ ####"; diff -uN $@ $<; false;,\
99
@echo "WARNING ##### $@ does not exist, cloning $< as $@ ############"; cp $< $@)
1010

@@ -27,14 +27,16 @@ info-envs: ## info on envs
2727

2828
info-tools: ## info on tooling
2929
# Tooling ---------------
30-
@echo ' make : $(shell make --version 2>&1 | head -n 1)'
31-
@echo ' jq : $(shell jq --version)'
3230
@echo ' awk : $(shell awk -W version 2>&1 | head -n 1)'
33-
@echo ' python : $(shell python3 --version)'
34-
@echo ' uv : $(shell uv --version)'
31+
@echo ' curl : $(shell curl --version | head -n 1)'
3532
@echo ' docker : $(shell docker --version)'
3633
@echo ' docker buildx : $(shell docker buildx version)'
3734
@echo ' docker compose : $(shell docker compose version)'
35+
@echo ' jq : $(shell jq --version)'
36+
@echo ' make : $(shell make --version 2>&1 | head -n 1)'
37+
@echo ' python : $(shell python3 --version)'
38+
@echo ' uv : $(shell uv --version)'
39+
3840

3941

4042
info-pip: ## info index versions
@@ -50,7 +52,9 @@ info: info-api info-envs info-tools info-pip ## all infos
5052

5153

5254
.venv: .check-uv-installed
53-
@uv venv $@
55+
@uv venv \
56+
--python 3.10 \
57+
$@
5458
## upgrading tools to latest version in $(shell python3 --version)
5559
@uv pip --quiet install --upgrade \
5660
pip~=24.0 \

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ To get started using the tools developed in this repository have a look at the
44
[Documentation](https://itisfoundation.github.io/osparc-simcore-clients).
55

66
For more in depth knowledge concerning the development of the repository, take a look at
7+
78
- [Release Notes](https://github.com/ITISFoundation/osparc-simcore-clients/releases)
89
- [Development notes](#development-notes)
910

@@ -27,6 +28,7 @@ See the different `clients/<language>/README.md` for the workflows for generatin
2728
2. The [openapi-generator](https://github.com/ITISFoundation/openapi-generator)-tool. The exact docker image of this tool to use is specifies in `scripts/common.Makefile`.
2829

2930
## Code lifecycle
31+
3032
This link explains the lifecycle of the osparc client(s) (borrowed from https://www.ibm.com/docs/en/acvfc?topic=manager-product-lifecycle)
3133
<p align="center">
3234
<a href="https://www.ibm.com/docs/en/acvfc?topic=manager-product-lifecycle" target="_blank">

VERSIONING.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Versioning Strategy
2+
3+
- We follow **post-release versioning** during development.
4+
- Format: `1.2.3.post0.devN` where `N` represents the number of commits since the last release (`1.2.3`).
5+
- We opt for post-release versioning rather than pre-release to avoid making early decisions about the next release version.
6+
7+
- Official releases follow the format `1.2.3`.
8+
9+
- **Patch releases** (e.g., `1.2.4`) are used instead of post-releases like `1.2.3.postX`.
10+
11+
- Releases are determined by **git tags**. SEE [Releases](https://github.com/ITISFoundation/osparc-simcore-clients/releases).
12+
13+
- For more details, refer to the following:
14+
- GitHub workflow for publishing: `.github/workflows/publish-python-client.yml`
15+
- Version computation script: `scripts/compute_version.bash`

api/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
openapi-*-diff.json
2+
openapi-deploy.json
3+
openapi-master.json

api/Makefile

Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,31 @@
11
include ../scripts/common.Makefile
22

33

4-
.PHONY: openapi-diff-dev.json
5-
openapi-dev-diff.json: ## Diffs against newer openapi-dev.json and checks backwards compatibility
6-
$(SCRIPTS_DIR)/openapi-diff.bash \
7-
/specs/openapi.json \
8-
/specs/openapi-dev.json \
9-
--fail-on-incompatible \
10-
--json=/specs/$@
4+
define download_openapi
5+
@curl -L $(1) -o $(2) || (echo "Failed to download $(2)" && exit 1)
6+
endef
117

8+
.PHONY: openapi-master.json
9+
openapi-master.json:
10+
$(call download_openapi, https://raw.githubusercontent.com/ITISFoundation/osparc-simcore-clients/refs/heads/master/api/openapi.json,$@)
1211

12+
.PHONY: openapi-deploy.json
13+
openapi-deploy.json:
14+
$(call download_openapi, https://api.osparc.io/api/v0/openapi.json,$@)
1315

14-
.PHONY: openapi-diff-dev.json
16+
17+
define openapi_diff
18+
$(SCRIPTS_DIR)/openapi-diff.bash $(1) /specs/openapi.json \
19+
--fail-on-incompatible \
20+
--json="/specs/$(2)"
21+
endef
22+
23+
24+
.PHONY: openapi-master-diff.json
25+
openapi-master-diff.json: ## Diffs against newer openapi-dev.json and checks backwards compatibility
26+
$(call openapi_diff, https://raw.githubusercontent.com/ITISFoundation/osparc-simcore-clients/refs/heads/master/api/openapi.json,$@)
27+
28+
29+
.PHONY: openapi-deploy-diff.json
1530
openapi-deploy-diff.json: ## Diffs against newer openapi-dev.json and checks backwards compatibility
16-
$(SCRIPTS_DIR)/openapi-diff.bash \
17-
https://api.osparc.io/api/v0/openapi.json \
18-
/specs/openapi.json \
19-
--fail-on-incompatible \
20-
--json=/specs/$@
31+
$(call openapi_diff, https://api.osparc.io/api/v0/openapi.json,$@)

0 commit comments

Comments
 (0)