Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates in site.toml to clear not-used attributes and update some vairables #462

Merged
merged 18 commits into from
Jun 24, 2024

Conversation

panosatha
Copy link
Contributor

@panosatha panosatha commented Jun 12, 2024

Various fixes to avoid having optional configuration as mandatory in the site.toml:

  • remove reference_water_level.reference as it is was not used
  • remove sfincs.ambient_pressure
  • obs_point isn ow optional and FA should not break when you have no observation points
  • renamed obs_station to tide_gauge, and removed reference water levels from it
  • tide_gauge has now a source attr where the either the cht_observation source is defined or "file" to use a downloaded file
  • renamed risk.flooding_threshold to flooding_frequency.threshold
  • river is now optional
  • slr scenarios are now better defined in the site.toml
  • offshore model and cyclone tracks not mandatory

@panosatha panosatha linked an issue Jun 12, 2024 that may be closed by this pull request
10 tasks
@panosatha panosatha requested a review from GundulaW June 12, 2024 15:19
@panosatha panosatha marked this pull request as ready for review June 12, 2024 15:36
Copy link
Contributor

@GundulaW GundulaW left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backend looks fine, but some things in the GUI broke, see GUI PR.

Copy link
Contributor

@GundulaW GundulaW left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All working for me now

@panosatha panosatha merged commit c87bc85 into main Jun 24, 2024
4 of 5 checks passed
@panosatha panosatha deleted the 422-site-toml-issues branch June 24, 2024 16:27
dumontgoulart added a commit that referenced this pull request Jul 9, 2024
* take most of the env creation script from frontend and put it in the … (#467)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* added temporary event name for plotting rainfall and river (#470)

* Move env creation to backend (#468)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* fix bug in env creation

* black

* pre-commit version and fiat adapter test not skipped anymore (#463)

* updated pre-commit version

* updated svn repo so this test can be run now

* return periods test is not skipped anymore with fiat_toolbox updates

* changed cht_observation to git repo install

* chore: close all loggers & handlers in database fixture setup and teardown

* fix: Output more info if incompatible river coordinates in SFINCS adapter and sitetoml

* add reset() to dbs_controller.py

* reset database in conftest.py

* black

* fix versions of formatting tools

---------

Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>

* Add self check to hazard run check (#471)

* Add self check to hazard run check

* Fix black

* Updates in site.toml to clear not-used attributes and update some vairables (#462)

* removed unused attributes from site toml

* small update in lint

* made observation points non mandatory

* changed site attribute obs_station to tide_gauge and removed unused attributes

* changed the flooding_threshold attribute to belong to a flood_frequency variable

* added default value for flood frequency flooding threshold

* when no river is present template discharge is used for now

* added source option to tide_gauge site attribute

* small correction in docstring

* changed slr.scenarios in site.toml and made them not mandatory

* offshore model and cyclone tracks not mandatory anymore

* small updates

* naming change

* make sure that the workflow does not break when there is nothing to plot

* todo on api for aggregation

* revert rename (#474)

* Fix logging and tests (#475)

* fix api output fixture and tests

* return -> yield in all fixtures

* return -> yield in all fixtures

* fix scenario.run() tests

* add logging class and implement in codebase

* bugfix logger contextmanager

* improve test logging

* fix bug in create_roads

* Add attribute check to adapter logger

* Config changes (#476)

* database path updates

* Update config getters to return Paths where needed

* Update lint.yml

* Update lint.yml

---------

Co-authored-by: GundulaW <gundulawinter@gmail.com>

* Split mandatory and optional metrics (#477)

---------

Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>
Co-authored-by: Panos Athanasiou <38324721+panosatha@users.noreply.github.com>
Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: dladrichem <136334482+dladrichem@users.noreply.github.com>
Co-authored-by: Daley Adrichem <daley.adrichem@deltares.nl>
Co-authored-by: GundulaW <gundulawinter@gmail.com>
dumontgoulart added a commit that referenced this pull request Jul 9, 2024
* take most of the env creation script from frontend and put it in the … (#467)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* added temporary event name for plotting rainfall and river (#470)

* Move env creation to backend (#468)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* fix bug in env creation

* black

* pre-commit version and fiat adapter test not skipped anymore (#463)

* updated pre-commit version

* updated svn repo so this test can be run now

* return periods test is not skipped anymore with fiat_toolbox updates

* changed cht_observation to git repo install

* chore: close all loggers & handlers in database fixture setup and teardown

* fix: Output more info if incompatible river coordinates in SFINCS adapter and sitetoml

* add reset() to dbs_controller.py

* reset database in conftest.py

* black

* fix versions of formatting tools

---------

Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>

* Add self check to hazard run check (#471)

* Add self check to hazard run check

* Fix black

* Updates in site.toml to clear not-used attributes and update some vairables (#462)

* removed unused attributes from site toml

* small update in lint

* made observation points non mandatory

* changed site attribute obs_station to tide_gauge and removed unused attributes

* changed the flooding_threshold attribute to belong to a flood_frequency variable

* added default value for flood frequency flooding threshold

* when no river is present template discharge is used for now

* added source option to tide_gauge site attribute

* small correction in docstring

* changed slr.scenarios in site.toml and made them not mandatory

* offshore model and cyclone tracks not mandatory anymore

* small updates

* naming change

* make sure that the workflow does not break when there is nothing to plot

* todo on api for aggregation

* revert rename (#474)

* Fix logging and tests (#475)

* fix api output fixture and tests

* return -> yield in all fixtures

* return -> yield in all fixtures

* fix scenario.run() tests

* add logging class and implement in codebase

* bugfix logger contextmanager

* improve test logging

* fix bug in create_roads

* Add attribute check to adapter logger

* Config changes (#476)

* database path updates

* Update config getters to return Paths where needed

* Update lint.yml

* Update lint.yml

---------

Co-authored-by: GundulaW <gundulawinter@gmail.com>

* Split mandatory and optional metrics (#477)

---------

Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>
Co-authored-by: Panos Athanasiou <38324721+panosatha@users.noreply.github.com>
Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: dladrichem <136334482+dladrichem@users.noreply.github.com>
Co-authored-by: Daley Adrichem <daley.adrichem@deltares.nl>
Co-authored-by: GundulaW <gundulawinter@gmail.com>
dumontgoulart added a commit that referenced this pull request Jul 11, 2024
* take most of the env creation script from frontend and put it in the … (#467)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* added temporary event name for plotting rainfall and river (#470)

* Move env creation to backend (#468)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* fix bug in env creation

* black

* pre-commit version and fiat adapter test not skipped anymore (#463)

* updated pre-commit version

* updated svn repo so this test can be run now

* return periods test is not skipped anymore with fiat_toolbox updates

* changed cht_observation to git repo install

* chore: close all loggers & handlers in database fixture setup and teardown

* fix: Output more info if incompatible river coordinates in SFINCS adapter and sitetoml

* add reset() to dbs_controller.py

* reset database in conftest.py

* black

* fix versions of formatting tools

---------

Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>

* Add self check to hazard run check (#471)

* Add self check to hazard run check

* Fix black

* Updates in site.toml to clear not-used attributes and update some vairables (#462)

* removed unused attributes from site toml

* small update in lint

* made observation points non mandatory

* changed site attribute obs_station to tide_gauge and removed unused attributes

* changed the flooding_threshold attribute to belong to a flood_frequency variable

* added default value for flood frequency flooding threshold

* when no river is present template discharge is used for now

* added source option to tide_gauge site attribute

* small correction in docstring

* changed slr.scenarios in site.toml and made them not mandatory

* offshore model and cyclone tracks not mandatory anymore

* small updates

* naming change

* make sure that the workflow does not break when there is nothing to plot

* todo on api for aggregation

* revert rename (#474)

* Fix logging and tests (#475)

* fix api output fixture and tests

* return -> yield in all fixtures

* return -> yield in all fixtures

* fix scenario.run() tests

* add logging class and implement in codebase

* bugfix logger contextmanager

* improve test logging

* fix bug in create_roads

* Add attribute check to adapter logger

* Config changes (#476)

* database path updates

* Update config getters to return Paths where needed

* Update lint.yml

* Update lint.yml

---------

Co-authored-by: GundulaW <gundulawinter@gmail.com>

* Split mandatory and optional metrics (#477)

---------

Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>
Co-authored-by: Panos Athanasiou <38324721+panosatha@users.noreply.github.com>
Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: dladrichem <136334482+dladrichem@users.noreply.github.com>
Co-authored-by: Daley Adrichem <daley.adrichem@deltares.nl>
Co-authored-by: GundulaW <gundulawinter@gmail.com>
dumontgoulart added a commit that referenced this pull request Jul 11, 2024
* take most of the env creation script from frontend and put it in the … (#467)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* added temporary event name for plotting rainfall and river (#470)

* Move env creation to backend (#468)

* take most of the env creation script from frontend and put it in the backend

* move env_docs.yml to the docs dir

* update readme

* fix bug in env creation

* black

* pre-commit version and fiat adapter test not skipped anymore (#463)

* updated pre-commit version

* updated svn repo so this test can be run now

* return periods test is not skipped anymore with fiat_toolbox updates

* changed cht_observation to git repo install

* chore: close all loggers & handlers in database fixture setup and teardown

* fix: Output more info if incompatible river coordinates in SFINCS adapter and sitetoml

* add reset() to dbs_controller.py

* reset database in conftest.py

* black

* fix versions of formatting tools

---------

Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>

* Add self check to hazard run check (#471)

* Add self check to hazard run check

* Fix black

* Updates in site.toml to clear not-used attributes and update some vairables (#462)

* removed unused attributes from site toml

* small update in lint

* made observation points non mandatory

* changed site attribute obs_station to tide_gauge and removed unused attributes

* changed the flooding_threshold attribute to belong to a flood_frequency variable

* added default value for flood frequency flooding threshold

* when no river is present template discharge is used for now

* added source option to tide_gauge site attribute

* small correction in docstring

* changed slr.scenarios in site.toml and made them not mandatory

* offshore model and cyclone tracks not mandatory anymore

* small updates

* naming change

* make sure that the workflow does not break when there is nothing to plot

* todo on api for aggregation

* revert rename (#474)

* Fix logging and tests (#475)

* fix api output fixture and tests

* return -> yield in all fixtures

* return -> yield in all fixtures

* fix scenario.run() tests

* add logging class and implement in codebase

* bugfix logger contextmanager

* improve test logging

* fix bug in create_roads

* Add attribute check to adapter logger

* Config changes (#476)

* database path updates

* Update config getters to return Paths where needed

* Update lint.yml

* Update lint.yml

---------

Co-authored-by: GundulaW <gundulawinter@gmail.com>

* Split mandatory and optional metrics (#477)

---------

Co-authored-by: LuukBlom <153174893+LuukBlom@users.noreply.github.com>
Co-authored-by: Panos Athanasiou <38324721+panosatha@users.noreply.github.com>
Co-authored-by: LuukBlom <luuk.blom@deltares.nl>
Co-authored-by: dladrichem <136334482+dladrichem@users.noreply.github.com>
Co-authored-by: Daley Adrichem <daley.adrichem@deltares.nl>
Co-authored-by: GundulaW <gundulawinter@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

site toml issues
2 participants