Skip to content

Convert process initialisation routines to python#3406

Merged
timothy-nunn merged 3 commits intomainfrom
3400-convert-process-initialisation-routines-to-python
Jan 8, 2025
Merged

Convert process initialisation routines to python#3406
timothy-nunn merged 3 commits intomainfrom
3400-convert-process-initialisation-routines-to-python

Conversation

@timothy-nunn
Copy link
Copy Markdown
Collaborator

@timothy-nunn timothy-nunn commented Nov 22, 2024

PROCESS initialisation sequence Fortran -> Python

Iteration variable initialisation sequence Fortran -> Python

initial.f90 post-input pre-model call validation Fortran -> Python

The input validations raise a ProcessValidationError, a new exception introduced specifically for input validation errors in a first move away from the in-built error handling system. As a temporary measure, the non-level 3 errors use warnings.warn until a permanent warning solution is found.

This does mean that our errors and warnings will temporarily operate through two systems, however this is no different how it was in Fortran, with inconsistent use if print/write statements and stop 1 statements.

@timothy-nunn timothy-nunn linked an issue Nov 22, 2024 that may be closed by this pull request
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Nov 22, 2024

Codecov Report

❌ Patch coverage is 72.74678% with 127 lines in your changes missing coverage. Please review.
✅ Project coverage is 30.65%. Comparing base (36523e6) to head (65e198e).
⚠️ Report is 564 commits behind head on main.

Files with missing lines Patch % Lines
process/init.py 73.82% 117 Missing ⚠️
process/exceptions.py 50.00% 7 Missing ⚠️
process/main.py 40.00% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3406      +/-   ##
==========================================
+ Coverage   29.63%   30.65%   +1.02%     
==========================================
  Files          78       80       +2     
  Lines       19105    19567     +462     
==========================================
+ Hits         5661     5999     +338     
- Misses      13444    13568     +124     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Copy Markdown
Contributor

@jonmaddock jonmaddock left a comment

Choose a reason for hiding this comment

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

Great, this is a nice solution.

@timothy-nunn timothy-nunn force-pushed the 3400-convert-process-initialisation-routines-to-python branch from 694a5ba to 65e198e Compare January 8, 2025 09:42
@timothy-nunn timothy-nunn merged commit 54d72c3 into main Jan 8, 2025
@timothy-nunn timothy-nunn deleted the 3400-convert-process-initialisation-routines-to-python branch January 8, 2025 10:52
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.

Convert PROCESS initialisation routines to Python

3 participants