Skip to content

Enhancement/windows ci#590

Open
RHammond2 wants to merge 45 commits intoNatLabRockies:developfrom
RHammond2:enhancement/windows-ci
Open

Enhancement/windows ci#590
RHammond2 wants to merge 45 commits intoNatLabRockies:developfrom
RHammond2:enhancement/windows-ci

Conversation

@RHammond2
Copy link
Copy Markdown
Collaborator

@RHammond2 RHammond2 commented Mar 10, 2026

Unpin coin-or-cbc to enable simplified Windows installations

This PR adopts coin-or-cbc version 2.10.12 or greater to coincide with the conda-forge packaging. All CI and installation instructions have also been updated. In addition, the nonfunctional Code-Coverage integration has been swapped with Coveralls.

Several updates needed to be made for consistent results on Windows and all other OS:

  • The temp_dir fixture's scope was downgraded to only functions because Windows was unable to handle tests accessing the same file.
  • The temp_copy_of_example fixture was moved to the top-level conftest.py, and is now imported in all lower-level contest.py files.
  • A new module-scoped temp_copy_of_example_module_scope was created, but not universally imported to allow for the tests in h2integrate/core/test/test_recorder.py to run through the process of creating SQL report files using the same base name across multiple process.

Section 1: Type of Contribution

  • Feature Enhancement
    • Framework
    • New Model
    • Updated Model
    • Tools/Utilities
    • Other (please describe): dependency updates
  • Bug Fix
  • Documentation Update
  • CI Changes
  • Other (please describe):

Section 2: Draft PR Checklist

  • Open draft PR
  • Describe the feature that will be added
  • Fill out TODO list steps
  • Describe requested feedback from reviewers on draft PR
  • Complete Section 7: New Model Checklist (if applicable)

TODO:

  • Step 1
  • Step 2

Type of Reviewer Feedback Requested (on Draft PR)

Structural feedback:

Implementation feedback:

Other feedback:

Section 3: General PR Checklist

  • PR description thoroughly describes the new feature, bug fix, etc.
  • Added tests for new functionality or bug fixes
  • Tests pass (If not, and this is expected, please elaborate in the Section 6: Test Results)
  • Documentation
    • Docstrings are up-to-date
    • Related docs/ files are up-to-date, or added when necessary
    • Documentation has been rebuilt successfully
    • Examples have been updated (if applicable)
  • CHANGELOG.md has been updated to describe the changes made in this PR

Section 3: Related Issues

Closes #25

Section 4: Impacted Areas of the Software

Section 4.1: New Files

N/A

Section 4.2: Modified Files

  • **/test/conftest.py: All conftest files now import the now top-level temp_copy_of_example for isolated access to examples data.
  • .github/workflows/ci.yml:
    • Reverts back to a conda-based Python action for running tests
    • Swaps Code-Coverage for Coveralls for test coverage reporting
    • The optional modifier is set to true to run all tests across all instances, and false for only a single runner to ensure the tests with optional dependencies are successfully skipped
    • YAML list formatting
  • README.md & docs/getting_started/install.md: updates Windows installations instructions
  • environment.yml: Adds the latest coin-or-cbc dependency universally
  • examples/test/test_all_examples.py
    • examples/test/test_all_examples.py: moved to test/conftest.py
    • test_28_iron_map_example: skipped when gis optional dependencies are not installed.
  • h2integrate/postprocess/test/test_mapping_tools.py: skips all tests when gis optional dependencies are not installed.
  • test/conftest.py:
    • temp_dir: downgraded to a function-scoped fixture to allow tests to pass on Windows
    • temp_dir_module: copy of temp_dir, but without teardown between functions in a module
    • temp_copy_of_example_module_scope: copy of temp_copy_of_example, but without teardown between functions in a module
  • h2integrate/core/test/test_recorder.py: Uses the module scoped example copy fixture to streamline the creation of multiple identically named files across multiple copies. All folder usage and checks have been updated to match with additional streamlining.
  • h2integrate/postprocess/test/test_sql_timeseries_to_csv.py: Uses the temp_copy_of_example fixture to potentially isolate the access to the .sql files for consistent results in Windows.
  • h2integrate/converters/co2/marine/test/conftest.py:
    • driver_config: converted to function scope to avoid compatibility issues with temp_dir's scope.

Section 5: Additional Supporting Information

N/A

Section 6: Test Results, if applicable

N/A

@RHammond2 RHammond2 added enhancement New feature or request code cleanup labels Mar 10, 2026
RHammond2 and others added 26 commits March 10, 2026 12:41
@RHammond2 RHammond2 requested a review from johnjasa March 12, 2026 23:57
@RHammond2 RHammond2 added the ready for review This PR is ready for input from folks label Mar 12, 2026
@RHammond2 RHammond2 marked this pull request as ready for review March 12, 2026 23:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

code cleanup enhancement New feature or request ready for review This PR is ready for input from folks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants