google / google/openhtf

Consider replacing our validators with voluptuous

Open
#415 5 comments 0 reactions 0 assignees View on GitHub
discussion
Dominant language
Python
Stars
722
Forks
237
Avg merge
11h 31m
Merged PRs (30d)
4

Description

https://github.com/alecthomas/voluptuous

Despite the name, it's a data validation library that does everything we need, and more. Its range even lets you specify if the ends should be included as valid or not (fixes another issue if I remember correctly).

As of February, many of the validators are classes just like ours, so our use-cases are 100% covered. What do you think? Worth dropping util/data.py for it?

Mapping:
Range -> Range
MatchesRegex -> Match
Equals -> Match or Range

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.