mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-09-20 15:09:02 +03:00
server: fix namespace visibility during introspection
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4971 GitOrigin-RevId: 0ed090b61da65849466607c29480f031f241e929
This commit is contained in:
parent
4b4a11dd07
commit
2498176052
@ -58,7 +58,7 @@
|
||||
|
||||
### Bug fixes and improvements
|
||||
|
||||
|
||||
- server: fix namespace visibility during introspection (fix #8434)
|
||||
- server: Create missing SQL triggers, if any, while reloading metadata and startup.
|
||||
- server: fix name transformation bug in `graphql-default` naming convention (fixes #8640 partially)
|
||||
- server: changes to the Rest Endpoints OpenAPI specification:
|
||||
|
@ -88,6 +88,7 @@ customizeNamespace ::
|
||||
P.MkTypename ->
|
||||
[FieldParser n a] ->
|
||||
[FieldParser n (NamespacedField a)]
|
||||
customizeNamespace (Just _) _ _ [] = [] -- The nampespace doesn't contain any Field parsers, so returning empty list
|
||||
customizeNamespace (Just namespace) fromParsedSelection mkNamespaceTypename fieldParsers =
|
||||
-- Source or remote schema has a namespace field so wrap the parsers
|
||||
-- in a new namespace field parser.
|
||||
|
@ -161,6 +161,52 @@
|
||||
}
|
||||
}
|
||||
|
||||
- description: Create user role
|
||||
url: /v1/metadata
|
||||
status: 200
|
||||
query:
|
||||
type: pg_create_select_permission
|
||||
args:
|
||||
table: author_local
|
||||
role: user
|
||||
permission:
|
||||
columns: '*'
|
||||
filter: {}
|
||||
source: pg1
|
||||
response:
|
||||
message: success
|
||||
|
||||
- description: Check namespace visibility
|
||||
url: /v1/graphql
|
||||
headers:
|
||||
X-Hasura-Role: user
|
||||
status: 200
|
||||
response:
|
||||
errors:
|
||||
- extensions:
|
||||
code: validation-failed
|
||||
path: $.selectionSet.s2
|
||||
message: "field \"s2\" not found in type: 'query_root'"
|
||||
|
||||
query:
|
||||
query: |
|
||||
query MyQuery {
|
||||
s2 {
|
||||
__typename
|
||||
}
|
||||
}
|
||||
|
||||
- description: Drop user role
|
||||
url: /v1/metadata
|
||||
status: 200
|
||||
query:
|
||||
type: pg_drop_select_permission
|
||||
args:
|
||||
role: user
|
||||
source: pg1
|
||||
table: author_local
|
||||
response:
|
||||
message: success
|
||||
|
||||
- description: untrack table 1
|
||||
url: /v1/metadata
|
||||
|
Loading…
Reference in New Issue
Block a user