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

chore(releases): improve bump oss script to allow less human errors (72 edition) #38888

Merged
merged 1 commit into from
Aug 18, 2023

Conversation

kelset
Copy link
Collaborator

@kelset kelset commented Aug 9, 2023

Summary:

One of the limitations of the existing flow for the release crew is that they need to manually remember to publish all the other packages in the monorepo ahead of a new patch release - this PR modifies the logic for the bump-oss-version script (and makes it available via yarn) so that it will not run if:

  • there are git changes lying around
  • if some of the packages need a new release

it required a bit of refactoring to extract some portions of the logic from the bump-all-package-versions script, but I think the end result is pretty decent.

This PR is the follow up from the one in main #38666 (plus #38887) to align the logic and new command convention.

It's not urgent, can be merged after patch release.

Changelog:

[INTERNAL] [CHANGED] - improve bump oss script to allow less human errors

Test Plan:

  • checkout this branch
  • comment L54 of trigger-react-native-release.js (to remove the check on the branch name)
  • run yarn bump-all-updated-packages, verify that it works and that it detects that some packages have unreleased code
  • run yarn trigger-react-native-release -t asd -v asd (the "fake" parameters are needed to pass the yargs check), verify that it will throw an error because it finds a package that has unreleased code

@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Contributor A React Native contributor. p: Microsoft Partner: Microsoft Partner labels Aug 9, 2023
@github-actions
Copy link

github-actions bot commented Aug 9, 2023

Warnings
⚠️ 🔒 package.json - Changes were made to package.json. This will require a manual import by a Facebook employee.

Generated by 🚫 dangerJS against e1c0b10

Copy link
Contributor

@fortmarek fortmarek left a comment

Choose a reason for hiding this comment

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

Looks good!

There are some unrelated changes due to force push in the 0.72-stable. We can still cherry-pick the commit itself, though.

@kelset
Copy link
Collaborator Author

kelset commented Aug 11, 2023

There seem to be changes unrelated to the script (FabricUIManger.java, etc.). Can we revert those?

yeah good catch - looks like @lunaleaps did some force pushing on the 72 branch that might have messed things up. Let me see if I can clean it up easily

Summary:
This added React-ImageManager to the use_frameworks! - a lot of rpm modules podspec need this.

bypass-github-export-checks

[iOS] [FIXED] - Add React-ImageManager path to work with use_frameworks!

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: #38247

Test Plan: Should not be breaking - it will add to the header_search_paths React-ImageManager

Reviewed By: dmytrorykun

Differential Revision: D47593749

Pulled By: cipolleschi

fbshipit-source-id: a66e90707e5fa73573deab1f04e8d8693869a90c

chore(releases): improve bump oss script to allow less human errors (#38666)

Summary:
One of the limitations of the existing flow for the release crew is that they need to manually remember to publish all the other packages in the monorepo ahead of a new patch release - this PR modifies the logic for the bump-oss-version script (and makes it available via yarn) so that it will not run if:
* there are git changes lying around
* if some of the packages need a new release

it required a bit of refactoring to extract some portions of the logic from the bump-all-package-versions script, but I think the end result is pretty decent.

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests
-->

[INTERNAL] [CHANGED] - improve bump oss script to allow less human errors

Pull Request resolved: #38666

Test Plan:
* checkout this branch
* comment L54 of bump-oss-version.js (to remove the check on the branch name)
* run `yarn bump-all-updated-packages`, verify that it works and that it detects that some packages have unreleased code
* run `yarn bump-oss-version -t asd -v asd` (the "fake" parameters are needed to pass the yargs check), verify that it will throw an error because it finds a package that has unreleased code

Reviewed By: mdvacca

Differential Revision: D48156963

Pulled By: cortinico

fbshipit-source-id: 2473ad5a84578c5236c905fd9aa9a88113fe8d22

# Conflicts:
#	scripts/publish-npm.js

re-add the file

nit

Revert "Update new_architecture.rb for React-ImageManager (#38247)"

This reverts commit 645264e249f566ce87f6aaf462e029909302fd92.
@kelset
Copy link
Collaborator Author

kelset commented Aug 11, 2023

@fortmarek fixed

@analysis-bot
Copy link

Platform Engine Arch Size (bytes) Diff
android hermes arm64-v8a 8,491,707 -454,487
android hermes armeabi-v7a 7809525 n/a
android hermes x86 8961513 n/a
android hermes x86_64 8822851 n/a
android jsc arm64-v8a 9,151,450 -388,603
android jsc armeabi-v7a 8340959 n/a
android jsc x86 9204406 n/a
android jsc x86_64 9463155 n/a

Base commit: bbcdb40
Branch: main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. Contributor A React Native contributor. p: Microsoft Partner: Microsoft Partner Pick Request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants