Shahzad Lone
Shahzad Lone
Admin Operation Access Control for operations that are only for admins. - Turn on / off ACP Don't forget to: - Put server dump command under AAC (https://github.com/sourcenetwork/defradb/pull/2633#discussion_r1608797380) - Maybe...
## Relevant issue(s) Resolves #3104 ## Description - Bump linter - Resolve deprecated stuff - Resolve new linter warning improvements
Bump golangci-lint linter to v1.61 and fix deprecated stuff and linter errors Also noticed the old linter panics upon running locally for me. New version works fine.
Suggestion from @nasdf: https://github.com/sourcenetwork/defradb/pull/3099#discussion_r1787947741 Change: ``` go db, ok := req.Context().Value(dbContextKey).(client.DB) if !ok { responseJSON(rw, http.StatusBadRequest, errorResponse{NewErrFailedToGetContext("db")}) return } ``` To return error `500` so roughly this: ```go db, ok...
We can improve the following function in `test/integration/utils.go`: ```go func getNodes(nodeID immutable.Option[int], nodes []clients.Client) []clients.Client { if !nodeID.HasValue() { return nodes } return []clients.Client{nodes[nodeID.Value()]} } ``` To return a list...
## Clean up test utils ### Make assert helpers To avoid code duplication that was introduced in #3608 ### Remove confusing utility functions - Remove `getNodes` and `getNodeCollections` to avoid...
__**Describe the problem**__ Our testing framework seems to be not asserting the other result values once an error is encountered and assertion for `that ExpectedError` passes. __**To Reproduce**__ Both the...
Unstable policyIDs in next few sourcehub version bumps so rework `policyIDs` in tests to be stored in state and not be explicitly required. It's not as straight forward as `DocIndex`...
The backup import and export tests have a copy pasted comment line: `// If a value is not provided the indexes will be retrieved from the first nodes.` Which is...
An actor granted a write permission still can't write unless also given read permission Example Policy where reader can strictly only read and writer can strictly only write: ```yaml name:...