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 problems found while publishing 7.21.0 #15440

Merged
merged 3 commits into from Feb 20, 2023

Conversation

nicolo-ribaudo
Copy link
Member

@nicolo-ribaudo nicolo-ribaudo commented Feb 20, 2023

Q                       A
Fixed Issues? Fixes #1, Fixes #2
Patch: Bug Fix?
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

I had to manually release 7.21.0 because these problems made CI fail (https://github.com/babel/babel/actions/runs/4224580190/jobs/7335726019)

@@ -230,4 +230,4 @@ type ParseResult<Result> = Result & {
errors: ParseError[];
};

export { DecoratorsPluginOptions, FlowPluginOptions, ParseError, ParserOptions, ParserPlugin, ParserPluginWithOptions, PipelineOperatorPluginOptions, RecordAndTuplePluginOptions, TypeScriptPluginOptions, parse, parseExpression, tokTypes };
export { DecoratorsPluginOptions, FlowPluginOptions, ParseError, ParseResult, ParserOptions, ParserPlugin, ParserPluginWithOptions, PipelineOperatorPluginOptions, RecordAndTuplePluginOptions, TypeScriptPluginOptions, parse, parseExpression, tokTypes };
Copy link
Member Author

Choose a reason for hiding this comment

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

This is a regression, for some reason the file published in 7.21.0 didn't include ParseResult.

@liuxingbaoyu
Copy link
Member

These look like warnings, and I think the real failure reason has to do with FORCE_COLOR.

@babel-bot
Copy link
Collaborator

babel-bot commented Feb 20, 2023

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/53991/

@liuxingbaoyu
Copy link
Member

@liuxingbaoyu liuxingbaoyu added pkg: parser PR: Bug Fix 🐛 A type of pull request used for our changelog categories labels Feb 20, 2023
* By default, new.target use is not allowed outside of a function or class.
* Set this to true to accept such code.
*/
allowNewTargetOutsideFunction?: boolean;
Copy link
Member

Choose a reason for hiding this comment

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

Good catch! Let's add annexB together.

@nicolo-ribaudo
Copy link
Member Author

I'm trying to reproduce the original failure locally.

@nicolo-ribaudo
Copy link
Member Author

I tried make prepublish | cat on main but I still don't see the error 😕
I hope this PR fixes it, but the only way to know is to try to release a patch (since the error doesn't happen in our e2e publish tests)

@liuxingbaoyu
Copy link
Member

liuxingbaoyu commented Feb 20, 2023

Whoops, I just remembered. Probably because github's terminal doesn't fully support colors, I remember this was fixed in newer dependencies, but we don't seem to be updating it because of babel8.

But I don't understand why CI throws exception only when publishing.

@nicolo-ribaudo
Copy link
Member Author

Ohh I got it.

  • On normal CI, we run Jest with --color
  • On e2e publish, we run prepublish-build instead of prepublish, and it doesn't run tests

I'll add back FORCE_COLOR in the release GH workflow.

@liuxingbaoyu
Copy link
Member

Also I found that babel-code-frame and babel-highlight both throw exceptions.

@JLHwung JLHwung merged commit 7feaa36 into babel:main Feb 20, 2023
@nicolo-ribaudo nicolo-ribaudo deleted the publish-problems branch February 21, 2023 11:24
@github-actions github-actions bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label May 24, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
i: regression outdated A closed issue/PR that is archived due to age. Recommended to make a new issue pkg: parser PR: Bug Fix 🐛 A type of pull request used for our changelog categories
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants