Skip to content

Commit

Permalink
Fix/minor errors (#98)
Browse files Browse the repository at this point in the history
* bump ortools version

* small test fix

* fix link

* update

* update

* update

* update

* fix python version

* fix python version

* fix python version

* try relax rule

* error in README.md

* no 3.8

* no 3.8

* add AS to  AUTHORS.txt
  • Loading branch information
sgatto authored Nov 19, 2024
1 parent 9e65621 commit 31ad26c
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 19 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,18 @@ jobs:
build:
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, '[skip ci]')"
env:
CI: false
strategy:
max-parallel: 4
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
python-version: [3.6, 3.7, 3.8]
python-version: ["3.9", "3.10"]

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v1
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- uses: psf/black@stable
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Set up Python 3.6
uses: actions/setup-python@v1
- uses: actions/checkout@v4
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: 3.6
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Set up Python 3.6
uses: actions/setup-python@v1
- uses: actions/checkout@v4
- name: Set up Python 3.9
uses: actions/setup-python@v5
with:
python-version: 3.6
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
3 changes: 2 additions & 1 deletion AUTHORS.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Authors ordered by first contribution.

Francois Jolain <francois.jolain@rte-international.com>
Francois Jolain <francois.jolain@rte-international.com>
Andrea Sgattoni <andrea.sgattoni@rte-france.com>
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Contributing
We appreciate your helps

Before fillings issue, please read [Contribution Guide](https://doc.hadar-simulator.org/en/develop/dev-guide/devops.html)
Before fillings issue, please read [Contribution Guide](https://doc.hadar-simulator.org/en/develop/dev-guide/index.html)
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Each kind of network has a needs of adequacy. On one side, some network nodes ne
items such as watt, litter, package. And other side, some network nodes produce items.
Applying adequacy on network, is tring to find the best available exchanges to avoid any lack at the best cost.

For example, a electric grid can have some nodes wich produce too more power and some nodes which produce not enough power.
For example, a electric grid can have some nodes that can produce more power than they need and some nodes that do not produce enough power.

![adequacy](examples/Get%20Started/figure.png)

Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pandas>=1.0.3,<2.0.0
numpy>=1.18.2,<2.0.0
ortools>=7.5.7466,<8.0.0
ortools>=7.5.7466,<10.0.0
plotly==4.8.1
matplotlib>=3.2.1,<4.0.0
requests>=2.23.0,<3.0.0
Expand Down
8 changes: 4 additions & 4 deletions tests/analyzer/test_result.py
Original file line number Diff line number Diff line change
Expand Up @@ -547,8 +547,8 @@ def test_build_src_converter(self):
def test_aggregate_to_conv(self):
# Expected
exp_conv = pd.DataFrame(
data={"flow": [10, 1, 1], "max": [5] * 3, "ratio": [2] * 3},
index=pd.Index([0, 1, 2], name="t"),
data={"flow": [10., 1., 1.], "max": [5] * 3, "ratio": [2] * 3},
index=pd.Index([0., 1., 2.], name="t"),
)

agg = ResultAnalyzer(study=self.study, result=self.result)
Expand All @@ -559,8 +559,8 @@ def test_aggregate_to_conv(self):
def test_aggregate_from_conv(self):
# Expected
exp_conv = pd.DataFrame(
data={"cost": [1] * 3, "flow": [20, 2, 2], "max": [10] * 3},
index=pd.Index([0, 1, 2], name="t"),
data={"cost": [1] * 3, "flow": [20., 2., 2.], "max": [10] * 3},
index=pd.Index([0., 1., 2.], name="t"),
)

agg = ResultAnalyzer(study=self.study, result=self.result)
Expand Down

0 comments on commit 31ad26c

Please sign in to comment.