Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
buildstream
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
6
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
BuildStream
buildstream
Commits
1c05a092
Commit
1c05a092
authored
6 years ago
by
Valentin David
Committed by
Jürg Billeter
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix type of error codes in CAS server
Fixes
#882
.
parent
2fcb4491
No related branches found
No related tags found
1 merge request
!1099
Fix type of error codes in CAS server
Pipeline
#45211054
passed
6 years ago
Stage: test
Stage: post
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
buildstream/_cas/casserver.py
+3
-3
3 additions, 3 deletions
buildstream/_cas/casserver.py
with
3 additions
and
3 deletions
buildstream/_cas/casserver.py
+
3
−
3
View file @
1c05a092
...
...
@@ -324,7 +324,7 @@ class _ContentAddressableStorageServicer(remote_execution_pb2_grpc.ContentAddres
blob_response
.
digest
.
size_bytes
=
digest
.
size_bytes
if
len
(
blob_request
.
data
)
!=
digest
.
size_bytes
:
blob_response
.
status
.
code
=
grpc
.
StatusCode
.
FAILED_PRECONDITION
blob_response
.
status
.
code
=
code_pb2
.
FAILED_PRECONDITION
continue
try
:
...
...
@@ -335,10 +335,10 @@ class _ContentAddressableStorageServicer(remote_execution_pb2_grpc.ContentAddres
out
.
flush
()
server_digest
=
self
.
cas
.
add_object
(
path
=
out
.
name
)
if
server_digest
.
hash
!=
digest
.
hash
:
blob_response
.
status
.
code
=
grpc
.
StatusCode
.
FAILED_PRECONDITION
blob_response
.
status
.
code
=
code_pb2
.
FAILED_PRECONDITION
except
ArtifactTooLargeException
:
blob_response
.
status
.
code
=
grpc
.
StatusCode
.
RESOURCE_EXHAUSTED
blob_response
.
status
.
code
=
code_pb2
.
RESOURCE_EXHAUSTED
return
response
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment