Skip to content

Commit

Permalink
ninjs 3.0 release candidate, including events, planning, live streams…
Browse files Browse the repository at this point in the history
… and camelCase properties (#157)

ninjs 3.0 release, including the following changes:
* events and news coverage support
* extensive date support including recurring events, expectedStartDate and expectedEndDate for events and planning items
* expectedStartDate and expectedEndDate support TruncatedDateTime which allows for year-only, year-month, year-month-day etc as well as fully specified date-time strings
* commissioning information
* additions to rendition support to handle live streaming events
* move of all property names to "camelCase" format which is best practice in the JSON world, particularly in GraphQL
* ninjs 3.0 unit tests and examples
* update to the ninjs User Guide

---------
Co-authored-by: Ian Young <ian@iansramblings.com>
Co-authored-by: Johan Lindgren <jl@tt.se>
Co-authored-by: Trond Huso <trond@trondhuso.no>
  • Loading branch information
bquinn authored Nov 26, 2024
1 parent 677efe1 commit 5a1e5cd
Show file tree
Hide file tree
Showing 129 changed files with 12,241 additions and 3,334 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@
venv
__pycache__
node_modules
package.json
package-lock.json

39 changes: 27 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,14 @@ The `examples` folder contains example files, including some supplied
by Business Wire. Examples show how NewsML 1.2 files convert to their
equivalents in ninjs.

Two versions of ninjs: ninjs 1.4 and ninjs 2.0
Three versions of ninjs: ninjs 1.5, ninjs 2.1 and ninjs 3.0
-------------------------

This repository specifies both the 1.4 and 2.0 versions of ninjs.
This repository specifies all versions of ninjs.

The 1.x series adds new features to the version of ninjs that started
with ninjs 1.0 back in 2013, in a way that is fully backwards
compatible. The latest release in this series is 1.4, which includes
new fields _contentcreated_, _expires_ and _rightsinfo_. The 1.4
version of ninjs was approved by the IPTC Standards Committee on May
18th, 2022.
compatible. The latest release in this series is 1.5.

The 2.x series fixes some issues that made the 1.x series tricky for
developers to work with. The main change is that we avoid the use of
Expand All @@ -50,15 +47,25 @@ October 20th, 2021.
An errata update was made in May 2022 to fix a problem with the way GeoJSON
properties were integrated into the "places" object.

The 3.x series is a major update to ninjs, which is not backwards compatible.

Version 3.0 offers three document types, the existing "news item" and new
document types for events and planning items. For improved readability and
to align with general best practice for variable naming and graphQL the
properties now use "camelCase".

The 3.0 version of ninjs was approved by the IPTC Standards Committee on
October 2nd, 2024.

Which version should I choose for my project?
-------------------------

If you are starting a green-field project, we recommend using ninjs 2.0.
If you are starting a green-field project, we recommend using ninjs 3.0.
This version should be easiest for developers to work with.

If you are already using a 1.x version of ninjs, we recommend at least
upgrading to version 1.4. This should be an easy change, because 1.4 is
backwards-compatible with versions 1.0, 1.1, 1.2 and 1.3.
upgrading to version 1.5. This should be an easy change, because 1.5 is
backwards-compatible with all previous versions of 1.x.

Protocol Buffers demo
---------------------
Expand All @@ -70,13 +77,15 @@ We also show how a code library can be automatically generated from
the protobufs schema and we include an example Python script showing
how a ninjs Protobufs document can be written and read via code.

Please note that this has not yet been updated for ninjs 3.0.

See [the protobufs README](/protobufs/README.md) for details.

Unit tests
----------

To run unit tests in the `validation/test_suite` folder against each
of the ninjs 1.0, 1.1, 1.2, 1.3, 1.4 and 2.0 schemas, run the following
of the ninjs 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 2.0, 2.1 and 3.0 schemas, run the following
tool in a command/terminal window:

pip install -r validation/python/requirements.txt
Expand All @@ -86,6 +95,11 @@ We automatically run unit tests on every commit using CircleCI. The
badge above the title on this page indicates the current status of the
unit tests.

Additionaly the same unit test suite can be run via Javascript with the following:

npm install
npm test

Dev schema
----------

Expand All @@ -102,5 +116,6 @@ ninjs Generator
---------------

In the `generator` folder is the source code to the ninjs generator, a
user-facing tool to generate sample ninjs files of either 1.4 or 2.0 version, which is hosted at
https://www.iptc.org/std/ninjs/generator/.
user-facing tool to generate sample ninjs files in either ninjs 1.5, 2.1 or 3.0.

The tool is hosted at https://www.iptc.org/std/ninjs/generator/
Loading

0 comments on commit 5a1e5cd

Please sign in to comment.