Giter Site home page Giter Site logo

Comments (5)

iadgovuser1 avatar iadgovuser1 commented on July 3, 2024 1

@froi Thanks for the quick response. For now I've updated my code so it will validate against the current schema requirement (date only), but allowing both in the future would be great.

from code-gov-data.

DanielJDufour avatar DanielJDufour commented on July 3, 2024

@iadgovuser1 , great question. @froi or @RicardoAReyes , can you help clarify? Thanks!

from code-gov-data.

froi avatar froi commented on July 3, 2024

Hi @iadgovuser1, thanks for reaching out.

In schema version 1.0.1 the date fields were just strings without the format specified. The intent of version 2.0.0 was always to give it a format to improve data quality. I believe that the intent was to accept both formats as stated in the description. Thanks for catching this oversight!

We will be discussing what approach to take, although I think we will update the schema to permit both formats.

Ex.

"date": {
    "type": "object",
    "description": "A date object describing the release.",
    "properties": {
        "created": {
            "anyOf": [{
                    "type": "string",
                    "format": "date"
                },
                {
                    "type": "string",
                    "format": "date-time"
                }
            ],
            "description": "The date the release was created, in YYYY-MM-DD or ISO 8601 format."
        },
        "lastModified": {
            "anyOf": [{
                    "type": "string",
                    "format": "date"
                },
                {
                    "type": "string",
                    "format": "date-time"
                }
            ],
            "description": "The date the release was modified, in YYYY-MM-DD or ISO 8601 format."
        },
        "metadataLastUpdated": {
            "anyOf": [{
                    "type": "string",
                    "format": "date"
                },
                {
                    "type": "string",
                    "format": "date-time"
                }
            ],
            "description": "The date the metadata of the release was last updated, in YYYY-MM-DD or ISO 8601 format."
        }
    },
    "additionalProperties": false
}

We will get back to you.

from code-gov-data.

iadgovuser1 avatar iadgovuser1 commented on July 3, 2024

I forgot to mention the project I'm using the schema with: https://github.com/nsacyber/CodeGov This is what I use to generate https://nsacyber.github.io/code.json

Right now the schema is embedded in the code, but I might switch to dynamically retrieving the schema from https://github.com/GSA/code-gov-data/blob/master/schemas/schema-2.0.0.json

from code-gov-data.

DanielJDufour avatar DanielJDufour commented on July 3, 2024

Hi, @iadgovuser1 . I'm moving this to code-gov-data where we are now hosting the schema discussions. Thanks!

from code-gov-data.

Related Issues (9)

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.