Skip to content

feat: fix command formating - #840

Open
lczyk wants to merge 1 commit into
canonical:mainfrom
lczyk:fix/snapd-command-format
Open

feat: fix command formating#840
lczyk wants to merge 1 commit into
canonical:mainfrom
lczyk:fix/snapd-command-format

Conversation

@lczyk

@lczyk lczyk commented Oct 15, 2025

Copy link
Copy Markdown
  • Have you followed the guidelines for contributing?
  • Have you signed the CLA?
  • Have you successfully run make lint && make test?

...
2025-10-15 14:08:29.458 Executing command on host: ['snap', 'known', 'account', 'account-id=canonical']
2025-10-15 14:08:29.507 Executing in container: lxc --project rockcraft exec local:rockcraft-prime-arm64-4100954 -- env CRAFT_MANAGED_MODE=1 ROCKCRAFT_DEBUG=False ROCKCRAFT_LXD_REMOTE=local ROCKCRAFT_LAUNCHPAD_INSTANCE=production DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true DEBIAN_PRIORITY=critical test -d /tmp
...

note the discrepancy between Executing command on host and Executing in container. this PR fixes that

@lczyk
lczyk requested a review from cmatsuoka as a code owner October 15, 2025 13:22
@lengau
lengau requested a review from Copilot December 6, 2025 03:52

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes inconsistent command formatting in log messages by ensuring commands are properly formatted as shell strings. The change addresses a discrepancy where "Executing command on host" logged commands differently than "Executing in container" messages.

  • Updates the _get_assertion function to format command output consistently using shlex.join()

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread craft_providers/actions/snap_installer.py
@lengau
lengau requested a review from tigarmo December 8, 2025 15:31
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