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

Deprecated API used in the ErrorActivity is crashing the app (when latest support library is used) #1494

Closed
NickIliev opened this issue Oct 7, 2019 · 0 comments

Comments

@NickIliev
Copy link

Environment
Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

  • CLI: latest
  • Cross-platform modules: latest
  • Android Runtime: latest

Describe the bug

Deprecated API is crashing the app with:

platforms/android/app/src/debug/java/com/tns/ErrorReport.java:294: error: incompatible types: ErrorReport cannot be converted to BaseOnTabSelectedListener
tabLayout.setOnTabSelectedListener(this);

As a workaround, add an after-prepare hook to modify ErrorReport.java, line 294

from

tabLayout.setOnTabSelectedListener(this);

to

tabLayout.addOnTabSelectedListener(this);

To Reproduce

Use the latest version of the support library in your project.

Additional context

Reported via t.1433066

darind added a commit that referenced this issue Oct 7, 2019
- Update to androidx.appcompat 1.1.0
- Replace setOnTabSelectedListener with addOnTabSelectedListener
darind added a commit that referenced this issue Oct 9, 2019
- Replace setOnTabSelectedListener with addOnTabSelectedListener
darind added a commit that referenced this issue Oct 9, 2019
Deprecated API use in ErrorReport.java (#1494)
@vtrifonov vtrifonov added this to the 6.2.0 milestone Oct 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants