mirror of
https://github.com/nspcc-dev/neofs-s3-gw.git
synced 2026-03-01 04:29:15 +00:00
Use SDK error checkers instead of manual unwraps #268
Labels
No labels
I2
I2
I3
I4
S2
S3
S4
S4
U0
U1
U2
U2
U3
U4
U4
auth-mate
blocked
bug
config
dependencies
discussion
documentation
enhancement
epic
feature
go
good first issue
help wanted
performance
question
security
test
tree-service
tree-service
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
nspcc-dev/neofs-s3-gw#268
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @alexvanin on GitHub (Jun 30, 2022).
Originally assigned to: @alexvanin on GitHub.
After https://github.com/nspcc-dev/neofs-sdk-go/issues/278 we can use SDK error checkers because they are now work correctly with wrapper errors. Look for
unwrapmethods in the code.@cthulhu-rider commented on GitHub (Jul 4, 2022):
I've not found any place with unwrapping.
@alexvanin commented on GitHub (Jul 4, 2022):
Relevant for tree-service branch after rebase.
@alexvanin commented on GitHub (Jul 27, 2022):
The only place where unwrap is being used is here (v0.22.0):
nspcc-dev/neofs-s3-gw@5dd658302d/internal/neofs/neofs.go (L473-L488)I think it is appropriate to keep unwrapping, because gate wants a reason, so type casting is mandatory.
I don't have any good ideas how to organize error type casting on a SDK level.