-
Notifications
You must be signed in to change notification settings - Fork 25
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks o.k., pending the parenthesis/comma fixes.
The comment about info
is a bit spares; in the long run we should some specifications there (e.g. "do not put data which may facilitate re-identification of individuals here if used outside of controlled environment" and such).
The original requirement was a field for adding simple custom information, not complex structures. But if the community considers it should accept any strucutre, then we should go with this solution. |
@sdelatorrep See my comment on #168. Wouldn't break the schema if list of objects, or would it? |
I think it wouldn't. An object in JSON can be whatever you want (e.g. a list of key-value pairs). |
I think that this definitely should be fixed. The current solution is:
and the proposed solution is:
The proposed solution is much simpler and easier to parse. |
@juhtornr I'm not against dictionary/hash instead of list (i.e. simply define as "object), if the values then can be of any type.
|
To add to this, here is how simple it would be in the specification:
Which results in the awkward form we want to get rid of for practical and aesthetic reasons. It could be as simple as:
^ See that we can give the example without enforcing the format Looks like the following in the preview:
|
@teemukataja Sure; it just breaks the current That being said, we actually had this format already in our test implementation (somewhat erroneously, but didn't fix due to the direction this is moving ...).
|
@mbaudis I agree that from specification point of view this breaks the backwards compatibility. However we took a look how this is currently done in Beacon implementations and the conclusion is that:
So the implementations are actually pretty much using the proposed model and therefore I would suggest that we simply "fix" the specification. Can you @mbaudis raise this to the strategic group? |
@juhtornr Sounds convincing to me. I think we should just run this here, w/ approval from @jrambla, @garysaunders, @mcupak (and the Finnish team, which is a given...). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving, w/ requirement by others (see thread).
Sorry gentlemen, is the proposed solution allowing for any payload in the "info"? or just key:value?
Written from a mobile device, disregard brevity and typos, please.
Escrit des d'un mòbil, disculpeu la brevetat i les errades.
Escrito desde un móvil, disculpad la brevedad y las erratas.
…________________________________
From: garysaunders <[email protected]>
Sent: Friday, November 30, 2018 2:40:32 PM
To: ga4gh-beacon/specification
Cc: jrambla; Mention
Subject: Re: [ga4gh-beacon/specification] Fix info key (#226)
@garysaunders approved this pull request.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#226 (review)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AHsiOnX36Kvm-NDm4sRVk11l4xA7ewdJks5u0TVQgaJpZM4YGUQu>.
|
My take:
So this is mostly usage definitions, not technical protocol ("here is a sharp knife, but ..."). |
73cc968
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this change overall, and I think ideally, despite the troubles with parsing, I'd support going as far as extending this to cover arbitrary free form objects.
A few questions about this particular PR:
- This doesn't use
additionalProperties: true
- is that by design, or is it the default value? It's probably clearer to state it explicitly. - I'd suggest using different examples since e.g. license does not make sense in that context.
- Can you rebase please?
I also second the concerns about backward compatibility, since this does break it. If we need to bump to 2.0, so be it, but I'd delay this to squeeze a few more things into the major release in that case.
@mcupak related to this:
in OpenApi specs https://swagger.io/specification/#schemaObject it is stated:
|
Hi guys! I've got feedback from @jrambla and he approves this. |
337a7f3
to
8f2d3ef
Compare
Re-based and updated as per suggestions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @teemukataja! I asked for some changes. Thanks!
Co-Authored-By: teemukataja <[email protected]>
Fixes #168
This was attempted at #197 but was closed
This change introduces a solution to fix the issue with the
info
key andKeyValuePair
, by conforming to JSON standards, in plain terms:info
's value would be of type object.An example of how this might look in practice is provided by @blankdots at #223 (comment)
This PR builds on top of #225 as it has the change made to
.travis.yml
.