metosin/malli

m/-tuple-transformer is broken in many ways

Open

#578 创建于 2021年11月21日

在 GitHub 查看
 (1 评论) (0 反应) (0 负责人)Clojure (237 fork)batch import
bughelp wanted

仓库指标

Star
 (1,724 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

;; ok
(m/decode
  [:tuple string? string?]
  []
  (mt/string-transformer))
; => []

;; fail
(m/decode
  [:tuple keyword? string?]
  []
  (mt/string-transformer))
; => [nil]

;; megafail
(m/decode
  [:tuple string? keyword?]
  []
  (mt/string-transformer))
; =throws=> Execution error (IndexOutOfBoundsException) at malli.core/-update (core.cljc:194).

贡献者指南