Adjust the position of require File.expand_path#141521
Adjust the position of require File.expand_path#141521auto-submit[bot] merged 1 commit intoflutter:masterfrom
Conversation
There was a problem hiding this comment.
any reason why this shouldn't be at the top of the file?
There was a problem hiding this comment.
This line of code must be placed after the flutter_root method, otherwise the following error will be reported.
❯ pod install
[!] Invalid `Podfile` file: undefined local variable or method `flutter_root' for main:Object
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
^^^^^^^^^^^^.It is also used like this in Podfile-ios-objc.
flutter/packages/flutter_tools/templates/cocoapods/Podfile-ios-objc
Lines 13 to 26 in 67457e6
There was a problem hiding this comment.
Ahh I see, makes sense
@jmagman this code change seems ok to me, but probably more important, is this a supported workflow? |
jmagman
left a comment
There was a problem hiding this comment.
Sometimes we only need to use the install_flutter_plugin_pods method in podhelper.rb. For example, using Shorebird in an iOS hybird app scenario, we need to build Flutter.xcframework and App.xcframework and embed them into the iOS native project. In order to avoid unnecessary conflicts, use install_flutter_plugin_pods method to install Flutter plugin pods.
@LinXunFeng can you explain this a bit more, I'm curious. Is the scenario that your hybrid app uses CocoaPods and needs the same pods between the native app and the Flutter module? So you'd rather pod install run only once and deal with all the version solving so they don't conflict? Or is there something else going on?
is this a supported workflow?
It's not "supported" but I wouldn't go out of my way to break it. This change LGTM.
There was a problem hiding this comment.
By the way, thank you so much for the test!
@jmagman According to the various ways to integrate the Flutter module introduced in the document, our app initially used When using the above command, Shorebird will use its own modified Flutter framework and engine to build In my Flutter module, I use some Flutter plugins based on native third packages, such as Pod::Spec.new do |s|
s.name = 'sqflite'
...
s.dependency 'FMDB', '>= 2.7.5'
...
endWhen using The following error will occur when compiling. Showing Recent Messages
Multiple commands produce '/Users/lxf/.../xxx.app/Frameworks/FMDB.framework'And the Pod::Spec.new do |s|
s.name = 'realm'
...
s.vendored_frameworks = 'realm_dart.xcframework'
...
endRelated feedback: #125530 I also tried to embed these I have tried putting the Even if the above problem was solved, our app would crash as soon as it started. After investigation, I found that it was because dyld[31764]: Symbol not found: _$s12ReachabilityAAC10ConnectionO4wifiyA2DmFWC
Referenced from: <8142F86E-4C9C-3513-AD29-D3522FC6677F> /Users/lxf/.../connectivity_plus.framework/connectivity_plus
Expected in: <DA318000-9A97-35AD-87EA-7C5B635DE010> /Users/lxf/.../Frameworks/Reachability.framework/ReachabilityIn addition, we also need to determine whether each Related feedback: #122183 Based on so many problems mentioned above, I finally chose to create a |
ad3d363 to
fd8b6bc
Compare
flutter/flutter@ddf60fb...5dea6b9 2024-01-21 [email protected] Roll Flutter Engine from 2b31ad2fb819 to a7b207d5a1fe (1 revision) (flutter/flutter#141945) 2024-01-21 [email protected] [flutter_tools] update analyze_once_test.dart to be null-safe (flutter/flutter#141790) 2024-01-21 [email protected] Adjust the position of require File.expand_path (flutter/flutter#141521) 2024-01-21 [email protected] Add RadioListItem use-case to a11y_assessments (flutter/flutter#140984) 2024-01-20 [email protected] Roll Flutter Engine from 704ef3399012 to 2b31ad2fb819 (1 revision) (flutter/flutter#141937) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
On
Podfile:Encountering the following error after executing
pod install:The
flutter_relative_path_from_podfilemethod is influtter_tools/bin/podhelper.rb, but nowflutter_tools/bin/podhelper.rbis only required ininstall_all_flutter_podsinpodhelper.rb.tmpl.Sometimes we only need to use the
install_flutter_plugin_podsmethod in podhelper.rb. For example, usingShorebirdin an iOS hybird app scenario, we need to buildFlutter.xcframeworkandApp.xcframeworkand embed them into the iOS native project. In order to avoid unnecessary conflicts, useinstall_flutter_plugin_podsmethod to install Flutter plugin pods.Shorebird - Code Push In Hybrid Apps
So I adjust the position of
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root).Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.