Skip to content
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

Pod [V1.5.0] lib lint fail with error "AppIcon" in case of its dependency or subspec contains a xcassets type resources #7617

Open
seuzxh opened this Issue Apr 11, 2018 · 20 comments

Comments

Projects
None yet
10 participants
@seuzxh
Copy link

seuzxh commented Apr 11, 2018

Report

What did you do?

  • I create a test Pod with command "pod lib create"
  • I add a subspec named "TestSub1" in the podspec file
  • Add resources of "TestSub1" with the xcassets file
  • run "pod lib lint --allow-warnings --verbose --fail-fast --no-clean"

What did you expect to happen?

  • lint success

What happened instead?

  • lint fail with message
/* com.apple.actool.errors */
/Users/zhaoxianghui/Documents/XCProject/TestPod1.5.0/TestSub1/Assets/testpodAset.xcassets: error: None of the input catalogs contained a matching stickers icon set or app icon set named  "AppIcon".
/* com.apple.actool.compilation-results */
/Users/zhaoxianghui/Library/Developer/Xcode/DerivedData/App-ephhbjaiwsmhsbexfmoptnatintl/Build/Products/Release-iphonesimulator/App.app/Assets.car
/Users/zhaoxianghui/Library/Developer/Xcode/DerivedData/App-ephhbjaiwsmhsbexfmoptnatintl/Build/Products/Release-iphonesimulator/assetcatalog_generated_info.plist
Command /bin/sh failed with exit code 1
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution [CP]\ Copy\ Pods\ Resources /Users/zhaoxianghui/Library/Developer/Xcode/DerivedData/App-ephhbjaiwsmhsbexfmoptnatintl/Build/Intermediates.noindex/App.build/Release-iphonesimulator/App.build/Script-2991DDF45C0A25EC16418712.sh

CocoaPods Environment

Stack

   CocoaPods : 1.5.0
        Ruby : ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-darwin16]
    RubyGems : 2.6.8
        Host : Mac OS X 10.13.4 (17E199)
       Xcode : 9.3 (9E145)
         Git : git version 2.9.2
Ruby lib dir : /usr/local/Cellar/ruby/2.3.3/lib
Repositories : coding-hging-specs - https://git.coding.net/hging/Specs.git @ 69c5cf4775bd6fde8b04782d6a3725d8d738f31a
               master - https://github.com/CocoaPods/Specs.git @ 18020377917e622f64b4b73808de98b6cf39e5be

Installation Source

Executable Path: /usr/local/bin/pod

Plugins

cocoapods-deintegrate : 1.0.2
cocoapods-plugins     : 1.0.0
cocoapods-search      : 1.0.0
cocoapods-stats       : 1.0.0
cocoapods-trunk       : 1.3.0
cocoapods-try         : 1.1.0

Project that demonstrates the issue

you can get the demo project from here:

Demo Project

@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 11, 2018

yeap this is a bug in validator, the ASSETCATALOG_COMPILER_APPICON_NAME is set to an image that does not exist. Will fix for 1.5.1.

@dnkoutso dnkoutso added this to the 1.5.1 milestone Apr 11, 2018

@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 11, 2018

Also appears to be in subspecs only as you correctly stated in the beginning.

@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 11, 2018

@seuzxh figured it out. It's because your subspec has no sources it gets integrated differently. Definitely a bug but if you add a source file to your subspec it works.

@dnkoutso dnkoutso removed this from the 1.5.1 milestone Apr 11, 2018

@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 11, 2018

This will most likely get fixed for 1.6.0 depending on progress on revamped pods project generation and target installation.

@seuzxh

This comment has been minimized.

Copy link
Author

seuzxh commented Apr 11, 2018

@dnkoutso As you replied "It's because your subspec has no sources it gets integrated differently. "
Do you mean I should add some source_files for my subspec like this ?

  s.subspec 'TestSub1' do |sub1|
    sub1.source_files = 'TestSub1/*'

    sub1.resources = 'TestSub1/Assets/testpodAset.xcassets' #'TestSub1/Assets/**/*.png'

  end
@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 11, 2018

Yeap

@seuzxh

This comment has been minimized.

Copy link
Author

seuzxh commented Apr 11, 2018

Oh ~ I tried again, it pass validation.

@seuzxh

This comment has been minimized.

Copy link
Author

seuzxh commented Apr 11, 2018

@dnkoutso It pass validation after I add the source_files
But I found if I add the --use-libraries option, it failed again with the same error message as I said before.

pod lib lint --allow-warnings  --use-libraries --verbose --fail-fast --no-clean  **--use-libraries**
@dnkoutso

This comment has been minimized.

Copy link
Contributor

dnkoutso commented Apr 17, 2018

@seuzxh will need to investigate. sorry havent had time.

@passol1988

This comment has been minimized.

Copy link

passol1988 commented May 18, 2018

@seuzxh Did u have any solution?
I met same issue when I --use-libraries and it prompt None of the input catalogs contained a matching stickers icon set or app icon set named "AppIcon".

@passol1988

This comment has been minimized.

Copy link

passol1988 commented May 18, 2018

I use cocoapods (version 1.4.0) is Ok.while 1.5.0 and 1.5.2 it reproduces error.

@seuzxh

This comment has been minimized.

Copy link
Author

seuzxh commented May 18, 2018

@passol1988 I've no solution now, but @dnkoutso said this issue will be fixed in 1.6.0 version....
But I think this is a big issue for my team.....

@bazik123

This comment has been minimized.

Copy link

bazik123 commented Sep 4, 2018

is this fixed in 1.6.0-alfa?

have you found any workarounds?

@tomasgreen

This comment has been minimized.

Copy link

tomasgreen commented Oct 17, 2018

For anyone still stuck on this, try adding an empty AppIcon to the assets, it's not graceful but it worked.

@JimmyYezeguelian

This comment has been minimized.

Copy link

JimmyYezeguelian commented Oct 17, 2018

For anyone still stuck on this, try adding an empty AppIcon to the assets, it's not graceful but it worked.

Yes of course but after that you'll find that you can't have multiple xcasset (#8136)

@tomasgreen

This comment has been minimized.

Copy link

tomasgreen commented Oct 17, 2018

For anyone still stuck on this, try adding an empty AppIcon to the assets, it's not graceful but it worked.

Yes of course but after that you'll find that you can't have multiple xcasset (#8136)

Yeah, that was bad advice, turns out it way more effective to exclude it from the resources and add them as a resource bundle instead.

@zhgw01

This comment has been minimized.

Copy link

zhgw01 commented Nov 5, 2018

Is there any plan to fix this issue?

@xdkhan

This comment has been minimized.

Copy link

xdkhan commented Nov 14, 2018

This bug still exists in the new version(1.6.0 beta2)

@amorde

This comment has been minimized.

Copy link
Member

amorde commented Nov 15, 2018

PRs are welcome :)

@lucasanovaes

This comment has been minimized.

Copy link

lucasanovaes commented Nov 21, 2018

Still happening using Xcode 10.0 and cocoapods: 1.6.0.beta.2

The only workaround is to add an empty "AppIcon" inside .xcassets 😅

@amorde amorde added the help wanted label Nov 21, 2018

wmathurin added a commit to wmathurin/SalesforceMobileSDK-iOS that referenced this issue Nov 28, 2018

Generated app with cocoapod 1.5 or 1.6 fail to build with None of the…
… input catalogs contained a matching stickers icon set or app icon set named "AppIcon".

See CocoaPods/CocoaPods#7816
Adding empty AppIcon as suggested here: CocoaPods/CocoaPods#7617 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.