Giter Club home page Giter Club logo

Comments (10)

Julian avatar Julian commented on May 25, 2024

Not having format checkers present when the required dependencies aren't satisfied doesn't bother me that much. If anything we could improve the documentation if you think there's something there that could be clearer. We could perhaps more prominently discuss the attribute on format checkers that contains all the known checkers, which is public and could be used to inspect the available checkers.

Putting all the format checkers in the class though is fine with me if we have a reasonable way of doing that.

Since this is mostly for our own sanity this is pretty low priority I'm guessing.

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

Since this is mostly for our own sanity this is pretty low priority I'm guessing.

My goal was so that an user can instantiate a FormatChecker with the subset of properties they desire. Right now you can't do FormatChecker(formats=('time', 'email')) because 'time' checker is just in the draft3_format_checker instance, not on the class.
I'll have another go at doing this.

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

What do you think about something like this? gazpachoking@b0a694f

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

Or maybe _checks_drafts should be usable like @_checks_drafts("email", raises=blah) for checkers on both drafts, and @_checks_drafts(draft3="ip-address", draft4="ipv4", raises=blah) for checkers on draft 3 only or when the name differs.

from jsonschema.

Julian avatar Julian commented on May 25, 2024

Um, I'm OK with that.

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

You sound hesitant...

from jsonschema.

Julian avatar Julian commented on May 25, 2024

:) nah. We should document the canonical names for the format checkers.
Other than that I'm not hesitant, just not particularly excited :p.
On Apr 11, 2013 9:08 AM, "Chase Sterling" [email protected] wrote:

You sound hesitant...


Reply to this email directly or view it on GitHubhttps://github.com//issues/78#issuecomment-16233127
.

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

The way I have it now puts both names onto the class, should it only add the canonical name? That might complicated things a bit.

BTW, do you prefer _checks_drafts like I have it, or the keyword idea?

from jsonschema.

Julian avatar Julian commented on May 25, 2024

Slight preference for the keyword way, but it's private so I don't really
care either way too strongly.

And yeah I saw both names are going to be on the class, but we should have
a table somewhere in the documentation where we mention format validation
and that table should list a single name for simplicity I think.
On Apr 11, 2013 9:16 AM, "Chase Sterling" [email protected] wrote:

The way I have it now puts both names onto the class, should it only add
the canonical name? That might complicated things a bit.

BTW, do you prefer _checks_drafts like I have it, or the keyword idea?


Reply to this email directly or view it on GitHubhttps://github.com//issues/78#issuecomment-16233571
.

from jsonschema.

gazpachoking avatar gazpachoking commented on May 25, 2024

Sounds good.

from jsonschema.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.