Skip to content

Commit 97219e4

Browse files
committed
fix ulid regex
1 parent a4ee522 commit 97219e4

File tree

8 files changed

+8
-8
lines changed

8 files changed

+8
-8
lines changed

bases/renku_data_services/data_api/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626

2727
def register_all_handlers(app: Sanic, config: Config) -> Sanic:
2828
"""Register all handlers on the application."""
29-
app.router.register_pattern("ulid", ULID.from_str, r"^[0-9A-HJKMNP-TV-Z]{26}$")
29+
app.router.register_pattern("ulid", ULID.from_str, r"^[0-7][0-9A-HJKMNP-TV-Z]{25}$")
3030
app.router.register_pattern("renku_slug", str, r"^[a-zA-Z0-9][a-zA-Z0-9\-_.]*$")
3131

3232
url_prefix = "/api/data"

components/renku_data_services/connected_services/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ components:
309309
type: string
310310
minLength: 26
311311
maxLength: 26
312-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
312+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
313313
ProviderId:
314314
description: ID of a OAuth2 provider, e.g. "gitlab.com".
315315
type: string

components/renku_data_services/namespace/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ components:
365365
type: string
366366
minLength: 26
367367
maxLength: 26
368-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
368+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
369369
NamespaceName:
370370
description: Renku group or namespace name
371371
type: string

components/renku_data_services/project/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ components:
360360
type: string
361361
minLength: 26
362362
maxLength: 26
363-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
363+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
364364
ProjectName:
365365
description: Renku project name
366366
type: string

components/renku_data_services/repositories/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ components:
103103
type: string
104104
minLength: 26
105105
maxLength: 26
106-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
106+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
107107
ProviderId:
108108
description: ID of a OAuth2 provider, e.g. "gitlab.com".
109109
type: string

components/renku_data_services/secrets/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ components:
8989
type: string
9090
minLength: 26
9191
maxLength: 26
92-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
92+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
9393
ErrorResponse:
9494
type: object
9595
properties:

components/renku_data_services/session/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ components:
430430
type: string
431431
minLength: 26
432432
maxLength: 26
433-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
433+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
434434
SessionName:
435435
description: Renku session name
436436
type: string

components/renku_data_services/users/api.spec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ components:
430430
type: string
431431
minLength: 26
432432
maxLength: 26
433-
pattern: "^[A-Z0-9]{26}$" # This is case-insensitive
433+
pattern: "^[0-7][0-9A-HJKMNP-TV-Z]{25}$" # This is case-insensitive
434434
ModificationDate:
435435
description: The date and time the secret was created or modified (this is always in UTC)
436436
type: string

0 commit comments

Comments
 (0)