{"action":"created","issue":{"url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/6973","repository_url":"https://api.github.com/repos/CocoaPods/CocoaPods","labels_url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/6973/labels{/name}","comments_url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/6973/comments","events_url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/6973/events","html_url":"https://github.com/CocoaPods/CocoaPods/issues/6973","id":252067557,"number":6973,"title":"Source files not found for subspecs","user":{"login":"rzolin","id":316550,"avatar_url":"https://avatars0.githubusercontent.com/u/316550?v=4","gravatar_id":"","url":"https://api.github.com/users/rzolin","html_url":"https://github.com/rzolin","followers_url":"https://api.github.com/users/rzolin/followers","following_url":"https://api.github.com/users/rzolin/following{/other_user}","gists_url":"https://api.github.com/users/rzolin/gists{/gist_id}","starred_url":"https://api.github.com/users/rzolin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rzolin/subscriptions","organizations_url":"https://api.github.com/users/rzolin/orgs","repos_url":"https://api.github.com/users/rzolin/repos","events_url":"https://api.github.com/users/rzolin/events{/privacy}","received_events_url":"https://api.github.com/users/rzolin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":9,"created_at":"2017-08-22T19:42:53Z","updated_at":"2017-08-23T18:12:18Z","closed_at":null,"body":"* [√] I've read and understood the [*CONTRIBUTING guidelines and have done my best effort to follow](https://github.com/CocoaPods/CocoaPods/blob/master/CONTRIBUTING.md).\r\n\r\nIt could be simple misunderstanding on my side. But searching for the answer didn't get good results in the CocoaPods Guides or on StackOverflow. So, some help would be really appreciated.\r\n\r\nI am trying to setup a framework with a couple of subspecs: `DataManagement` and `Networking`, which are grouped into the `Core` subspec (copied from `RestKit`). As I understood the `Core` subspec could be replaced with `default_subspecs = 'DataManagement', 'Networking'` to the same effect (probably).\r\n\r\nNeed to mention that at some point I used general `source_files` pattern to include all files for the entire framework and it work. So there is something wrong with subspec config I assume.\r\n\r\n# Report\r\n\r\n## What did you do?\r\n\r\nI created a framework (`pod spec create`) and was trying to `lint` it with `pod lib lint`. \r\n\r\nThe directory structure is as following:\r\n```\r\nMessengerFramework\r\n   > Assets (not used)\r\n   > Code\r\n       > ReplaceMe.swift\r\n       > DataManagement\r\n           > ReplaceMe.swift\r\n           > Model\r\n               > Model.xcdatamodeld\r\n       > Networking\r\n           > ReplaceMe.swift\r\n       > DataManagement.h\r\n       > Networking.h\r\n```\r\n\r\n## What did you expect to happen?\r\n\r\nI was expecting to pass all the checks.\r\n\r\n## What happened instead?\r\n\r\nGetting the error:\r\n```\r\n-> MessengerFramework (0.1.0)\r\n    - ERROR | [MessengerFramework/DataManagement,MessengerFramework/Networking] file patterns: The `source_files` pattern did not match any file.\r\n```\r\nAlso if uncomment the `resources` and `preserve_paths` they also give the error about not found files. \r\n\r\n## CocoaPods Environment\r\n\r\n### Stack\r\n\r\n```\r\n   CocoaPods : 1.3.1\r\n        Ruby : ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-darwin16]\r\n    RubyGems : 2.6.11\r\n        Host : Mac OS X 10.12.6 (16G29)\r\n       Xcode : 8.3.3 (8E3004b)\r\n         Git : git version 2.14.1\r\nRuby lib dir : /usr/local/Cellar/ruby/2.4.1_1/lib\r\nRepositories : master - https://github.com/CocoaPods/Specs.git @ 9e769bf7f0a353b76666db836be764b168ec905b\r\n```\r\n\r\n### Installation Source\r\n\r\n```\r\nExecutable Path: /usr/local/bin/pod\r\n```\r\n\r\n### Plugins\r\n\r\n```\r\ncocoapods-deintegrate : 1.0.1\r\ncocoapods-plugins     : 1.0.0\r\ncocoapods-search      : 1.0.0\r\ncocoapods-stats       : 1.0.0\r\ncocoapods-trunk       : 1.2.0\r\ncocoapods-try         : 1.1.0\r\n```\r\n\r\n## Pod Spec in question\r\n\r\n```\r\nPod::Spec.new do |s|\r\n  s.name             = 'MessengerFramework'\r\n  s.version          = '0.1.0'\r\n  s.summary          = 'some desc'\r\n\r\n  s.description      = <<-DESC\r\n some desc\r\n                      DESC\r\n\r\n  s.homepage         = 'http://www.example.com'\r\n  s.license          = { :type => 'MIT', :file => 'LICENSE' }\r\n  s.author           = { 'rzolin' => 'rzolin@gmail.com' }\r\n  s.source           = { :git => '<git-repo>', :tag => s.version.to_s }\r\n\r\n  # Platform setup\r\n  s.requires_arc = true\r\n  s.ios.deployment_target = '8.0'\r\n\r\n  s.default_subspec = 'Core'\r\n\r\n  ### Subspecs\r\n  s.subspec 'Core' do |cs|\r\n    cs.dependency 'MessengerFramework/DataManagement'\r\n    cs.dependency 'MessengerFramework/Networking'\r\n  end\r\n\r\n  s.subspec 'DataManagement' do |ds|\r\n    ds.source_files = 'Code/DataManagement.h', 'Code/DataManagement/**/*'\r\n  #  ds.resources = [ 'Code/DataManagement/Model/Model.xcdatamodeld', 'Code/DataManagement/Model/Model.xcdatamodeld/*.xcdatamodel' ]\r\n  #  ds.preserve_paths = 'Code/DataManagement/Model/Model.xcdatamodeld'\r\n  end\r\n\r\n  s.subspec 'Networking' do |ns|\r\n    ns.source_files = 'Code/Networking.h', 'Code/Networking/**/*.{h,m,swift}'\r\n  end\r\n\r\n  # s.resource_bundles = {\r\n  #   'MessengerFramework' => ['MessengerFramework/Assets/*.png']\r\n  # }\r\n\r\n  # s.public_header_files = 'Pod/Classes/**/*.h'\r\n  # s.frameworks = 'UIKit', 'MapKit'\r\n  # s.dependency 'AFNetworking', '~> 2.3'\r\nend\r\n\r\n```\r\n\r\n## Project that demonstrates the issue\r\n\r\nSample Project is [here](https://github.com/rzolin/SampleMessengerCocoapodFramework)"},"comment":{"url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/comments/324417962","html_url":"https://github.com/CocoaPods/CocoaPods/issues/6973#issuecomment-324417962","issue_url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/6973","id":324417962,"user":{"login":"rzolin","id":316550,"avatar_url":"https://avatars0.githubusercontent.com/u/316550?v=4","gravatar_id":"","url":"https://api.github.com/users/rzolin","html_url":"https://github.com/rzolin","followers_url":"https://api.github.com/users/rzolin/followers","following_url":"https://api.github.com/users/rzolin/following{/other_user}","gists_url":"https://api.github.com/users/rzolin/gists{/gist_id}","starred_url":"https://api.github.com/users/rzolin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rzolin/subscriptions","organizations_url":"https://api.github.com/users/rzolin/orgs","repos_url":"https://api.github.com/users/rzolin/repos","events_url":"https://api.github.com/users/rzolin/events{/privacy}","received_events_url":"https://api.github.com/users/rzolin/received_events","type":"User","site_admin":false},"created_at":"2017-08-23T18:12:18Z","updated_at":"2017-08-23T18:12:18Z","body":"Good call! Thanks. I pretty much copied from RestKit, but probably the directory structure is different. \r\n\r\nBut now there is another error:\r\n```\r\n-> SampleMessengerCocoapodFramework (0.1.0)\r\n    - WARN  | description: The description is equal to the summary.\r\n    - ERROR | [iOS] unknown: Encountered an unknown error (Unable to find other source ref for /Users/rzolin/Projects/ArmorText/iOS-Pod-Test/SampleMessengerCocoapodFramework/SampleMessengerCocoapodFramework/Code/DataManagement/Model/Model.xcdatamodeld/Model.xcdatamodel/contents for target SampleMessengerCocoapodFramework.) during validation.\r\n\r\n[!] SampleMessengerCocoapodFramework did not pass validation, due to 1 error and 1 warning.\r\nYou can use the `--no-clean` option to inspect any issue.\r\n```\r\n\r\nI've added the `resources` and `preserve_path` from some solutions to CoreData model. But it doesn't help. And again, I cannot get more help on the Internet. Even the error description itself is not clear to me. Reference to file? In the Project or in Pod/Framework? \r\nSo, any help is appreciated."}}
{"actor":{"display_login":"rzolin"}}