From 4c41fa6b1657ea7f7b2efaa47708a18a8206c251 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Kl=C3=B6tzke?= Date: Fri, 26 Jun 2026 17:45:59 +0200 Subject: [PATCH 1/2] setup: move setuptools-scm dependency to pyproject.toml Apparently, adding the dependency in setup.py is not supported anymore. --- pyproject.toml | 2 +- setup.py | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index cd72df0d..2147fb13 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,3 @@ [build-system] -requires = ["setuptools >= 40.0", "Sphinx"] +requires = ["setuptools >= 40.0", "setuptools-scm", "Sphinx"] build-backend = "setuptools.build_meta" diff --git a/setup.py b/setup.py index 6d61f2d4..e0d2e4dc 100644 --- a/setup.py +++ b/setup.py @@ -147,11 +147,6 @@ class build(build_orig): 'azure' : [ 'azure-storage-blob' ], }, - # Installation time dependencies only needed by setup.py - setup_requires = [ - 'setuptools_scm', # automatically get package version - ], - # Provide executables entry_points = { 'console_scripts' : [ From 477c8b97885afc47761cbadd56ab6bf9072c2d5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Kl=C3=B6tzke?= Date: Sun, 21 Jun 2026 10:39:21 +0200 Subject: [PATCH 2/2] invoker: don't show output of captured commands by default Capturing the output (stdout and/or stderr) of a command and the visibility of the output streams to the user used to be independent options. This is confusing, though. If the output is captured, it means that it is coming from some redirected, Bob-internal command. The user is unaware what command that is and will just observe random output. To make it more understandable, show the redirected output only if the command is traced. Fixes #699. --- pym/bob/invoker.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/pym/bob/invoker.py b/pym/bob/invoker.py index 63e7fefe..30901f65 100644 --- a/pym/bob/invoker.py +++ b/pym/bob/invoker.py @@ -291,7 +291,11 @@ async def __runCommand(self, args, cwd, stdout=None, stderr=None, # If stdout should be captured we use a dedicated buffer. This # buffer is then returned to the caller at child exit. stdoutRedir = subprocess.PIPE - stdoutStreams = [io.BytesIO(), self.__stdoutStream] + stdoutStreams = [io.BytesIO()] + if self.__trace: + # Only show stdout to the user if the command is traced. + # Otherwise it is unclear where it came from. + stdoutStreams.append(self.__stdoutStream) elif stdout == False: stdoutRedir = subprocess.DEVNULL stdoutStreams = [] @@ -306,7 +310,11 @@ async def __runCommand(self, args, cwd, stdout=None, stderr=None, # If stderr should be captured we use a dedicated buffer. This # buffer is then returned to the caller at child exit. stderrRedir = subprocess.PIPE - stderrStreams = [io.BytesIO(), self.__stderrStream] + stderrStreams = [io.BytesIO()] + if self.__trace: + # Only show stderr to the user if the command is traced. + # Otherwise it is unclear where it came from. + stderrStreams.append(self.__stderrStream) elif stderr == False: stderrRedir = subprocess.DEVNULL stderrStreams = []