surrealdb / surrealist

Surrealist is the ultimate way to visually manage your SurrealDB database
https://surrealist.app/
MIT License
1.04k stars 74 forks source link

Cannot create JWKS token #244

Closed akkie closed 2 months ago

akkie commented 2 months ago

Describe the bug It's not possible to create a JWKS token with Surrealist. With the old version it was possible, with the new version it shows an error.

To Reproduce Create a new query with the example from the documentation:

https://surrealdb.com/docs/surrealdb/surrealql/statements/define/token#json-web-key-set-jwks-since-120

DEFINE TOKEN token_name
  -- Use this token provider for database authorization
  ON DATABASE
  -- Specify the JWKS specification used to verify the token
  TYPE JWKS 
  -- Specify the URL where the JWKS object can be found
  VALUE "https://example.com/.well-known/jwks.json"
;

The UI shows an error: Failed to parse query at line 1 column 8 expected query to end

image

Expected behavior The query should be executed.

Environment:

Platform: Desktop
OS: Darwin
Architecture: aarch64
WebView: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko)
Version: 2.0.1
Flags: featureFlags: false, models_view: true, apidocs_view: true, themes: false, newsfeed: true

Additional information. The same issue occurs in the Rust SDK.