Skip to content
This repository has been archived by the owner on Aug 13, 2023. It is now read-only.

Mega packages bumps #4420

Merged
merged 19 commits into from
Mar 10, 2021
Merged

Mega packages bumps #4420

merged 19 commits into from
Mar 10, 2021

Conversation

jroebu14
Copy link
Contributor

@jroebu14 jroebu14 commented Mar 4, 2021

Overall change:
Upgrades a lot of packages.

Updates all minor and patch dependencies and the following major dependencies:

  • @testing-library/react-hooks
  • eslint-config-prettier
  • mkdirp
  • object-hash

Consists of several Renovate PRs:

Also adds a new dependency many-pkg that runs checks on postinstall to flag problems with our package.json files. Running this check on postinstall was inspired by Chakra UI's approach.

Running many-pkg highlighted some problems such as dependency mismatches across packages and peerDeps not being installed in devDeps. These issues were fixed in this PR.

Code changes:

Adds new root dependency many-pkg and 2 new scripts:

  • check:pkgs - run this to validate our package.json files using these checks. Runs on postinstall
  • fix:pkgs - run this to auto-fix problems highlighted by running check:pkgs

mkdirp v1 breaking changes

Used in moment-timezone-include package

What changed?

  • Promises instead of callbacks
  • Dropped support for older versions of node

More details - https://www.npmjs.com/package/mkdirp/v/1.0.0#use-this-module-mkdirp-1x-if

Changes needed
None. We didn't use callbacks - are using mkdirp.sync and we use a supported version of Node.


object-hash v2 breaking changes

Used in moment-timezone-include package

What changed?

  • Only Node.js versions >= 6.0.0 are now supported

More details - https://github.com/puleos/object-hash#v200

Changes needed
None.


eslint-config-prettier v8 breaking changes

Used in root package

What changed?

  • Changed: [arrow-body-style] and [prefer-arrow-callback] are no longer turned off by default

More details

Changes needed
None.


@testing-library/react-hooks v5 breaking changes

Used in root package

What changed?

  • Interval and timeout time changes
  • Deprecated function suppressErrors removed

More details

Changes needed
None.

  • I have assigned myself to this PR and the corresponding issues
  • Automated jest tests added (for new features) or updated (for existing features)
  • This PR requires manual testing

@github-actions
Copy link

github-actions bot commented Mar 4, 2021

Checkout your storybook preview here http://psammead-preview.tools.bbc.co.uk/4420

Jonathan Roebuck added 2 commits March 4, 2021 14:49
Bump package versions for psammead, psammead-amp-geo, psammead-brand, psammead-bulleted-list, psammead-bulletin, psammead-byline, psammead-caption, psammead-consent-banner, psammead-content-anchor, psammead-copyright, psammead-embed-error, psammead-episode-list, psammead-figure, psammead-grid, psammead-heading-index, psammead-headings, psammead-image-placeholder, psammead-image, psammead-inline-link, psammead-live-label, psammead-media-indicator, psammead-media-player, psammead-most-read, psammead-navigation, psammead-oembed, psammead-paragraph, psammead-play-button, psammead-podcast-promo, psammead-radio-schedule, psammead-script-link, psammead-section-label, psammead-sitewide-links, psammead-social-embed, psammead-story-promo-list, psammead-story-promo, psammead-timestamp, psammead-topic-tags, psammead-useful-links, psammead-visually-hidden-text, psammead-timestamp-container, moment-timezone-include, psammead-assets, psammead-calendars, psammead-detokeniser, psammead-locales, psammead-rich-text-transforms, psammead-storybook-helpers, psammead-styles, psammead-test-helpers, web-vitals,
Updates changelogs for psammead, psammead-amp-geo, psammead-brand, psammead-bulleted-list, psammead-bulletin, psammead-byline, psammead-caption, psammead-consent-banner, psammead-content-anchor, psammead-copyright, psammead-embed-error, psammead-episode-list, psammead-figure, psammead-grid, psammead-heading-index, psammead-headings, psammead-image-placeholder, psammead-image, psammead-inline-link, psammead-live-label, psammead-media-indicator, psammead-media-player, psammead-most-read, psammead-navigation, psammead-oembed, psammead-paragraph, psammead-play-button, psammead-podcast-promo, psammead-radio-schedule, psammead-script-link, psammead-section-label, psammead-sitewide-links, psammead-social-embed, psammead-story-promo-list, psammead-story-promo, psammead-timestamp, psammead-topic-tags, psammead-useful-links, psammead-visually-hidden-text, psammead-timestamp-container, moment-timezone-include, psammead-assets, psammead-calendars, psammead-detokeniser, psammead-locales, psammead-rich-text-transforms, psammead-storybook-helpers, psammead-styles, psammead-test-helpers, web-vitals
@jroebu14 jroebu14 self-assigned this Mar 4, 2021
@jroebu14 jroebu14 added the cross-team For visibility for both World Service teams (Engage & Media) label Mar 4, 2021
Copy link
Contributor

@andrewscfc andrewscfc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one point on peer dependnecies, otherwise I think this is good to merge looks like some dependencies for psammead-timestamp-container need pinning again looking at the failing tests

"@bbc/psammead-styles": "^7.2.2"
"@bbc/psammead-styles": "^7.2.2",
"@emotion/styled": "^11.0.0",
"react": "^17.0.1"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how do these dev dependencies work with the peer dependencies here? I guess the peer dependencies declare that you can integrate and use this package with a project (Simorgh in our case) that uses Emotion styled > 11 and react > 16.9 ? Should we change the react one to be react 17? I imagine this will be needed across all packages

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think if we do then we introduce a backwards-incompatible breaking change because consumers who haven't upgraded to React v17 won't be able to use new versions of Psammead components.

Copy link
Contributor

@chris-hinds chris-hinds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for this Jonathan

Copy link
Contributor

@HarveyPeachey HarveyPeachey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go ahead and Bump, ᴮᵘᵐᵖ!

@jroebu14 jroebu14 merged commit 2941bd5 into latest Mar 10, 2021
@jroebu14 jroebu14 deleted the mega-packages-bumps branch March 10, 2021 12:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cross-team For visibility for both World Service teams (Engage & Media)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants