-
Notifications
You must be signed in to change notification settings - Fork 28.7k
Only run pod install
on the first iOS build
#108205
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
Conversation
@@ -11,15 +11,15 @@ import 'test_utils.dart'; | |||
|
|||
void main() { | |||
test('flutter build ios --config only updates generated xcconfig file without performing build', () async { | |||
final String workingDirectory = fileSystem.path.join(getFlutterRoot(), 'examples', 'hello_world'); | |||
final String workingDirectory = fileSystem.path.join(getFlutterRoot(), 'dev', 'integration_tests', 'flutter_gallery'); |
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.
Change to example project that has pods.
This comment was marked as outdated.
This comment was marked as outdated.
78a9880
to
e0b7cb1
Compare
pod install
on the first iOS build
_fileSystem.file(fingerprintPath).writeAsStringSync(fingerprint.toJson()); | ||
final File fingerprintFile = _fileSystem.file(fingerprintPath); | ||
fingerprintFile.createSync(recursive: true); | ||
fingerprintFile.writeAsStringSync(fingerprint.toJson()); |
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.
Fingerprint write error: FileSystemException: Cannot open file, path = 'build/ios/pod_inputs.fingerprint' (OS Error: No such file or directory, errno = 2)
writeAsStringSync
wasn't recursively creating the directory structure. This write succeeded after the first successful build.
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.
d'oh
testWithoutContext('fingerprint does match if identical', () { | ||
fileSystem.file('a.dart').createSync(); | ||
fileSystem.file('b.dart').createSync(); | ||
|
||
const String fingerprintPath = 'path/to/out.fingerprint'; |
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.
This test failed on master.
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.
Nice catch, LGTM
pod install
is skipped based on SHAs stored in a fingerprint file. Fix the bug where the fingerprint file isn't being written to the first time when the directory structure isn't created.pod install
whenGenerated.xcconfig
changes. The build settings in the file should not impact any of the dependencies anymore, and that file changes all the time like every time you run a differentintegration_test
test.Fixes #108202
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.