Skip to content

Separate out constants into consts.py#801

Merged
katiebreivik merged 9 commits into
COSMIC-PopSynth:developfrom
TomWagg:consts
Jun 16, 2026
Merged

Separate out constants into consts.py#801
katiebreivik merged 9 commits into
COSMIC-PopSynth:developfrom
TomWagg:consts

Conversation

@TomWagg

@TomWagg TomWagg commented Jun 15, 2026

Copy link
Copy Markdown
Collaborator

A pretty simple PR here that reduces the length of evolve.py by 100 lines - aren't for loops nifty? 🙃

I've separated out the column constants into their own file. This will make setting them in backpop super simple. I've also updated the new settings docs (reduced number of things to change by 1 :D).

Oh and random small thing: CMC tests now use a temp directory for their sampling writeout rather than the directory you use to run tests. No more random input.hdf5 files :)

@TomWagg TomWagg requested a review from katiebreivik June 15, 2026 17:24
@TomWagg TomWagg self-assigned this Jun 15, 2026
@TomWagg TomWagg added the development tests, automation & code cleanup label Jun 15, 2026
@github-actions github-actions Bot added the needs-cmc-review PR touches cosmic core settings and needs CMC review label Jun 15, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🚨 CMC review requested

This pull request modifies one or more of:

  • src/cosmic/evolve.py
  • src/cosmic/data/cosmic-settings.json (only flagged when category: "bse" key-count changes)

Trigger: evolve file changed, probably needs CMC review

A CMC developer should review this PR to ensure corresponding changes are propagated upstream as needed.

@codecov

codecov Bot commented Jun 15, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 36.36364% with 21 lines in your changes missing coverage. Please review.
✅ Project coverage is 76.48%. Comparing base (8772c07) to head (f3caf82).
⚠️ Report is 172 commits behind head on develop.

Files with missing lines Patch % Lines
src/cosmic/evolve.py 0.00% 14 Missing ⚠️
src/cosmic/consts.py 0.00% 7 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##           develop     #801       +/-   ##
============================================
- Coverage    86.91%   76.48%   -10.43%     
============================================
  Files           40       59       +19     
  Lines        25542    28036     +2494     
  Branches         0      919      +919     
============================================
- Hits         22198    21442      -756     
- Misses        3344     6290     +2946     
- Partials         0      304      +304     

☔ View full report in Codecov by Harness.
📢 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.

@katiebreivik katiebreivik left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is great! Thanks @TomWagg

@katiebreivik katiebreivik merged commit a97391a into COSMIC-PopSynth:develop Jun 16, 2026
5 of 7 checks passed
@TomWagg TomWagg deleted the consts branch June 16, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

development tests, automation & code cleanup needs-cmc-review PR touches cosmic core settings and needs CMC review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants