Skip to content

Remove the log, was causing a crash. #1206

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

Merged
merged 1 commit into from
Sep 1, 2023
Merged

Conversation

bmarty
Copy link
Member

@bmarty bmarty commented Aug 31, 2023

kotlin.reflect.jvm.internal.KotlinReflectionInternalError: Function 'handleEvents' (JVM signature: present$handleEvents(Landroidx/compose/runtime/MutableState;Lkotlin/jvm/internal/Ref$ObjectRef;Lio/element/android/libraries/permissions/api/PermissionsEvents;)V) not resolved in class kotlin.jvm.internal.Intrinsics$Kotlin: no members found
at kotlin.reflect.jvm.internal.KDeclarationContainerImpl.findFunctionDescriptor(KDeclarationContainerImpl.kt:131)
at kotlin.reflect.jvm.internal.KFunctionImpl$descriptor$2.invoke(KFunctionImpl.kt:56)
at kotlin.reflect.jvm.internal.KFunctionImpl$descriptor$2.invoke(KFunctionImpl.kt:55)
at kotlin.reflect.jvm.internal.ReflectProperties$LazySoftVal.invoke(ReflectProperties.java:93)
at kotlin.reflect.jvm.internal.ReflectProperties$Val.getValue(ReflectProperties.java:32)
at kotlin.reflect.jvm.internal.KFunctionImpl.getDescriptor(KFunctionImpl.kt:55)
at kotlin.reflect.jvm.internal.KFunctionImpl.toString(KFunctionImpl.kt:185)
at kotlin.jvm.internal.FunctionReference.toString(FunctionReference.java:130)
at java.lang.String.valueOf(String.java:4092)
at java.lang.StringBuilder.append(StringBuilder.java:179)
at io.element.android.libraries.permissions.api.PermissionsState.toString
at java.lang.String.valueOf(String.java:4092)
at java.lang.StringBuilder.append(StringBuilder.java:179)
at io.element.android.libraries.permissions.impl.DefaultPermissionsPresenter.present(DefaultPermissionsPresenter.kt:128)

Type of change

  • Feature
  • Bugfix
  • Technical
  • Other :

Content

Fix crash https://sentry.tools.element.io/organizations/element/issues/85090

Not sure how the crash is occurring only now, but no need to investigate more I guess.

Motivation and context

Stable app.

Screenshots / GIFs

Tests

  • Step 1
  • Step 2
  • Step ...

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

kotlin.reflect.jvm.internal.KotlinReflectionInternalError: Function 'handleEvents' (JVM signature: present$handleEvents(Landroidx/compose/runtime/MutableState;Lkotlin/jvm/internal/Ref$ObjectRef;Lio/element/android/libraries/permissions/api/PermissionsEvents;)V) not resolved in class kotlin.jvm.internal.Intrinsics$Kotlin: no members found
    at kotlin.reflect.jvm.internal.KDeclarationContainerImpl.findFunctionDescriptor(KDeclarationContainerImpl.kt:131)
    at kotlin.reflect.jvm.internal.KFunctionImpl$descriptor$2.invoke(KFunctionImpl.kt:56)
    at kotlin.reflect.jvm.internal.KFunctionImpl$descriptor$2.invoke(KFunctionImpl.kt:55)
    at kotlin.reflect.jvm.internal.ReflectProperties$LazySoftVal.invoke(ReflectProperties.java:93)
    at kotlin.reflect.jvm.internal.ReflectProperties$Val.getValue(ReflectProperties.java:32)
    at kotlin.reflect.jvm.internal.KFunctionImpl.getDescriptor(KFunctionImpl.kt:55)
    at kotlin.reflect.jvm.internal.KFunctionImpl.toString(KFunctionImpl.kt:185)
    at kotlin.jvm.internal.FunctionReference.toString(FunctionReference.java:130)
    at java.lang.String.valueOf(String.java:4092)
    at java.lang.StringBuilder.append(StringBuilder.java:179)
    at io.element.android.libraries.permissions.api.PermissionsState.toString
    at java.lang.String.valueOf(String.java:4092)
    at java.lang.StringBuilder.append(StringBuilder.java:179)
    at io.element.android.libraries.permissions.impl.DefaultPermissionsPresenter.present(DefaultPermissionsPresenter.kt:128)
@bmarty bmarty requested a review from a team as a code owner August 31, 2023 15:42
@bmarty bmarty requested review from jmartinesp and removed request for a team August 31, 2023 15:42
@github-actions
Copy link
Contributor

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/8aW7Zp

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@jmartinesp
Copy link
Member

I can approve if it fixes the issue, but in my case I've seen this error plenty of times and most of them there wasn't a log involved. For some reason, the *State data classes sometimes crash when the eventSink is a function reference instead of a eventSink = { handleEvents(it) }.

Copy link
Member

@jmartinesp jmartinesp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but I think we should try to investigate why this is happening.

@codecov
Copy link

codecov bot commented Aug 31, 2023

Codecov Report

Patch coverage has no change and project coverage change: -0.01% ⚠️

Comparison is base (a96baf9) 57.44% compared to head (d776000) 57.44%.
Report is 2 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1206      +/-   ##
===========================================
- Coverage    57.44%   57.44%   -0.01%     
===========================================
  Files         1045     1045              
  Lines        27295    27292       -3     
  Branches      5617     5617              
===========================================
- Hits         15680    15677       -3     
  Misses        9185     9185              
  Partials      2430     2430              
Files Changed Coverage Δ
...es/permissions/impl/DefaultPermissionsPresenter.kt 90.69% <ø> (-0.61%) ⬇️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bmarty
Copy link
Member Author

bmarty commented Sep 1, 2023

Yes, noted. Let's merge this since this log was quite useless anyway.

@bmarty bmarty merged commit da07701 into develop Sep 1, 2023
@bmarty bmarty deleted the feature/bma/fixCrashToString branch September 1, 2023 07:45
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

Successfully merging this pull request may close these issues.

2 participants