Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Add support for receiving roStoryX, roItemY messages (SOFIE-2858) #87

Merged
merged 1 commit into from
Dec 27, 2023

Conversation

nytamin
Copy link
Contributor

@nytamin nytamin commented Dec 21, 2023

About the Contributor

This PR is posted on behald of the NRK.

Type of Contribution

This can be considered a bug fix. It adds support for a few missing MOS messages, that should have been there from the start.
This doesn't affect the consumer-side API of the library.

Current Behavior

As reported in #86 and #57, if, for example, a <roStoryReplace> message is received, the library will emit the error "Unsupported function".

While these types of messages are considered deprecated_ they should still be supported.
Quote from the mos protocol documentation:

At present, applications and devices claiming support for MOS v2.8.5 Profile 2 must support all of these messages for backwards compatibility plus the functionally equivalent <roElementAction> which will be forward compatible.

New Behavior

Library now supports the following messages:

  • roStoryAppend
  • roStoryInsert
  • roStoryReplace
  • roStoryMove
  • roStorySwap
  • roStoryDelete
  • roStoryMoveMultiple
  • roItemInsert
  • roItemReplace
  • roItemDelete
  • roItemMoveMultiple

All these messages have equivalent functionality in the roElementAction which is already supported, so a call to one of these will result in calls to the already existing callbacks (so no code changes are required in the consumer code).

Testing Instructions

This can be tested using

npm install @mos-connection/connector@3.0.7-nightly-fix-add-roStoryX-roItemX-support-20231221-070136-a4c110e.0

Other Information

Status

  • PR is ready to be reviewed.
  • The functionality has been tested by the author.
  • Relevant unit tests has been added / updated.
  • Relevant documentation (code comments, system documentation) has been added / updated.

These all have functionally equivalent roElementAction messages, so the consumer API is unchanged.

Addded messages: roStoryAppend, roStoryInsert, roStoryReplace, roStoryMove, roStorySwap, roStoryDelete, roStoryMoveMultiple, roItemInsert, roItemReplace, roItemDelete, roItemMoveMultiple.
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (f05870a) 77.58% compared to head (a4c110e) 77.84%.
Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #87      +/-   ##
==========================================
+ Coverage   77.58%   77.84%   +0.26%     
==========================================
  Files          63       63              
  Lines        3395     3422      +27     
  Branches      768      778      +10     
==========================================
+ Hits         2634     2664      +30     
+ Misses        679      676       -3     
  Partials       82       82              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@nytamin nytamin requested a review from a team December 21, 2023 08:56
@nytamin nytamin changed the title fix: Add support for receiving roStoryX, roStoryY messages (SOFIE-2858) fix: Add support for receiving roStoryX, roItemY messages (SOFIE-2858) Dec 26, 2023
@nytamin nytamin merged commit 1a80036 into master Dec 27, 2023
21 checks passed
@nytamin nytamin deleted the fix/add-roStoryX-roItemX-support branch December 27, 2023 14:01
@nytamin
Copy link
Contributor Author

nytamin commented Dec 27, 2023

These changes have now been published in version v3.0.7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug Report: roStoryReplace Unsupported function Support for deprecated Profile 2 MOS calls
2 participants