2015-03-26から1日間の記事一覧
FormとSchemaの違いvalidation編 FormとSchemaの違いをプレゼンテーション側からみた話を前に書来ましたが validation側から見た場合にも両者は違うようです。 エラー時にSchemaは元の入力値を捨てても良いが、Formは元の入力値にアクセスできることが重要 S…
http://marshmallow.readthedocs.org/en/latest/api_reference.html#marshmallow.Schema.dump update_fieldsという引数がdefaultでTrueになっていて。これは値のtypeを見て、変換する関数を変えている。具体的なmappingはmarshmallow.schemaにかかれていて以…