Skip to content

Commit 378c11e

Browse files
committed
Initial commit
0 parents  commit 378c11e

32 files changed

+4235
-0
lines changed
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: Run Ruff and Mypy Checks and Tests
2+
3+
on:
4+
push:
5+
branches:
6+
- '**' # Triggers on all branches but not tag push
7+
pull_request: # Triggers on all PRs
8+
9+
jobs:
10+
lint:
11+
name: Run Ruff and Mypy
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout code
16+
uses: actions/checkout@v3
17+
18+
- name: Set up Python
19+
uses: actions/setup-python@v4
20+
with:
21+
python-version: '3.11'
22+
23+
- name: Install dependencies
24+
run: |
25+
python -m pip install --upgrade pip
26+
pip install uv
27+
uv sync --group lint
28+
29+
- name: Run Ruff
30+
run: |
31+
uv run --frozen python -m ruff check
32+
33+
- name: Run Mypy
34+
run: |
35+
uv run --frozen python -m mypy
36+
37+
test:
38+
runs-on: ubuntu-latest
39+
needs: ['lint']
40+
41+
steps:
42+
- uses: actions/checkout@v4
43+
44+
- name: Set up Python
45+
uses: actions/setup-python@v5
46+
with:
47+
python-version: '3.11'
48+
49+
- name: Install dependencies
50+
run: |
51+
python -m pip install --upgrade pip
52+
pip install uv
53+
uv sync
54+
uv sync --group test
55+
56+
- name: Run Tests
57+
run: |
58+
uv run --frozen python -m pytest
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Publish to PyPI
2+
3+
on:
4+
release:
5+
types: [ published ]
6+
7+
jobs:
8+
build-and-publish:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v4
14+
15+
- name: Set up Python
16+
uses: actions/setup-python@v5
17+
with:
18+
python-version: '3.11'
19+
20+
- name: Install dependencies
21+
run: |
22+
python -m pip install --upgrade pip
23+
pip install build twine
24+
25+
- name: Build package
26+
run: python -m build
27+
28+
- name: Publish to PyPI
29+
env:
30+
TWINE_USERNAME: __token__
31+
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
32+
run: |
33+
twine check dist/*
34+
twine upload dist/*

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
.idea/
2+
venv/
3+
/dist/

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 eXXcellent solutions
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README-pypi.md

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
![easyssp-logo-light](https://raw.githubusercontent.com/exxcellent/easyssp-auth-client-python/refs/heads/master/images/logo-light.png#gh-light-mode-only)
2+
3+
# easySSP Simulation Python Client
4+
5+
This is the official Python client for the **Simulation API** of the easySSP. It provides an easy-to-use interface for
6+
interacting with simulation endpoints — including launching, monitoring, and managing simulations programmatically.
7+
8+
---
9+
10+
## 🚀 Features
11+
12+
- 📋 Retrieve available simulation options and current simulation credits
13+
- 🎯 Launch and control simulations
14+
- 🔍 Monitor simulation progress and access results
15+
- 🗂️ Manage and organize executed simulations
16+
17+
---
18+
19+
## 📦 Installation
20+
21+
```bash
22+
pip install easyssp-simulation-client
23+
```
24+
25+
Or clone and install from source:
26+
27+
```bash
28+
git clone https://github.com/exxcellent/easyssp-simulation-client-python.git
29+
cd easyssp-simulation-client-python
30+
pip install -e .
31+
```
32+
33+
## Tests
34+
35+
Execute `pytest` or `python -m pytest` to run the tests.
36+
37+
## 📁 Project Structure
38+
39+
```bash
40+
easyssp_simulation/
41+
├── __init__.py
42+
├── client/
43+
│ ├── __init__.py
44+
│ └── simulation_client.py # Simulating SSP models with integrated FMI components in easySSP
45+
46+
├── models/
47+
│ ├── __init__.py
48+
│ ├── hardware_option.py # The available hardware configuration options for simulations
49+
│ ├── run.py # The different runs the Simulation consists of
50+
│ ├── simulation.py # The created/started simulation
51+
│ ├── simulation_info.py # Info about the simulation
52+
│ ├── simulation_started.py # Info about the started simulation
53+
│ ├── start_simulation_configuration.py # The configuration for the simulation runs
54+
│ ├── start_simulation_run_configuration.py # Specifies configurations for simulation runs to execute on the given .ssp-file
55+
│ └── step.py # Each simulation run is split into two steps. The 'generate' step will generate a simulator. The 'simulate' step will use that simulator to perform the simulation with the given configurations
56+
```
57+
58+
## 📖 API Reference
59+
60+
This client is built against the official **Simulation API** specification, available as an OpenAPI (Swagger) document.
61+
62+
You can explore the full API documentation here:
63+
👉 [**Simulation API**](https://apps.exxcellent.de/easy-ssp/docs/integration-api/v1/simulation/index.html)
64+
65+
## 📚 Examples Repository & Extended Documentation
66+
67+
Looking for working demos? Check out the Simulation Client Examples Repository here:
68+
👉 [**Simulation Client Examples Repository**](https://github.com/exxcellent/easyssp-simulation-examples-python)
69+
70+
It includes:
71+
72+
- Real-world examples for running and managing simulations
73+
- Usage patterns for authentication and error handling
74+
75+
It's the best place to explore how the client works in action and how to integrate it into your own workflows.
76+
77+
## 🛠️ Requirements
78+
79+
- Python 3.11+
80+
- easyssp Pro Edition Account
81+
82+
Install dependencies using uv:
83+
84+
```bash
85+
pip install uv
86+
uv sync
87+
```
88+
89+
## 🤝 Contributing
90+
91+
This module is maintained as part of the easySSP ecosystem. If you find issues or want to suggest improvements, please
92+
open an issue or submit a pull request.
93+
94+
## 📄 License
95+
96+
This project is licensed under the MIT License.

README.md

Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
![easyssp-logo-light](https://raw.githubusercontent.com/exxcellent/easyssp-auth-client-python/refs/heads/master/images/logo-light.png#gh-light-mode-only)
2+
![easyssp-logo-dark](https://raw.githubusercontent.com/exxcellent/easyssp-auth-client-python/refs/heads/master/images/logo-dark.png#gh-dark-mode-only)
3+
4+
# easySSP Simulation Python Client
5+
6+
This is the official Python client for the **Simulation API** of the easySSP. It provides an easy-to-use interface for
7+
interacting with simulation endpoints — including launching, monitoring, and managing simulations programmatically.
8+
9+
---
10+
11+
## 🚀 Features
12+
13+
- 📋 Retrieve available simulation options and current simulation credits
14+
- 🎯 Launch and control simulations
15+
- 🔍 Monitor simulation progress and access results
16+
- 🗂️ Manage and organize executed simulations
17+
18+
---
19+
20+
## 📦 Installation
21+
22+
```bash
23+
pip install easyssp-simulation-client
24+
```
25+
26+
Or clone and install from source:
27+
28+
```bash
29+
git clone https://github.com/exxcellent/easyssp-simulation-client-python.git
30+
cd easyssp-simulation-client-python
31+
pip install -e .
32+
```
33+
34+
## Tests
35+
36+
Execute `pytest` or `python -m pytest` to run the tests.
37+
38+
## 📁 Project Structure
39+
40+
```bash
41+
easyssp_simulation/
42+
├── __init__.py
43+
├── client/
44+
│ ├── __init__.py
45+
│ └── simulation_client.py # Simulating SSP models with integrated FMI components in easySSP
46+
47+
├── models/
48+
│ ├── __init__.py
49+
│ ├── hardware_option.py # The available hardware configuration options for simulations
50+
│ ├── run.py # The different runs the Simulation consists of
51+
│ ├── simulation.py # The created/started simulation
52+
│ ├── simulation_info.py # Info about the simulation
53+
│ ├── simulation_started.py # Info about the started simulation
54+
│ ├── start_simulation_configuration.py # The configuration for the simulation runs
55+
│ ├── start_simulation_run_configuration.py # Specifies configurations for simulation runs to execute on the given .ssp-file
56+
│ └── step.py # Each simulation run is split into two steps. The 'generate' step will generate a simulator. The 'simulate' step will use that simulator to perform the simulation with the given configurations
57+
```
58+
59+
## 📖 API Reference
60+
61+
This client is built against the official **Simulation API** specification, available as an OpenAPI (Swagger) document.
62+
63+
You can explore the full API documentation here:
64+
👉 [**Simulation API**](https://apps.exxcellent.de/easy-ssp/docs/integration-api/v1/simulation/index.html)
65+
or in the `docs` directory in this project.
66+
67+
## 📚 Examples Repository & Extended Documentation
68+
69+
Looking for working demos? Check out the Simulation Client Examples Repository here:
70+
👉 [**Simulation Client Examples Repository**](https://github.com/exxcellent/easyssp-simulation-examples-python)
71+
72+
It includes:
73+
74+
- Real-world examples for running and managing simulations
75+
- Usage patterns for authentication and error handling
76+
77+
It's the best place to explore how the client works in action and how to integrate it into your own workflows.
78+
79+
## 🛠️ Requirements
80+
81+
- Python 3.11+
82+
- easyssp Pro Edition Account
83+
84+
Install dependencies using uv:
85+
86+
```bash
87+
pip install uv
88+
uv sync
89+
```
90+
91+
## 🤝 Contributing
92+
93+
This module is maintained as part of the easySSP ecosystem. If you find issues or want to suggest improvements, please
94+
open an issue or submit a pull request.
95+
96+
## 📄 License
97+
98+
This project is licensed under the MIT License.

0 commit comments

Comments
 (0)