RxSwiftCommunity / RxDataSources

UITableView and UICollectionView Data Sources for RxSwift (sections, animated updates, editing ...)
MIT License
3.09k stars 494 forks source link

Example app cannot run. #261

Open lm2343635 opened 6 years ago

lm2343635 commented 6 years ago

I have downloaded the repository with git clone and installed the dependencies with Carthage update. When I tried to run the Example, I found that there is no Rx.xcodeproj (it is red). I moved the RxDataSources.xcodeproj behind the Rx.xcodeproj and the demo app was launched. However, the demo was crashed. image

FranklySimple commented 6 years ago

I hit the same issue a couple of days ago. You could try: Make sure you have the official xcode 10 release version, and have set the cl setting to the release version. Can also try to remove all versions of xcode and reinstalling xcode 10

lm2343635 commented 5 years ago

How can I set the cl setting to the release version?

FranklySimple commented 5 years ago

xcode --> preferences --> locations --> command line tools: select the xcode 10 release version

lm2343635 commented 5 years ago

image

Build error 😂😂😂

cozzin commented 5 years ago

This is a bit different from the problem, but I could not run the example file either. I can't install pod file for example app.

seonghoui-MacBookPro:RxDataSources seongho$ ls
CHANGELOG.md        LICENSE.md      RxDataSources.podspec
Cartfile        Package.resolved    RxDataSources.xcodeproj
Cartfile.resolved   Package.swift       Sources
Differentiator.podspec  Podfile         Tests
Examples        README.md
seonghoui-MacBookPro:RxDataSources seongho$ pod install
Analyzing dependencies
[!] Unable to find a target named `Example`, did find `RxDataSources`, `Differentiator`, and `Tests`.
seonghoui-MacBookPro:RxDataSources seongho$ 
kzaher commented 5 years ago

I've forgot to remote the Podfile. We are using git submodules now.

Supporting multiple integration methods took too much time.

lm2343635 commented 5 years ago

You need to run pod install in the directory Examples @cozzin

cozzin commented 5 years ago

@kzaher hi, thank you for your comment. I had tried to use git submodules, but I still can't build example app.

seonghoui-MacBookPro:dev seongho$ cd /Users/seongho/Documents/dev/RxDataSources/Examples 
seonghoui-MacBookPro:Examples seongho$ /Users/seongho/Documents/dev/RxDataSources/Examples/dependencies.sh 
Submodule path 'RxSwift': checked out 'd158e7700655114e990313948d2de561d50e1115'
HEAD is now at e8aa1d89 Release 4.4.0

2018-11-07 9 47 07

Here is the project file https://drive.google.com/file/d/11mv22zSYxNlIlSulAgCFSw8VL4aqfavC/view?usp=sharing.

@lm2343635 hello, I also tried pod install in the directory Examples, but I can't install pod.

seonghoui-MacBookPro:RxDataSources seongho$ cd Examples/
seonghoui-MacBookPro:Examples seongho$ pod install
[in /Users/seongho/Documents/dev/RxDataSources]
Analyzing dependencies
[!] Unable to find a target named `Example`, did find `RxDataSources`, `Differentiator`, and `Tests`.
lm2343635 commented 5 years ago

RxDataSources/Examples/Example @cozzin Run the pod install in the directory which contains a file named Podfile

cozzin commented 5 years ago

@lm2343635 I've changed the current folder location, but the result is the same.

seonghoui-MacBookPro:Example seongho$ cd /Users/seongho/Documents/dev/RxDataSources/Examples/Example 
seonghoui-MacBookPro:Example seongho$ pod install
[in /Users/seongho/Documents/dev/RxDataSources]
Analyzing dependencies
[!] Unable to find a target named `Example`, did find `RxDataSources`, `Differentiator`, and `Tests`.

First of all, as mentioned https://github.com/RxSwiftCommunity/RxDataSources/issues/261#issuecomment-436378363, the Podfile has been removed based on the current master branch. f54c744ed0f78c5f419d4e6bb71372ed4dc75177

lm2343635 commented 5 years ago

Run carthage update --platform iOS in the directory RxDataSources

cozzin commented 5 years ago
$ carthage update --platform iOS
*** Fetching RxSwift
*** Checking out RxSwift at "4.4.0"
*** xcodebuild output can be found in /var/folders/8t/bj9zpqgd73s3tcsmmrcvzf700000gn/T/carthage-xcodebuild.iGhvH2.log
*** Downloading RxSwift.framework binary at "Atomic"

@lm2343635 thank you for your help. but it also doesn't work. Have you tested on your current master branch?

2018-11-07 12 42 21
lm2343635 commented 5 years ago

Try to move the RxDataSources.xcodeproj to your project.

cozzin commented 5 years ago

@lm2343635 Where do I have to move RxDataSources.xcodeproj file?

@kzaher If a client need to install Carthage and move the files into the example files, I think we need to provide a guide document or change the structure.

lm2343635 commented 5 years ago

Open Finder and drop it into your Xcode.

mkko commented 5 years ago

If you checked the project with git, run

git submodule init
git submodule update
cozzin commented 5 years ago

After deleting all the files and cloning again, I went to the example file and ran the dependencies.sh file so that I could build it. Thank you.

/Users/user/Documents/Code/RxDataSources/Examples/dependencies.sh
AjinkyaSharma commented 5 years ago

As of today, when i clone the project, I don't see any dependencies.sh. The same error keeps showing. No such module RXSwift. Plus there is no podfile to run a pod install!!

mkko commented 5 years ago

@AjinkyaSharma, looks like the example is using carthage. Just run

carthage update

at the root of the project (where the Cartfile is). It was a submodule once, but apparently was changed a month ago.

philosopherdog commented 2 years ago

carthage update --use-xcframeworks

You will also likely need to change minimum versions of deployment targets to get it to run

spraveenk91 commented 2 years ago

Try to move the RxDataSources.xcodeproj to your project.

This should be the accepted answer as it is working and it should be closed.

WingCH commented 1 year ago

It would be helpful if the README included instructions on how to run the example in Xcode 14.1. I followed the steps below and was able to successfully run the example.

  1. carthage update --use-xcframeworks
  2. modify ios Minimum Deployments from 8.0 to 9.0