Skip to content

Conversation

@jonahwilliams
Copy link
Contributor

@jonahwilliams jonahwilliams commented Jan 29, 2019

  • Adds generate command, which runs code generation without compiling to kernel.
  • Separates code generation APIs based on build_runner usage to keep google3 rolling simple. Only the BuildRunner directory cannot be used (added a forbidden imports tests to catch this).
  • When the experimental flutter build is enabled swap out

Basic flutter app which brews coffee on button press, requires dart inject code generation to run.

Work towards #27141

@jonahwilliams jonahwilliams requested a review from yjbanov January 29, 2019 21:27
@zoechi zoechi added a: tests "flutter test", flutter_test, or one of our tests tool Affects the "flutter" command-line tool. See also t: labels. labels Jan 30, 2019
@jonahwilliams
Copy link
Contributor Author

cc @yjbanov PTAL

@yjbanov
Copy link
Contributor

yjbanov commented Feb 7, 2019

lgtm

@jonahwilliams jonahwilliams changed the title Add basic codegen app to be used for integration testing and benchmarks [WIP] Add basic codegen app to be used for integration testing and benchmarks Feb 7, 2019
@jonahwilliams jonahwilliams changed the title [WIP] Add basic codegen app to be used for integration testing and benchmarks Add basic codegen app to be used for integration testing and benchmarks Feb 11, 2019
@jonahwilliams
Copy link
Contributor Author

Adding @zanderso for tool changes

@jonahwilliams
Copy link
Contributor Author

Unless anyone has any comments, I will land this tonight after the build is green

Copy link
Contributor

@yjbanov yjbanov left a comment

Choose a reason for hiding this comment

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

I only have some nits. LGTM.

import 'runner.dart' as runner;
import 'src/base/context.dart';
// The build_runner code generation is provided here to make it easier to
// avoid introducing the dependency into google3.
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: This aspect might be useful to others companies, so I'd phrase it as "avoid introducing the dependency into build systems that use their own codegen methods, such as Google's internal infrastructure".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is only an issue for google3 because the build packages are not synced. In theory it could run...

verboseHelp: verboseHelp);
verboseHelp: verboseHelp,
overrides: <Type, Generator>{
// The build runner instance is not supported in google3.
Copy link
Contributor

Choose a reason for hiding this comment

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

same nit here

Copy link
Member

@zanderso zanderso left a comment

Choose a reason for hiding this comment

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

lgtm

@jonahwilliams jonahwilliams merged commit 67cf215 into flutter:master Feb 15, 2019
@jonahwilliams jonahwilliams deleted the add_integration branch February 15, 2019 07:33
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

a: tests "flutter test", flutter_test, or one of our tests tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants