Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
3fc13c2
initial commit for simul8 simulator
Rasmus-M-C Jun 21, 2025
9eab75a
corrected file name
Rasmus-M-C Jun 21, 2025
464aa26
gitignore updated with main branch
marcomelloni Jun 26, 2025
25aa3a4
Top-level fix issue
marcomelloni Jun 26, 2025
66b2c26
non working data input to simul8
Rasmus-M-C Jul 4, 2025
c73a2d0
added client folder
Rasmus-M-C Jul 9, 2025
723b14d
added structure diagram and demo videos
Rasmus-M-C Jul 9, 2025
066e75a
removed tracking of client folder
Rasmus-M-C Jul 9, 2025
0f5b250
functionality to run batch simulation using simul8
Rasmus-M-C Jul 9, 2025
55c2a9a
removed tcp connections and other non-necessary config option for simul8
Rasmus-M-C Jul 9, 2025
38fdfe0
example simulation adding co2 and energy
Rasmus-M-C Jul 9, 2025
e474066
corrected path
Rasmus-M-C Jul 9, 2025
d23a95a
correct naming to simul8
Rasmus-M-C Jul 9, 2025
6d550f4
corrected generation for simul8 agent
Rasmus-M-C Jul 9, 2025
4800da6
corrected payload file for simul8 agent
Rasmus-M-C Jul 9, 2025
51a8d6e
rewrote readme for simul8 instance
Rasmus-M-C Jul 9, 2025
0768b72
renaming
Rasmus-M-C Jul 9, 2025
280955d
removed tests for now
Rasmus-M-C Jul 9, 2025
b532f0c
Removed printing statements
Rasmus-M-C Jul 9, 2025
317338b
updated TODOS
Rasmus-M-C Sep 1, 2025
997f0c2
removed temp files
Rasmus-M-C Sep 9, 2025
382acbe
Updated diagram to better explain the structure
Rasmus-M-C Sep 2, 2025
467ac32
fixed exmample with mock values
Rasmus-M-C Sep 2, 2025
8e9ece0
Updated readme
Rasmus-M-C Sep 2, 2025
a37303f
updated readme
Rasmus-M-C Sep 2, 2025
75577a6
created example in parser
Rasmus-M-C Sep 2, 2025
0d5bb81
removed unused function
Rasmus-M-C Sep 25, 2025
9a4d24e
creatded more tests.
Rasmus-M-C Oct 9, 2025
8156604
fixed exact assert to approx for better reliability
Rasmus-M-C Oct 15, 2025
306537d
more secure tls
Rasmus-M-C Oct 15, 2025
b367e9e
Check file exists before trying to run it, if not return error
Rasmus-M-C Oct 16, 2025
0226e8b
added tests for csv parser
Rasmus-M-C Oct 16, 2025
9517ce3
Fixed typo
Rasmus-M-C Oct 16, 2025
06a1864
removed metadata test, not accesible for simul8
Rasmus-M-C Oct 16, 2025
8991841
added correct naming
Rasmus-M-C Oct 21, 2025
6067b82
added correct naming for generated files
Rasmus-M-C Oct 21, 2025
b87d913
formatted with pep8
Rasmus-M-C Oct 21, 2025
d966b78
fixed path exits
Rasmus-M-C Oct 21, 2025
53fe060
restructured simulator as discussed in first meeting with prasad
Rasmus-M-C Oct 22, 2025
60b8655
added performance analysis, same as in matlab agent
Rasmus-M-C Oct 22, 2025
aa092fd
updated readme
Rasmus-M-C Oct 22, 2025
cf826ba
fixed csv parser
Rasmus-M-C Oct 22, 2025
c98fa99
removed debug statements
Rasmus-M-C Oct 22, 2025
a13c27f
updated to match matlab connect.py file
Rasmus-M-C Oct 22, 2025
fd48bb9
renamed functions to simul8
Rasmus-M-C Oct 22, 2025
0a54d44
updated naming
Rasmus-M-C Oct 22, 2025
175ec8b
added bk8 file
Rasmus-M-C Oct 22, 2025
0119f95
formatted code and renamed performance to match changes in classfile
Rasmus-M-C Oct 22, 2025
28b86c0
flow to ensure code follows repo standards
Rasmus-M-C Oct 26, 2025
f3505b2
updated gif
Rasmus-M-C Oct 27, 2025
16f046e
tests to cover simul8 functions
Rasmus-M-C Oct 27, 2025
713b28f
corrected logging functions
Rasmus-M-C Oct 27, 2025
dad3103
reorder imports
Rasmus-M-C Oct 27, 2025
0822ddf
changed logger f string
Rasmus-M-C Oct 27, 2025
03f5b25
changed logger fstring
Rasmus-M-C Oct 27, 2025
798784d
updated readme to be more descriptive
Rasmus-M-C Oct 27, 2025
50d1d5b
added error description for gen_py issue
Rasmus-M-C Oct 27, 2025
2d7e038
more descriptive of simulation requirements
Rasmus-M-C Oct 27, 2025
28b10a0
test coverage updated and improved
Rasmus-M-C Oct 27, 2025
c75bbc6
removed unecessary tests for shutting down s8
Rasmus-M-C Oct 27, 2025
e7a3665
removed macos, no simul8 for macos
Rasmus-M-C Oct 27, 2025
9c21eb9
removed linux based test, simul8 only exists on windows
Rasmus-M-C Oct 27, 2025
18356c5
added linter for markdown
Rasmus-M-C Oct 28, 2025
c1f6b79
linted readme's
Rasmus-M-C Oct 30, 2025
c8f4e8c
linting
Rasmus-M-C Oct 30, 2025
32c8a65
fixed folders for generating files
Rasmus-M-C Oct 30, 2025
258bed0
renamed use_simul8 to match type
Rasmus-M-C Oct 30, 2025
0ea6fe1
fixed generating folders
Rasmus-M-C Oct 30, 2025
35fbe34
formatting fixes
Rasmus-M-C Oct 30, 2025
36bf421
updated test to only unit tests
Rasmus-M-C Oct 30, 2025
b5bfcd5
corrected model file
Rasmus-M-C Oct 30, 2025
b51386a
added tls option and fixed typo
Rasmus-M-C Oct 30, 2025
45dd222
linting of readme's
Rasmus-M-C Oct 30, 2025
47e6a5a
updated model
Rasmus-M-C Oct 30, 2025
31fcd87
ignore .s8 fiels in simul8 directory ( created when running --generat…
Rasmus-M-C Oct 30, 2025
ba8bb14
deleted .s8 file in wrong directory
Rasmus-M-C Oct 30, 2025
b85f3ec
fixed killing the simul8-agent, now only kills simul8 program
Rasmus-M-C Oct 30, 2025
b4c2699
Fixes simul8 client script
prasadtalasila Oct 30, 2025
aa10060
fixed simul8 tests
Rasmus-M-C Oct 30, 2025
4cf9b2a
fixed actions yml
Rasmus-M-C Oct 30, 2025
eab5277
Merge branch 'feature/simul8_agent' of https://github.com/INTO-CPS-As…
Rasmus-M-C Oct 30, 2025
32511ff
fixed syntax error for print statement
Rasmus-M-C Oct 30, 2025
20d0d31
fixed new syntas error
Rasmus-M-C Oct 30, 2025
81d9fb2
Fixes markdown lint issues
prasadtalasila Oct 30, 2025
d43fcdc
Fixes simul8 README
prasadtalasila Oct 31, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
83 changes: 83 additions & 0 deletions .github/workflows/simul8-agent-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: SIMUL8 Agent CI

on:
pull_request:
paths:
- "agents/simul8/**"
- ".github/workflows/simul8-agent-ci.yml"

jobs:
ci:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest]

# All commands run inside the agent directory
defaults:
run:
working-directory: agents/simul8

steps:
# ───── 1. Checkout ─────
- uses: actions/checkout@v4

# ───── 2. Python + Poetry ─────
- uses: actions/setup-python@v5
with:
python-version: "3.12"

- name: Install Poetry
env:
POETRY_HOME: ${{ runner.temp }}/poetry
run: |
python -m pip install --upgrade pip
curl -sSL https://install.python-poetry.org | python -

- name: Add Poetry to PATH (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: echo "${{ runner.temp }}\poetry\bin" |
Out-File -FilePath $env:GITHUB_PATH -Encoding utf8

# ───── 3. Install dev deps once ─────
- name: Install dev dependencies
run: poetry install --with dev

# ───── 4. Format check ─────
- name: Check formatting (non-blocking)
continue-on-error: true
run: poetry run autopep8 --recursive --diff simul8_agent

# ───── 5. Lint ─────
- name: Run pylint (min score 9.0)
run: poetry run pylint simul8_agent --fail-under=9

# ───── 6. Tests ─────
- name: Run pytest (with coverage)
run: poetry run pytest --cov=simul8_agent --cov-report=xml

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5
with:
files: coverage.xml
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}

# ───── 7. Build + dist artefacts ─────
- name: Install runtime dependencies
run: poetry install --only main

- name: Build wheel and sdist
run: |
poetry build --format wheel
poetry build --format sdist

- name: Upload dist artefacts
uses: actions/upload-artifact@v4
with:
name: simul8-agent-dist
path: |
agents/simul8/dist/*.whl
agents/simul8/dist/*.tar.gz
retention-days: 1 # minimum allowed (≈24 h)
12 changes: 11 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -195,16 +195,26 @@ agents/matlab/dist/
**/resources/*.yml
**/matlab/*.yaml
**/matlab/*.yml
**/simul8/*.yml
**/simul8/*.yaml
config*.yaml
simulation*.yaml
*.csv
interactive.py
*_interactive.py
**/examples/interactive-simulation/*
# SIMUL8 agent
agents/simul8/client
agents/simul8/logs
*.bk8
# Ignore any .s8 files in agents/simul8 (including subdirectories)
agents/simul8/*.s8
#SIMULATION BRIDGE
/logs
/certs
*.pem
*_use.yaml
client/
dist/
/certs
*.pem
*_use.yaml
Expand Down
9 changes: 5 additions & 4 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"python.testing.pytestArgs": ["."],
"python.testing.pytestEnabled": true,
"python.testing.pytestArgs": ["simulation_bridge/test"],
"python.testing.autoTestDiscoverOnSaveEnabled": true,
"python.testing.promptToConfigure": false
}
"python.testing.unittestEnabled": false,
"python.testing.cwd": "${workspaceFolder}/agents/simul8",
"python.testing.autoTestDiscoverOnSaveEnabled": true
}
13 changes: 13 additions & 0 deletions agents/simul8/.coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[run]
omit =
*/tests/*
*/venv/*
*/.venv/*
*/__init__.py
*/simul8_agent/docs/*
*/simul8_agent/resources/*

[report]
exclude_lines =
if __name__ == .__main__.:
pragma: no cover
9 changes: 9 additions & 0 deletions agents/simul8/.markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"default": true,
"MD003": { "style": "atx" },
"MD007": { "indent": 4 },
"no-hard-tabs": false,
"whitespace": true,
"line-length": true,
"MD033": { "allowed_elements": [ "div", "img" , "p", "i"] }
}
2 changes: 2 additions & 0 deletions agents/simul8/.pep8
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[pycodestyle]
max_line_length = 80
Loading