Skip to content

Rework logger#338

Open
thomaswilliamsastro wants to merge 1 commit into
masterfrom
rework-logging
Open

Rework logger#338
thomaswilliamsastro wants to merge 1 commit into
masterfrom
rework-logging

Conversation

@thomaswilliamsastro
Copy link
Copy Markdown
Collaborator

@thomaswilliamsastro thomaswilliamsastro commented May 15, 2026

This PR reworks logging, to make the output more useful. It'll now overwrite the file if a log output is selected, and the default log format is synchronised between terminal and file. It now looks like this (by default, but can be customised):

[2026-05-16 10:28:59] [INFO] [task_contsub]: &%&%&%&%&%&%&%&%&%&%&%&%&%
[2026-05-16 10:28:59] [INFO] [task_contsub]: u-v continuum subtraction for
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... file: ngc0300_1_flux_ref_2025.1.00576.L_7m_1_co21.ms
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... output: ngc0300_1_flux_ref_2025.1.00576.L_7m_1_co21.ms.contsub
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... excluding frequency ranges: [(np.float64(230.23501715646884), np.float64(230.61951315079776))]
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... fitorder: 0
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... combine: 
[2026-05-16 10:28:59] [INFO] [task_contsub]: ... flag_edge_fraction: 0.0
[2026-05-16 10:28:59] [INFO] [task_contsub]: &%&%&%&%&%&%&%&%&%&%&%&%&%

The pipelineLogger, which was never used anywhere, has now been removed. Finally, there are also now tests that cover the whole logger, and the pipeline doesn't force default to DEBUG.

  • Remove deprecated pipelineLogger module
  • Tidy up phangsLogger.py
  • Tidy up the log format to be consistent and more informative
  • Add test suite
  • Remove debug call throughout
  • Add changelog entry

@codecov
Copy link
Copy Markdown

codecov Bot commented May 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 6.22%. Comparing base (9997b7b) to head (7ffea32).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff            @@
##           master    #338      +/-   ##
=========================================
- Coverage    6.27%   6.22%   -0.06%     
=========================================
  Files          38      38              
  Lines       15229   15192      -37     
  Branches     3653    3649       -4     
=========================================
- Hits          955     945      -10     
+ Misses      14260   14233      -27     
  Partials       14      14              

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

@thomaswilliamsastro thomaswilliamsastro force-pushed the rework-logging branch 3 times, most recently from d41d99a to 3d3c0d9 Compare May 16, 2026 09:31
@thomaswilliamsastro thomaswilliamsastro marked this pull request as ready for review May 16, 2026 09:32
@thomaswilliamsastro
Copy link
Copy Markdown
Collaborator Author

@low-sky this is now ready for review!

@thomaswilliamsastro thomaswilliamsastro force-pushed the rework-logging branch 3 times, most recently from 419f689 to 6123dcd Compare May 16, 2026 10:00
- Remove deprecated pipelineLogger module
- Tidy up phangsLogger.py
- Tidy up the log format to be consistent and more informative
- Add test suite
- Remove debug call throughout
- Add changelog entry
@thomaswilliamsastro
Copy link
Copy Markdown
Collaborator Author

@low-sky any showstoppers on this, or are we good to merge?

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.

1 participant