question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Validator ignores format:date-time

See original GitHub issue

When validating against this JSON schema

{
    "type":"object",
    "$schema":"http://json-schema.org/draft-04/schema#",
        "date":{
            "type":"string",
            "format":"date-time"
        }
    }
}

sending any String as the date will do. I’ve read somewhere that support for format is optional, is this the case for this validator?

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
erosbcommented, Mar 15, 2016

@balazs-zsoldos now yes, please, I’ve just fixed it and re-released 1.2.0 on github @rcillo thanks for the fast feedback

1reaction
erosbcommented, Mar 13, 2016

I’ve just finished and merged “format” keyword support (and added docs to readme ), tagged as version 1.2.0 . @balazs-zsoldos please release version 1.2.0 on maven central. Thank you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to validate date with format "mm/dd/yyyy" in JavaScript?
This validates '2020-5-1' as true while the leading zero's are ignored. I made it work by first testing the pattern of the year...
Read more >
ADF - How to validate String is of valid DATE format?
My understanding is that you would want to validate if a given string is of valid date format and then continue the flow...
Read more >
Dataweave - Check String is date and ignore non dates
Hi all,. I have a set of data with a field with dates, the problem is sometimes that field comes with letters and...
Read more >
validate format datetime in laravel Code Example - Code Grepper
Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 7.3.0". Ignore platform version laravel · composer install ...
Read more >
date field validation does not work on SP - ServiceNow
... but on Service Portal, the validation are all being ignored. I already figured out the function "formatDate" which SP does not like....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found