alecthomas / alecthomas/voluptuous
Inclusive should support default values
Aberta
- Linguagem predominante
- Python
- Estrelas
- 1.9k
- Forks
- 237
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Descrição
The `Inclusive` schema builder does not support default values even though it inherits from `Optional`, which does support them. It would be valuable if defaults were supported for situations such as this:
```
dimensions = Schema({
Inclusive("width", "dims", default=1024): Coerce(int),
Inclusive("height", "dims", default=576): Coerce(int),
}
```
In general, when using `Inclusive` to enforce "all or nothing", having default values for the "nothing" case would be very helpful.
Guia de contribuição
Nenhum guia de contribuição indexado para este repositório
Avaliação
Esta issue ainda não foi avaliada.