Xcode 11 b4 build fails when there are Swift Packages in the project

xcode
#1

Bitrise Build Issue Report template

Description of the issue

When I add swift packages to an iOS project using the new Xcode 11 feature, I get warnings:
$ bundle install

$ bundle exec ruby /var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/step.rb

[!] Xcodeproj doesn’t know about the following attributes {“productRef”=>“FA0E851722EAE63800DA50D3”} for the ‘PBXBuildFile’ isa.

If this attribute was generated by Xcode please file an issue: https://github.com/CocoaPods/Xcodeproj/issues/new

[!] Xcodeproj doesn’t know about the following attributes {“packageProductDependencies”=>[“FA0E851722EAE63800DA50D3”]} for the ‘PBXNativeTarget’ isa.

If this attribute was generated by Xcode please file an issue: https://github.com/CocoaPods/Xcodeproj/issues/new

[!] Xcodeproj doesn’t know about the following attributes {“packageReferences”=>[“FA0E851622EAE63800DA50D3”]} for the ‘PBXProject’ isa.

If this attribute was generated by Xcode please file an issue: https://github.com/CocoaPods/Xcodeproj/issues/new

And then the step fails:

Error:

[Xcodeproj] Unknown object version.

Stacktrace (for debugging):

/Users/vagrant/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/xcodeproj-1.7.0/lib/xcodeproj/project.rb:223:in `initialize_from_file’

/Users/vagrant/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/xcodeproj-1.7.0/lib/xcodeproj/project.rb:108:in `open’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:273:in `block in archivable_target_and_container_project’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:263:in `each’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:263:in `archivable_target_and_container_project’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:298:in `block in read_scheme_archivable_target_and_container_project’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:294:in `each’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:294:in `read_scheme_archivable_target_and_container_project’

/private/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/lib/autoprovision/project_helper.rb:24:in `initialize’

/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/step.rb:43:in `new’

/var/folders/6q/wgy6jtp12w5gzgm9lzcglpqw0000gn/T/bitrise735625962/step_src/step.rb:43:in `’

Environment:

stack: Xcode 11.0.x, on macOS 10.14.5 (Mojave)
Workflow: ios-auto-provision@1.3.1 (exit code: 1)

Reproducibility

Rebuilding causes the same problem

Local reproduction

Application builds and runs fine locally, and for clones on other machines.

Local reproduction: Linux / Android (docker based) stack builds

Build log

0 Likes

iOS Auto Provisioning Step not working with Xcode 11 beta
#2

Hi @AbizerOrdre! :wave: I wasn’t able to access your build log in the included link, so could you please send me the build URL for a build where you are experiencing this issue? That would start with app.bitrise.io/build/. Thanks :smile:

0 Likes

#3

I think this looks like the right one https://app.bitrise.io/build/304e6665a52299d3#

0 Likes

#4

Perfect, thanks! It’s possible that your gem is pointing to a ruby version that isn’t compatible with the xcodeproj pod. Could you please add a script step with the following contents:

gem list xcodeproj

run that build, and send me the build URL for that build?

Thanks! :smile:

0 Likes

#5

Thanks for the response, here’s a link to the new build

0 Likes

#6

Sorry. should be

https://app.bitrise.io/build/e28169b081624ced

0 Likes

#7

This is quite perplexing, because this error appears to occur when xcodeproj being provided the wrong ruby version. Your stacktrace would indicate, however, that ryby 2.6.3 is in use for xcodeproj 1.7.0, which should be just fine. You can consider doing the following:

  1. Make sure your /Users/vagrant/.rbenv/ folder doesnt contain any unused ruby version that xcodeproj 1.7.0 might be connecting to.
  2. Try using the latest version of xcodeproj (1.11.0)
0 Likes

#8

@AbizerOrdre I just wanted to mention that this is a verified step issue and we are currently working on a fix. I’ll announce it here when it’s been rolled out. Thanks for your patience :smile:

0 Likes

closed #9

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

0 Likes