-
Notifications
You must be signed in to change notification settings - Fork 24.4k
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
[Codegen]: Refactor buildPropertySchema
fn of (Flow, TS) into common fn
#35288
[Codegen]: Refactor buildPropertySchema
fn of (Flow, TS) into common fn
#35288
Conversation
aff6da6
to
a722b1a
Compare
This comment was marked as resolved.
This comment was marked as resolved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job moving this, thank you so much!
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
This comment was marked as outdated.
This comment was marked as outdated.
Hi @Pranav-yadav! I'll try to figure out what's going on and I'll suggest a fix before EOD.
Yes, please, it's better to have some workflows that fails rather then not having at all. |
a722b1a
to
76e01d4
Compare
To solve the circular dependency, I think we need to move The problem is that If we break it as described above, it should work. We should probably define some clear rules about what should go in What do you think? |
This comment was marked as resolved.
This comment was marked as resolved.
I understand. I can try myself tomorrow morning. |
@Pranav-yadav Looks like you found a solution to your error. If you encounter an error again, I am available to look at it together. |
Here we go #35343 <-- this should fix the problem(s) :) |
…#35343) Summary: This PR should solve the `"Circular Dependencies"` problem/issue because of which some PRs are getting blocked as discussed here #35288 (comment) - also moved below helpers to `parsers-commons.js`; - `getTypeAnnotationParameters` - `getFunctionNameFromParameter` - `getParameterName` - `getParameterTypeAnnotation` - `getTypeAnnotationReturnType` <3 ## Changelog [INTERNAL] [CHANGED] - Moved `translateFunctionTypeAnnotation` fn from `parsers-primitives.js` to `parsers-commons.js` also, moved it's helpers Pull Request resolved: #35343 Test Plan: - ensure 👇 is `#00ff00` `yarn lint && yarn flow && yarn test-ci` Reviewed By: christophpurrer Differential Revision: D41273191 Pulled By: rshest fbshipit-source-id: cc1839a91579e7914f05516a90b280a776510c9d
Summary: This is a task of facebook#34872 - combined `Flow` and `TypeScript` `buildPropertySchema` fn 's into single common - uses callback param `resolveTypeAnnotation` - moved it to `parsers-commons.js` - re-organize imports and exports
76e01d4
to
0cdea0e
Compare
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Base commit: 64ff077 |
Base commit: 64ff077 |
Definitely. Block comments should be added at top of both |
PR build artifact for 0cdea0e is ready. |
PR build artifact for 0cdea0e is ready. |
@cipolleschi did u notice something strange about @react-native-bot ? |
@Pranav-yadav thank you for reporting this. We have to look into that bot, I think. |
@cipolleschi After giving it another thought, I think we should merge those two files. Reason: Cohesion
Thoughts? PS: sorry for commenting under closed PR |
…facebook#35343) Summary: This PR should solve the `"Circular Dependencies"` problem/issue because of which some PRs are getting blocked as discussed here facebook#35288 (comment) - also moved below helpers to `parsers-commons.js`; - `getTypeAnnotationParameters` - `getFunctionNameFromParameter` - `getParameterName` - `getParameterTypeAnnotation` - `getTypeAnnotationReturnType` <3 ## Changelog [INTERNAL] [CHANGED] - Moved `translateFunctionTypeAnnotation` fn from `parsers-primitives.js` to `parsers-commons.js` also, moved it's helpers Pull Request resolved: facebook#35343 Test Plan: - ensure 👇 is `#00ff00` `yarn lint && yarn flow && yarn test-ci` Reviewed By: christophpurrer Differential Revision: D41273191 Pulled By: rshest fbshipit-source-id: cc1839a91579e7914f05516a90b280a776510c9d
…ook#35288) Summary: This PR is a task of facebook#34872 - combined `Flow` and `TS` `buildPropertySchema` fn 's into common fn - added callback param `resolveTypeAnnotation` to the same - moved it to `parsers-commons.js` - re-organized imports and exports ## Changelog [INTERNAL] [CHANGED] - [Codegen]: Refactored `buildPropertySchema` fn of (Flow, TS) into common fn in `parsers-commons.js` Pull Request resolved: facebook#35288 Test Plan: - ensure 👇 is `#00ff00` ```bash yarn lint && yarn flow && yarn test-ci ``` Reviewed By: christophpurrer Differential Revision: D41247738 Pulled By: cipolleschi fbshipit-source-id: aecc0ed8d07efa1c2c39e8a8e64b4ee73b720b8f
Summary
This PR is a task of #34872
Flow
andTS
buildPropertySchema
fn 's into common fnresolveTypeAnnotation
to the sameparsers-commons.js
Changelog
[INTERNAL] [CHANGED] - [Codegen]: Refactored
buildPropertySchema
fn of (Flow, TS) into common fn inparsers-commons.js
Test Plan
#00ff00