From b9a80d19bf47dd8e0e683b0dd0d8ae4b75fb9f2b Mon Sep 17 00:00:00 2001 From: Bart van der Braak Date: Tue, 18 Jun 2024 16:01:05 +0200 Subject: [PATCH] Merge changes from upstream --- buildbot/pipeline/code.py | 10 +++++----- buildbot/pipeline/code_store.py | 8 ++++---- buildbot/pipeline/common.py | 8 ++++---- buildbot/worker/blender/lint.py | 7 ++++--- buildbot/worker/doc_manual.py | 4 ++-- buildbot/worker/utils.py | 2 +- 6 files changed, 20 insertions(+), 19 deletions(-) diff --git a/buildbot/pipeline/code.py b/buildbot/pipeline/code.py index 1af64b9..040282a 100644 --- a/buildbot/pipeline/code.py +++ b/buildbot/pipeline/code.py @@ -717,8 +717,8 @@ def populate(devops_env_id): ] if needs_nightly_schedulers and (track_id in code_track_ids): - nighlty_scheduler_name = ( - f"{track_id}-code-{pipeline_type}-coordinator-nighlty" + nightly_scheduler_name = ( + f"{track_id}-code-{pipeline_type}-coordinator-nightly" ) nightly_properties = { "revision": "HEAD", @@ -729,7 +729,7 @@ def populate(devops_env_id): "build_configuration": "release", "platform_architectures": code_all_platform_architectures[track_id], } - nighlty_codebases = { + nightly_codebases = { "blender.git": { "repository": "", "branch": code_tracked_branch_ids[track_id], @@ -738,9 +738,9 @@ def populate(devops_env_id): } schedulers += [ plugins_schedulers.Nightly( - name=nighlty_scheduler_name, + name=nightly_scheduler_name, builderNames=[coordinator_builder_name], - codebases=nighlty_codebases, + codebases=nightly_codebases, properties=nightly_properties, onlyIfChanged=False, hour=1, diff --git a/buildbot/pipeline/code_store.py b/buildbot/pipeline/code_store.py index 308d3a5..6a51592 100644 --- a/buildbot/pipeline/code_store.py +++ b/buildbot/pipeline/code_store.py @@ -209,11 +209,11 @@ def populate(devops_env_id): ] if needs_nightly_schedulers and (track_id in track_ids): - nighlty_scheduler_name = f"{track_id}-code-store-coordinator-nighlty" + nightly_scheduler_name = f"{track_id}-code-store-coordinator-nightly" nightly_properties = { "revision": "HEAD", } - nighlty_codebases = { + nightly_codebases = { "blender.git": { "repository": "", "branch": tracked_branch_ids[track_id], @@ -222,9 +222,9 @@ def populate(devops_env_id): } schedulers += [ plugins_schedulers.Nightly( - name=nighlty_scheduler_name, + name=nightly_scheduler_name, builderNames=[coordinator_builder_name], - codebases=nighlty_codebases, + codebases=nightly_codebases, properties=nightly_properties, onlyIfChanged=False, hour=5, diff --git a/buildbot/pipeline/common.py b/buildbot/pipeline/common.py index 5cdb724..6197159 100644 --- a/buildbot/pipeline/common.py +++ b/buildbot/pipeline/common.py @@ -312,19 +312,19 @@ def create_pipeline( ] if needs_nightly_schedulers and (track_id in track_ids): - nighlty_codebases = { + nightly_codebases = { codebase: { "repository": "", "branch": tracked_branch_ids[track_id], "revision": None, } } - nighlty_scheduler_name = f"{track_id}-{artifact_id}-coordinator-nighlty" + nightly_scheduler_name = f"{track_id}-{artifact_id}-coordinator-nightly" schedulers += [ plugins_schedulers.Nightly( - name=nighlty_scheduler_name, + name=nightly_scheduler_name, builderNames=[coordinator_builder_name], - codebases=nighlty_codebases, + codebases=nightly_codebases, properties=nightly_properties, onlyIfChanged=False, hour=hour, diff --git a/buildbot/worker/blender/lint.py b/buildbot/worker/blender/lint.py index 44d8bed..5c0afcd 100644 --- a/buildbot/worker/blender/lint.py +++ b/buildbot/worker/blender/lint.py @@ -12,8 +12,6 @@ import worker.utils def make_format(builder: worker.blender.CodeBuilder) -> bool: os.chdir(builder.blender_dir) - makefile = "make.bat" if builder.platform == "windows" else "GNUmakefile" - # Always run formatting with scripts from main, for security on unverified patches. # TODO: how secure is this? How to test formatting issues in the scripts themselves? # main_files = [makefile, "tools/utils_maintenance", "build_files/windows"] @@ -21,7 +19,10 @@ def make_format(builder: worker.blender.CodeBuilder) -> bool: # worker.utils.call(['git', 'checkout', 'origin/main', '--', main_file]) # Run format - builder.call(["make", "-f", makefile, "format"]) + if builder.platform == "windows": + builder.call(["make.bat", "format"]) + else: + builder.call(["make", "-f", "GNUmakefile", "format"]) # Check for changes diff = worker.utils.check_output(["git", "diff"]) diff --git a/buildbot/worker/doc_manual.py b/buildbot/worker/doc_manual.py index 3c774b6..e7c5387 100755 --- a/buildbot/worker/doc_manual.py +++ b/buildbot/worker/doc_manual.py @@ -48,7 +48,7 @@ def update(builder: ManualBuilder) -> None: def check(builder: ManualBuilder) -> None: os.chdir(builder.track_path) - worker.utils.call_pipenv(["install", "--requirements", builder.code_path / "requirements.txt"]) + worker.utils.call_pipenv(["install", "--pre", "--requirements", builder.code_path / "requirements.txt"]) os.chdir(builder.code_path) @@ -61,7 +61,7 @@ def check(builder: ManualBuilder) -> None: def compile_doc(builder: ManualBuilder) -> None: # Install requirements. os.chdir(builder.track_path) - worker.utils.call_pipenv(["install", "--requirements", builder.code_path / "requirements.txt"]) + worker.utils.call_pipenv(["install", "--pre", "--requirements", builder.code_path / "requirements.txt"]) # Determine format and locales locales = builder.get_locales() diff --git a/buildbot/worker/utils.py b/buildbot/worker/utils.py index a01c1bd..bc3e03f 100644 --- a/buildbot/worker/utils.py +++ b/buildbot/worker/utils.py @@ -104,7 +104,7 @@ def _log_cmd(msg: str) -> None: _warnings += [msg] return - print(msg, flush=True) + print(msg.encode('utf-8', errors='replace'), flush=True) # Command execution -- 2.30.2