Skip to content

Commit 50c5273

Browse files
committed
artifact.proto: Add a field for the build sandbox state
1 parent e468aea commit 50c5273

File tree

3 files changed

+28
-8
lines changed

3 files changed

+28
-8
lines changed

src/buildstream/_protos/buildstream/v2/artifact.proto

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,11 @@ message Artifact {
8585

8686
// digest of a directory
8787
build.bazel.remote.execution.v2.Digest buildroot = 17; // optional
88+
89+
message SandboxState {
90+
repeated build.bazel.remote.execution.v2.Command.EnvironmentVariable environment = 1;
91+
string working_directory = 2;
92+
repeated build.bazel.remote.execution.v2.Digest subsandbox_digests = 3;
93+
};
94+
SandboxState buildsandbox = 18; // optional
8895
}

src/buildstream/_protos/buildstream/v2/artifact_pb2.py

Lines changed: 8 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/buildstream/_protos/buildstream/v2/artifact_pb2.pyi

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ from typing import ClassVar as _ClassVar, Iterable as _Iterable, Mapping as _Map
88
DESCRIPTOR: _descriptor.FileDescriptor
99

1010
class Artifact(_message.Message):
11-
__slots__ = ("version", "build_success", "build_error", "build_error_details", "strong_key", "weak_key", "was_workspaced", "files", "build_deps", "public_data", "logs", "buildtree", "sources", "low_diversity_meta", "high_diversity_meta", "strict_key", "buildroot")
11+
__slots__ = ("version", "build_success", "build_error", "build_error_details", "strong_key", "weak_key", "was_workspaced", "files", "build_deps", "public_data", "logs", "buildtree", "sources", "low_diversity_meta", "high_diversity_meta", "strict_key", "buildroot", "buildsandbox")
1212
class Dependency(_message.Message):
1313
__slots__ = ("project_name", "element_name", "cache_key", "was_workspaced")
1414
PROJECT_NAME_FIELD_NUMBER: _ClassVar[int]
@@ -27,6 +27,15 @@ class Artifact(_message.Message):
2727
name: str
2828
digest: _remote_execution_pb2.Digest
2929
def __init__(self, name: _Optional[str] = ..., digest: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ...) -> None: ...
30+
class SandboxState(_message.Message):
31+
__slots__ = ("environment", "working_directory", "subsandbox_digests")
32+
ENVIRONMENT_FIELD_NUMBER: _ClassVar[int]
33+
WORKING_DIRECTORY_FIELD_NUMBER: _ClassVar[int]
34+
SUBSANDBOX_DIGESTS_FIELD_NUMBER: _ClassVar[int]
35+
environment: _containers.RepeatedCompositeFieldContainer[_remote_execution_pb2.Command.EnvironmentVariable]
36+
working_directory: str
37+
subsandbox_digests: _containers.RepeatedCompositeFieldContainer[_remote_execution_pb2.Digest]
38+
def __init__(self, environment: _Optional[_Iterable[_Union[_remote_execution_pb2.Command.EnvironmentVariable, _Mapping]]] = ..., working_directory: _Optional[str] = ..., subsandbox_digests: _Optional[_Iterable[_Union[_remote_execution_pb2.Digest, _Mapping]]] = ...) -> None: ...
3039
VERSION_FIELD_NUMBER: _ClassVar[int]
3140
BUILD_SUCCESS_FIELD_NUMBER: _ClassVar[int]
3241
BUILD_ERROR_FIELD_NUMBER: _ClassVar[int]
@@ -44,6 +53,7 @@ class Artifact(_message.Message):
4453
HIGH_DIVERSITY_META_FIELD_NUMBER: _ClassVar[int]
4554
STRICT_KEY_FIELD_NUMBER: _ClassVar[int]
4655
BUILDROOT_FIELD_NUMBER: _ClassVar[int]
56+
BUILDSANDBOX_FIELD_NUMBER: _ClassVar[int]
4757
version: int
4858
build_success: bool
4959
build_error: str
@@ -61,4 +71,5 @@ class Artifact(_message.Message):
6171
high_diversity_meta: _remote_execution_pb2.Digest
6272
strict_key: str
6373
buildroot: _remote_execution_pb2.Digest
64-
def __init__(self, version: _Optional[int] = ..., build_success: bool = ..., build_error: _Optional[str] = ..., build_error_details: _Optional[str] = ..., strong_key: _Optional[str] = ..., weak_key: _Optional[str] = ..., was_workspaced: bool = ..., files: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., build_deps: _Optional[_Iterable[_Union[Artifact.Dependency, _Mapping]]] = ..., public_data: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., logs: _Optional[_Iterable[_Union[Artifact.LogFile, _Mapping]]] = ..., buildtree: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., sources: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., low_diversity_meta: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., high_diversity_meta: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., strict_key: _Optional[str] = ..., buildroot: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ...) -> None: ...
74+
buildsandbox: Artifact.SandboxState
75+
def __init__(self, version: _Optional[int] = ..., build_success: bool = ..., build_error: _Optional[str] = ..., build_error_details: _Optional[str] = ..., strong_key: _Optional[str] = ..., weak_key: _Optional[str] = ..., was_workspaced: bool = ..., files: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., build_deps: _Optional[_Iterable[_Union[Artifact.Dependency, _Mapping]]] = ..., public_data: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., logs: _Optional[_Iterable[_Union[Artifact.LogFile, _Mapping]]] = ..., buildtree: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., sources: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., low_diversity_meta: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., high_diversity_meta: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., strict_key: _Optional[str] = ..., buildroot: _Optional[_Union[_remote_execution_pb2.Digest, _Mapping]] = ..., buildsandbox: _Optional[_Union[Artifact.SandboxState, _Mapping]] = ...) -> None: ...

0 commit comments

Comments
 (0)