popolo-project / popolo-spec

International legislative data specifications
http://www.popoloproject.com/
99 stars 18 forks source link

other_name#name is required field? #86

Closed tmtmtmtm closed 9 years ago

tmtmtmtm commented 9 years ago

It seems odd that 'name' isn't a required field on the primary name, but is on an Other Name.

i.e. I would have thought that I should be able to have a Person:

    {
      "given_name": "Nicholas",
      "family_name": "Clegg",
      "other_names": [
        {
          "given_name": "Nick"
        }
      ]
    }

but instead I need to have:

    {
      "given_name": "Nicholas",
      "family_name": "Clegg",
      "other_names": [
        {
          "name": "Nick Clegg"
        }
      ]
    }
jpmckinney commented 9 years ago

name was removed from Person, because a contributor made a case for why they would only ever use the other_names array (i.e. in their context, names should always have dates). I have no strong feelings about keeping name required on OtherName. Shall I remove that constraint?

tmtmtmtm commented 9 years ago

I'm open to persuasion if someone can argue why it should be kept, but I think it makes sense to be able to 'move' a valid name object into the other_names array, without having to also manufacture an extra name field for it, if one didn't previously exist.

jpmckinney commented 9 years ago

Closed by https://github.com/popolo-project/popolo-spec/commit/9aec3f3fa4a40392cbe01adcffd5d2c70681181a Seems to have been accidentally left out of the 2014-02-10 change:

name and label are no longer required properties in the JSON Schema.