Skip to content

Add simtools log file to grid output.#2040

Merged
GernotMaier merged 4 commits intomainfrom
pack-for-register-simtools-log
Feb 13, 2026
Merged

Add simtools log file to grid output.#2040
GernotMaier merged 4 commits intomainfrom
pack-for-register-simtools-log

Conversation

@GernotMaier
Copy link
Copy Markdown
Contributor

@GernotMaier GernotMaier commented Feb 12, 2026

Add simtools log file to grid output tar package.

Note that the simtools log file will be included in the tar package for each model version. I guess this duplication if acceptable.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds the simtools application log file to the per-model grid upload tarballs, so grid outputs include the full simtools runtime context (and adjusts the simulate-prod app label/logging sequence accordingly).

Changes:

  • Add get_simtools_log_file() helper to discover an attached logging.FileHandler log path (walking logger parents).
  • Include the discovered simtools log file in Simulator.pack_for_register() tarball contents.
  • Update simulate_prod to set an application label and emit report() before packing, plus add a changelog entry and unit tests for the new helper.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/simtools/utils/general.py Adds helper to locate the simtools log file from logger handlers.
src/simtools/simulator.py Adds simtools log file to per-model grid tarball packaging.
src/simtools/applications/simulate_prod.py Sets application label for consistent log naming; moves report() earlier so it’s captured before packing.
tests/unit_tests/utils/test_general.py Adds unit tests for get_simtools_log_file().
docs/changes/2040.feature.md Documents the new behavior in the changelog.

@GernotMaier GernotMaier marked this pull request as ready for review February 12, 2026 11:38
@ctao-sonarqube
Copy link
Copy Markdown

@GernotMaier
Copy link
Copy Markdown
Contributor Author

@EshitaJoshi - this is a direct follow up to #2039

Copy link
Copy Markdown
Collaborator

@EshitaJoshi EshitaJoshi left a comment

Choose a reason for hiding this comment

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

Thanks, all good

Base automatically changed from logging-to-file to main February 13, 2026 08:44
@GernotMaier
Copy link
Copy Markdown
Contributor Author

And thanks again @EshitaJoshi

@GernotMaier GernotMaier merged commit 3265d7c into main Feb 13, 2026
12 checks passed
@GernotMaier GernotMaier deleted the pack-for-register-simtools-log branch February 13, 2026 08:45
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.

3 participants