Skip to content

EvaluatorOptions.withResourceReader/withModuleReader adds incorrect allowed module/resource when reader scheme contains regex control characters #80

@HT154

Description

@HT154

Given a ResourceReader with scheme "foo+bar.baz", calling EvaluatorOptions.preconfigured().withResourceReader(reader) yields options with allowedResources containing "foo+bar.baz:", which does not match the literal string "foo+bar.baz" when reading a resource in evaluated Pkl code, resulting in a "Refusing to read resource " error.

The scheme should be automatically escaped by these convenience methods.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions