← Back to issue list

feat: fetch logs from inside the build instance

View original Github issue

Metadata

Project
craft-application
Number
#87
Type
pull request
State
merged
Author
tigarmo
Labels
—
Created
Updated
Closed

Current evaluation

Merged to main as commit 519c9aa3. ProviderService.instance() now pulls the managed log file from the build instance (new _capture_logs_from_instance) and appends it to the outer log. Fixes issue #59.

Resolution: closed resolved

Reason: PR #87 was approved and merged as commit 519c9aa3 ("feat: fetch logs from inside the build instance (#87)"), adding ProviderService._capture_logs_from_instance() in craft_application/services/provider.py plus unit tests; the commit's message states "Fixes #59", and the maintainer verified it in rockcraft with logs appearing in the outer instance.

Evaluated by: mr-cal-bot

No scores available.

Issue body

One could argue that this a bugfix since this was missing behavior from the existing craft tools. Regardless, this commit updates the instance() method in the default ProviderService to fetch the logfile from inside the build instance once its done. The contents of this file are then emitted so that they can end up in the logs of the "outer" instance. Fixes #59 - [ ] Have you followed the guidelines for contributing? - [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [ ] Have you successfully run `tox`? -----

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged to main as commit 519c9aa3. ProviderService.instance() now pulls the managed log file from the build instance (new _capture_logs_from_instance) and appends it to the outer log. Fixes issue #59.
stealth/space-bunny-alpha — closed resolved Merged PR #87 (commit 519c9aa3) makes ProviderService.instance() pull the logfile from the finished build instance and emit it, fixing issue #59 where build-instance logs never reached the outer instance.
stealth/space-bunny-alpha — closed resolved Merged as commit 519c9aa3 (PR #87): default ProviderService.instance() now pulls the build instance's logfile after the run and emits it to outer logs. Fixes #59.
stealth/space-bunny-alpha — closed resolved Merged #87, resolving #59: ProviderService.instance() now fetches and emits logs from the completed build instance (commit 519c9aa3).
qwen/qwen3.6-35b-a3b — — Merged PR #87 fixes #59 by updating ProviderService.instance() to retrieve and emit logs from the build container after execution. Approved by two reviewers, passed CI, and verified in rockcraft.

Update history

No update history recorded yet.

Related work

  • Duplicate Of: canonical/craft-application#59 (confidence 97%)

    Issue #59 (logs generated in the build instance are not fetched) was closed by this PR.

  • Related To: canonical/craft-application#691 (confidence 60%)

    Later commit 1f120464 "fix: don't double up on timestamps in managed logs" refines the same managed-log emission feature.

Related issues

Issue Project State Summary Similarity
#77 providers: capture logs from instance rockcraft merged Merged as commit 1fe5b57b: refactored instance log capture to use craft-providers temporarily_pull_file() and moved the method into providers.py.
71%