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

Giving Error: "unrecognized selector sent to instance" if library added using "Tuist framework" #569

Closed
3 tasks
dheerajghub opened this issue May 24, 2024 · 1 comment

Comments

@dheerajghub
Copy link

Description

I'm using a Tuist framework to modularize my Swift project code, and I've found that even though I've been able to add the skeleton view properly and even able to access its properties and methods, however on runtime it crashes and throws an error.

What type of issue is this? (place an x in one of the [ ])

  • [x ] bug
  • enhancement (feature request)
  • [ x] question
  • documentation related
  • discussion

Requirements (place an x in each of the [ ])

  • [x ] I've read and understood the Contributing guidelines and have done my best effort to follow them.
  • [ x] I've read and agree to the Code of Conduct.
  • [x ] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report

Filling out the following details about bugs will help us solve your issue sooner.

SkeletonView Environment:

SkeletonView version: 1.31.0
Xcode version: 15.0
Swift version: 5.9

Steps to reproduce:

Please replace this with the steps to reproduce the behavior.

  1. added Skeleton view as package dependency using Tuist framework
  2. I've create this title label to which I've added isSkeletonable property and set it to true
let titleLabel: UILabel = {
    let label = UILabel()
    label.translatesAutoresizingMaskIntoConstraints = false
    label.text = "Title"
    label.isSkeletonable = true
    return label
}()
  1. And in viewDidAppear I've added this code:
override func viewDidAppear(_ animated: Bool) {
    titleLabel.showAnimatedSkeleton(usingColor: .red)
    DispatchQueue.main.asyncAfter(deadline: .now() + 5) {
        self.titleLabel.stopSkeletonAnimation()
        self.titleLabel.hideSkeleton(transition: .crossDissolve(0.25))
    }
}

Expected result:

now expected behavior is it should show the skeleton and hide it after 5sec (added delay for testing)
NOTE: this works fine if I add SkeletonView as a package dependency separately, not using Tuist

Actual result:

But it is throwing an error attached to the image below

Attachments:

Screenshot 2024-05-24 at 9 28 42 AM
@dheerajghub
Copy link
Author

dheerajghub commented May 26, 2024

Turns out, i have to configure my xcconfig file in Tuist, sorted now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant