-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolve conflicts
- Loading branch information
Showing
17 changed files
with
235 additions
and
143 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,31 @@ | ||
.vscode | ||
# Some categories and items copied from https://github.com/github/gitignore/blob/main/Python.gitignore | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__ | ||
**.ipynb | ||
|
||
.idea | ||
venv | ||
.env | ||
# Distribution / packaging | ||
.Python | ||
build/ | ||
dist/ | ||
sdist/ | ||
*.egg-info/ | ||
site/ | ||
|
||
# Unit test / coverage reports | ||
.coverage | ||
coverage.xml | ||
AntaresWebDesktop | ||
.tox/ | ||
|
||
# Environments | ||
.env | ||
.venv | ||
env/ | ||
venv/ | ||
|
||
# Jupyter notebooks | ||
**.ipynb | ||
|
||
# Other | ||
.vscode | ||
.idea | ||
AntaresWebDesktop/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,46 @@ | ||
Antares Craft python library is currently under construction. When completed it will allow to create, update and read antares studies. | ||
# antares_craft | ||
[![github ci](https://github.com/AntaresSimulatorTeam/antares_craft/actions/workflows/ci.yml/badge.svg)](https://github.com/AntaresSimulatorTeam/antares_craft/actions/workflows/ci.yml) | ||
|
||
## about | ||
|
||
Antares Craft python library is currently under construction. When completed it will allow to create, update and read | ||
antares studies. | ||
|
||
This project only supports antares studies with a version v8.8 or higher. | ||
|
||
To reformat your code, use this command line : `ruff check src/ tests/ --fix && ruff format src/ tests/` | ||
## developers | ||
### install dev requirements | ||
|
||
Install dev requirements with `pip install -r requirements-dev.txt` | ||
|
||
### linting and formatting | ||
|
||
To reformat your code, use this command line: `ruff check src/ tests/ --fix && ruff format src/ tests/` | ||
|
||
To launch integration tests you'll need an AntaresWebDesktop instance on your local env (at least the v.2.17.3, **currently running in 2.17.5**). | ||
To install it, download it from the last [Antares Web release](https://github.com/AntaresSimulatorTeam/AntaREST/releases) (inside the assets list). | ||
### typechecking | ||
|
||
To typecheck your code, use this command line: `mypy` | ||
|
||
### integration testing | ||
|
||
To launch integration tests you'll need an AntaresWebDesktop instance on your local env (at least the v.2.17.3, | ||
**currently running in 2.17.5**). | ||
To install it, download it from the last [Antares Web release](https://github.com/AntaresSimulatorTeam/AntaREST/releases) | ||
(inside the assets list). | ||
Then, unzip it at the root of this repository and rename the folder `AntaresWebDesktop`. | ||
*NB*: The expected folder structure is the following: `antares_craft/AntaresWebDesktop/config.yaml` | ||
|
||
### tox | ||
To use [tox](https://tox.wiki/) to run unit tests in multiple python versions at the same time as linting and formatting | ||
with ruff and typing with mypy: | ||
1) As the dev requirements include [uv](https://docs.astral.sh/uv/) and `tox-uv` there is no need to install python | ||
versions, `uv` will do this for you. | ||
2) Use `tox -p` to run the environments in parallel to save time, this will create virtual environment with the | ||
necessary python versions the first time you run tox. | ||
|
||
### mkdocs | ||
Smallest beginning of `mkdocs` included more as proof of concept than anything, theme and logo copied from [Antares | ||
Simulator](https://github.com/AntaresSimulatorTeam/Antares_Simulator). | ||
1) To preview the docs on your local machine run `mkdocs serve`. | ||
2) To build the static site for publishing for example on [Read the Docs](https://readthedocs.io) use `mkdocs build`. | ||
3) To flesh out the documentation see [mkdoc guides](https://www.mkdocs.org/user-guide/). |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# antares_craft | ||
[![github ci](https://github.com/AntaresSimulatorTeam/antares_craft/actions/workflows/ci.yml/badge.svg)](https://github.com/AntaresSimulatorTeam/antares_craft/actions/workflows/ci.yml) | ||
|
||
## about | ||
|
||
Antares Craft python library is currently under construction. When completed it will allow to create, update and read | ||
antares studies. | ||
|
||
This project only supports antares studies with a version v8.8 or higher. | ||
|
||
## developers | ||
### install dev requirements | ||
|
||
Install dev requirements with `pip install -r requirements-dev.txt` | ||
|
||
### linting and formatting | ||
|
||
To reformat your code, use this command line: `ruff check src/ tests/ --fix && ruff format src/ tests/` | ||
|
||
### typechecking | ||
|
||
To typecheck your code, use this command line: `mypy` | ||
|
||
### integration testing | ||
|
||
To launch integration tests you'll need an AntaresWebDesktop instance on your local env (at least the v.2.17.3, | ||
**currently running in 2.17.5**). | ||
To install it, download it from the last [Antares Web release](https://github.com/AntaresSimulatorTeam/AntaREST/releases) | ||
(inside the assets list). | ||
Then, unzip it at the root of this repository and rename the folder `AntaresWebDesktop`. | ||
*NB*: The expected folder structure is the following: `antares_craft/AntaresWebDesktop/config.yaml` | ||
|
||
### tox | ||
To use [tox](https://tox.wiki/) to run unit tests in multiple python versions at the same time as linting and formatting | ||
with ruff and typing with mypy: | ||
1) As the dev requirements include [uv](https://docs.astral.sh/uv/) and `tox-uv` there is no need to install python | ||
versions, `uv` will do this for you. | ||
2) Use `tox -p` to run the environments in parallel to save time, this will create virtual environment with the | ||
necessary python versions the first time you run tox. | ||
|
||
### mkdocs | ||
Smallest beginning of `mkdocs` included more as proof of concept than anything, theme and logo copied from [Antares | ||
Simulator](https://github.com/AntaresSimulatorTeam/Antares_Simulator). | ||
1) To preview the docs on your local machine run `mkdocs serve`. | ||
2) To build the static site for publishing for example on [Read the Docs](https://readthedocs.io) use `mkdocs build`. | ||
3) To flesh out the documentation see [mkdoc guides](https://www.mkdocs.org/user-guide/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Reference | ||
|
||
To start using Antares Craft create a study using either the API or local modes, you can then build on the created object to add study elements as you go: | ||
|
||
Exemple: | ||
|
||
study = create_study_local("test_study", 880, {"local_path": "test_study", "study_name": "test_study"}) | ||
|
||
|
||
::: src.antares.model.study |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
site_name: Antares Craft | ||
repo_url: https://github.com/AntaresSimulatorTeam/antares_craft | ||
nav: | ||
- Home: index.md | ||
- Quickstart: quickstart.md | ||
theme: | ||
name: material | ||
logo: assets/logo.png | ||
favicon: assets/Icone.png | ||
prev_next_buttons_location: none | ||
# custom_dir: docs/overrides | ||
features: | ||
- navigation.instant | ||
- navigation.top | ||
- content.tabs.link | ||
# - navigation.expand | ||
# - navigation.sections | ||
# - header.autohide | ||
# - toc.separate | ||
palette: | ||
- media: "(prefers-color-scheme: light)" | ||
scheme: antares | ||
toggle: | ||
icon: material/toggle-switch-off-outline | ||
name: Switch to dark mode | ||
- media: "(prefers-color-scheme: dark)" | ||
scheme: slate | ||
toggle: | ||
icon: material/toggle-switch | ||
name: Switch to light mode | ||
|
||
plugins: | ||
- search | ||
- mkdocstrings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
absl-py~=1.4.0 | ||
click~=8.1.7 | ||
configparser~=5.0.2 | ||
numpy~=1.26.4 | ||
requests~=2.31.0 | ||
pandas~=2.2.2 | ||
pandas-stubs~=2.2.2 | ||
pydantic~=2.7.1 | ||
pytest~=7.2.1 | ||
python-dateutil~=2.9.0 | ||
pydantic~=2.7.1 | ||
configparser~=5.0.2 | ||
click~=8.1.7 | ||
requests~=2.31.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.