-
-
Couldn't load subscription status.
- Fork 115
Open
Labels
Description
Describe the bug
A few predicates from dry-logic is missing in the json_schema compiler
To Reproduce
require "dry-types"
require "dry-schema"
Dry::Schema.load_extensions(:json_schema)
module Types
include Dry.Types()
end
puts (Dry::Schema.Params do
required(:_).value(Types::Hash.schema(
size: Types::Array.constrained(size: 5),
format: Types::String.constrained(format: /[A-Z]{2}/),
bool: Types::Bool,
))
end).json_schemaExpected behavior
To not error and return the correct schema
My environment
- Affects my production application: yes, but i've just monkeypatched it for now
- Ruby version: 3.3.9
- OS: NixOS