这是indexloc提供的服务,不要输入任何密码
Skip to content

Navigating to an endpoint with spaces in its operationID forces a redirect in Stoplight #721

@BasMichielsen

Description

@BasMichielsen

Somewhere between version v 2.23 and v 2.28 something changed regarding OperationIDs with spaces in them. I just upgraded from v 2.23 to v 2.28 and now my operations that have spaces in their operationIDs can no longer be viewed in Stoplight and force a web redirect to the root. However, when I rollback to v 2.23 it works again. Is this accidental, or should an OperationID not have a space in it? If the latter, I would have expected an error message explaining the issue. If the former, there is probably a bug.

name := "Get All Detections"
...
huma.Register(api, huma.Operation{
   OperationID: name, 
   Path: path, 
   Method: method,
   }, func(ctx context.Context, input *struct{}) (*DetectionsHolder, error) {
...
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    dependenciesPull requests that update a dependency file

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions