-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
198 changed files
with
38,658 additions
and
55,983 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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[flake8] | ||
extend-exclude = docs | ||
max-line-length = 88 | ||
extend-ignore = E203 | ||
count = true | ||
statistics = true | ||
show-source = true |
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,33 +1,69 @@ | ||
# Tests with pytest the package and monitors the covarage and sends it to coveralls.io | ||
# Coverage is only send to coveralls.io when no pytest tests fail | ||
name: "Tests & coverage" | ||
name: "Tests & Coverage" | ||
|
||
on: [push] | ||
|
||
|
||
# Cancel jobs on new push | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
name: "${{ matrix.name-suffix }} at py${{ matrix.python-version }} on ${{ matrix.os }}" | ||
runs-on: ${{ matrix.os }} | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: [ '3.7', '3.8', '3.9' ] | ||
include: | ||
- name-suffix: "coverage" | ||
os: ubuntu-latest | ||
python-version: 3.8 | ||
- name-suffix: "basic" | ||
os: ubuntu-latest | ||
python-version: 3.9 | ||
- name-suffix: "basic" | ||
os: windows-latest | ||
python-version: 3.8 | ||
|
||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v2 | ||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
pip3 install -e $GITHUB_WORKSPACE[full] | ||
pip3 install coveralls | ||
- name: Run coverage | ||
run: | | ||
coverage run --source=edisgo -m pytest --runslow -vv | ||
#continue-on-error: true | ||
- name: Run coveralls | ||
run: | | ||
coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
COVERALLS_SERVICE_NAME: github | ||
- name: Checkout repo | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install packages (Linux) | ||
if: runner.os == 'Linux' | ||
run: | | ||
pip install --upgrade pip wheel setuptools | ||
pip install -e "." | ||
- name: Install packages (Windows) | ||
if: runner.os == 'Windows' | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
miniconda-version: "latest" | ||
activate-environment: edisgo_env | ||
environment-file: eDisGo_env_dev.yml | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Run tests | ||
if: ${{ !(runner.os == 'Linux' && matrix.python-version == 3.8 && matrix.name-suffix == 'coverage') }} | ||
run: | | ||
python -m pip install pytest pytest-notebook | ||
python -m pytest --runslow --disable-warnings --color=yes -v | ||
- name: Run tests, coverage and send to coveralls | ||
if: runner.os == 'Linux' && matrix.python-version == 3.8 && matrix.name-suffix == 'coverage' | ||
run: | | ||
pip install pytest pytest-notebook coveralls | ||
coverage run --source=edisgo -m pytest --runslow --disable-warnings --color=yes -v | ||
coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
COVERALLS_SERVICE_NAME: github |
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
[settings] | ||
profile = black | ||
multi_line_output = 3 | ||
lines_between_types = 1 |
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,32 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.3.0 | ||
hooks: | ||
- id: check-yaml | ||
- id: end-of-file-fixer | ||
- id: trailing-whitespace | ||
- repo: https://github.com/psf/black | ||
rev: 22.8.0 | ||
hooks: | ||
- id: black | ||
- repo: https://github.com/pycqa/flake8 | ||
rev: 5.0.4 | ||
hooks: | ||
- id: flake8 | ||
- repo: https://github.com/pycqa/isort | ||
rev: 5.10.1 | ||
hooks: | ||
- id: isort | ||
name: isort (python) | ||
- repo: https://github.com/asottile/pyupgrade | ||
rev: v2.38.0 | ||
hooks: | ||
- id: pyupgrade | ||
#- repo: https://github.com/pycqa/pylint | ||
# rev: pylint-2.6.0 | ||
# hooks: | ||
# - id: pylint | ||
- repo: https://github.com/kynan/nbstripout | ||
rev: 0.6.0 | ||
hooks: | ||
- id: nbstripout |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,66 @@ | ||
edisgo.flex\_opt package | ||
======================== | ||
|
||
edisgo.flex\_opt.charging\_strategies module | ||
-------------------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.charging_strategies | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.check\_tech\_constraints module | ||
------------------------------------------------ | ||
|
||
.. automodule:: edisgo.flex_opt.check_tech_constraints | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.costs module | ||
----------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.costs | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.exceptions module | ||
---------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.exceptions | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.heat_pump_operation module | ||
--------------------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.heat_pump_operation | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.q\_control module | ||
----------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.q_control | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.reinforce\_grid module | ||
--------------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.reinforce_grid | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.flex\_opt.reinforce\_measures module | ||
------------------------------------------- | ||
|
||
.. automodule:: edisgo.flex_opt.reinforce_measures | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
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,34 +1,42 @@ | ||
edisgo.io package | ||
=================== | ||
================= | ||
|
||
edisgo.io.ding0\_import module | ||
------------------------------- | ||
------------------------------ | ||
|
||
.. automodule:: edisgo.io.ding0_import | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.io.electromobility\_import module | ||
---------------------------------------- | ||
|
||
.. automodule:: edisgo.io.electromobility_import | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.io.generators\_import module | ||
----------------------------------- | ||
|
||
.. automodule:: edisgo.io.generators_import | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.io.pypsa\_io module | ||
------------------------------ | ||
-------------------------- | ||
|
||
.. automodule:: edisgo.io.pypsa_io | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
edisgo.io.timeseries\_import module | ||
------------------------------------ | ||
----------------------------------- | ||
|
||
.. automodule:: edisgo.io.timeseries_import | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
Oops, something went wrong.