title: Flutter Archive app to testflight gives error ITMS-90338: Non-public API usage
body: <p>I'm developing a Flutter application and trying to upload a new build to testFlight</p>
  <blockquote>
  <p>flutter doctor -v</p>
  <p>[✓] Flutter (Channel stable, v1.9.1+hotfix.6, on Mac
  OS X 10.15.5 19F101, locale
  en-US)
  • Flutter version 1.9.1+hotfix.6 at /Users/shadysherif/Documents/Dev/flutter
  • Framework revision 68587a0916 (10 months ago), 2019-09-13 19:46:58 -0700
  • Engine revision b863200c37
  • Dart version 2.5.0</p>
  <p>[✗] Android toolchain - develop for Android devices
  ✗ Unable to locate Android SDK.
  Install Android Studio from:
  <a href="https://developer.android.com/studio/index.html" rel="nofollow noreferrer">https://developer.android.com/studio/index.html</a>
  On first launch it will assist you in installing the Android SDK
  components.
  (or visit <a href="https://flutter.dev/setup/#android-setup" rel="nofollow noreferrer">https://flutter.dev/setup/#android-setup</a> for detailed
  instructions).
  If the Android SDK has been installed to a custom location, set
  ANDROID_HOME to that location.
  You may also want to add it to your PATH environment variable.</p>
  <p>[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
  • Xcode at /Applications/Xcode.app/Contents/Developer
  • Xcode 11.5, Build version 11E608c
  • CocoaPods version 1.9.3</p>
  <p>[!] Android Studio (not installed)
  • Android Studio not found; download from
  <a href="https://developer.android.com/studio/index.html" rel="nofollow noreferrer">https://developer.android.com/studio/index.html</a>
  (or visit <a href="https://flutter.dev/setup/#android-setup" rel="nofollow noreferrer">https://flutter.dev/setup/#android-setup</a> for detailed
  instructions).</p>
  <p>[!] Connected device
  ! No devices available</p>
  <p>! Doctor found issues in 3 categories.</p>
  </blockquote>
  <h2>Problem #1</h2>
  <p>After archiving the application and uploading it to testFlight, I got a success message but I can't find any build on the testFlight. I waited more than 10 minutes and testFlight shows <code>no builds</code>. I tried many times and I also tried to export instead of the upload because a colleague told me It could be XCode issue while uploading and I used the tool and I had no luck.</p>
  <p><a href="https://i.stack.imgur.com/H4FRZ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/H4FRZ.png" alt="enter image description here" /></a></p>
  <p><strong>Finally, I found that the errors were sent as an email to my developer account email !!!</strong></p>
  <h2>Problem #2</h2>
  <p>I'm happy that I found the error and here all the details:</p>
  <blockquote>
  <p>We identified one or more issues with a recent delivery for your app,
  &quot;app name&quot; version. Please correct the
  following issues, then upload again.</p>
  <p>ITMS-90338: Non-public API usage - The app references non-public
  symbols in Frameworks/Flutter.framework/Flutter: _ptrace. If method
  names in your source code match the private Apple APIs listed above,
  altering your method names will help prevent this app from being
  flagged in future submissions. In addition, note that one or more of
  the above APIs may be located in a static library that was included
  with your app. If so, they must be removed. For further information,
  visit the Technical Support Information at
  <a href="http://developer.apple.com/support/technical/" rel="nofollow noreferrer">http://developer.apple.com/support/technical/</a></p>
  </blockquote>
  <p>I didn't find much help online</p>