[Notes] [Git][BuildStream/buildstream][Qinusty/481] 2 commits: message.py: MessagesType.SKIPPED added



Title: GitLab

Qinusty pushed to branch Qinusty/481 at BuildStream / buildstream

Commits:

3 changed files:

Changes:

  • buildstream/_artifactcache/cascache.py
    ... ... @@ -32,6 +32,7 @@ from .._protos.google.bytestream import bytestream_pb2, bytestream_pb2_grpc
    32 32
     from .._protos.build.bazel.remote.execution.v2 import remote_execution_pb2, remote_execution_pb2_grpc
    
    33 33
     from .._protos.buildstream.v2 import buildstream_pb2, buildstream_pb2_grpc
    
    34 34
     
    
    35
    +from .._message import MessageType, Message
    
    35 36
     from .. import _signals, utils
    
    36 37
     from .._exceptions import ArtifactError
    
    37 38
     
    
    ... ... @@ -280,8 +281,12 @@ class CASCache(ArtifactCache):
    280 281
     
    
    281 282
                             if response.digest.hash == tree.hash and response.digest.size_bytes == tree.size_bytes:
    
    282 283
                                 # ref is already on the server with the same tree
    
    283
    -                            element.info("Skipping {}, remote ({}) already has artifact cached".format(
    
    284
    -                                element._get_brief_display_key(), remote.spec.url))
    
    284
    +                            self.context.message(Message(
    
    285
    +                                None,
    
    286
    +                                MessageType.SKIPPED,
    
    287
    +                                "Remote ({}) already has {} cached".format(
    
    288
    +                                    remote.spec.url, element._get_brief_display_key())
    
    289
    +                            ))
    
    285 290
                                 continue
    
    286 291
     
    
    287 292
                         except grpc.RpcError as e:
    

  • buildstream/_frontend/widget.py
    ... ... @@ -160,6 +160,7 @@ class TypeName(Widget):
    160 160
             MessageType.START: "blue",
    
    161 161
             MessageType.SUCCESS: "green",
    
    162 162
             MessageType.FAIL: "red",
    
    163
    +        MessageType.SKIPPED: "yellow",
    
    163 164
             MessageType.ERROR: "red",
    
    164 165
             MessageType.BUG: "red",
    
    165 166
         }
    

  • buildstream/_message.py
    ... ... @@ -36,6 +36,7 @@ class MessageType():
    36 36
         START = "start"        # Status start message
    
    37 37
         SUCCESS = "success"    # Successful status complete message
    
    38 38
         FAIL = "failure"       # Failing status complete message
    
    39
    +    SKIPPED = "skipped"
    
    39 40
     
    
    40 41
     
    
    41 42
     # Messages which should be reported regardless of whether
    



  • [Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]