René's URL Explorer Experiment


Title: fix(runtime): keep a constructed instance's recorded class by edusperoni · Pull Request #2132 · NativeScript/android · GitHub

Open Graph Title: fix(runtime): keep a constructed instance's recorded class by edusperoni · Pull Request #2132 · NativeScript/android

X Title: fix(runtime): keep a constructed instance's recorded class by edusperoni · Pull Request #2132 · NativeScript/android

Description: Description Runtime::CallJSMethodNative, on the Java constructor's call into JS (isConstructor), replaced the class recorded for the instance with env.GetObjectClass(obj). obj is the receiver of the native method, the com.tns.Runtime object, not the instance, and the result is a JNI local reference that is freed when the native call returns. So for a JS-extended instance whose constructor calls into JS, the recorded class became a dead local ref to com.tns.Runtime's class. On main only one place reads it: the "Failed to get Java object by ID. id=…, class=…" error, which therefore named com.tns.Runtime or read a freed reference. Registration (CallbackHandlers::RegisterInstance, Runtime::CreateJSInstanceNative) already records the instance's real class as a cached global ref, so the overwrite is simply removed. Found while porting the canary wrapper lifetime mode (#2127), which keeps the recorded class. Testing Full suite on an arm64 API 36.1 emulator: 1773 specs, 0 failures. No spec: the only observable effect on main is the class name in that error message, reached when a Java object lookup fails. Summary by CodeRabbit Behavior Changes During JavaScript constructor calls, the linked Java instance’s class is no longer updated based on the supplied object. This may affect how the instance is associated with its Java class after construction.

Open Graph Description: Description Runtime::CallJSMethodNative, on the Java constructor's call into JS (isConstructor), replaced the class recorded for the instance with env.GetObjectClass(obj). obj is the receiver o...

X Description: Description Runtime::CallJSMethodNative, on the Java constructor's call into JS (isConstructor), replaced the class recorded for the instance with env.GetObjectClass(obj). obj is the receiv...

Opengraph URL: https://github.com/NativeScript/android/pull/2132

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:ddc42491-c183-9efa-34da-9bb3ef889fb9
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idB824:DB09F:13A66AD:1913FBD:6B012B37
html-safe-nonced7ab90ef5dd010dec4eef5435e699ce36f563d084b1ca4e7ea6d0901150d6c08
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCODI0OkRCMDlGOjEzQTY2QUQ6MTkxM0ZCRDo2QjAxMkIzNyIsInZpc2l0b3JfaWQiOiI0OTk3ODM5Mzk5MTM3NTU0NDciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac10dc991cfae00ab56af41c9d194f8a708eaa40792b6eed40204c61d087441055
hovercard-subject-tagpull_request:5419389578
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/NativeScript/android/pull/2132/files
twitter:imagehttps://avatars.githubusercontent.com/u/4061767?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/4061767?s=400&v=4
og:image:altDescription Runtime::CallJSMethodNative, on the Java constructor's call into JS (isConstructor), replaced the class recorded for the instance with env.GetObjectClass(obj). obj is the receiver o...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/NativeScript/android git https://github.com/NativeScript/android.git
octolytics-dimension-user_id7392261
octolytics-dimension-user_loginNativeScript
octolytics-dimension-repository_id29137950
octolytics-dimension-repository_nwoNativeScript/android
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id29137950
octolytics-dimension-repository_network_root_nwoNativeScript/android
turbo-body-classeslogged-out env-production page-responsive
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/NativeScript/android/pull/2132/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FNativeScript%2Fandroid%2Fpull%2F2132%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FNativeScript%2Fandroid%2Fpull%2F2132%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=NativeScript%2Fandroid
Reloadhttps://github.com/NativeScript/android/pull/2132/files
Reloadhttps://github.com/NativeScript/android/pull/2132/files
Reloadhttps://github.com/NativeScript/android/pull/2132/files
NativeScripthttps://github.com/NativeScript
androidhttps://github.com/NativeScript/android
Codehttps://github.com/NativeScript/android
Issues106 (106)https://github.com/NativeScript/android/issues
Pull requests24 (24)https://github.com/NativeScript/android/pulls
Actionshttps://github.com/NativeScript/android/actions
Projectshttps://github.com/NativeScript/android/projects
Wikihttps://github.com/NativeScript/android/wiki
Security and qualityhttps://github.com/NativeScript/android/security
Insightshttps://github.com/NativeScript/android/insights
Sign up for GitHub https://github.com/signup?return_to=%2FNativeScript%2Fandroid%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FNativeScript%2Fandroid%2Fissues%2Fnew%2Fchoose
edusperonihttps://github.com/edusperoni
mainhttps://github.com/NativeScript/android/tree/main
fix/constructor-class-refhttps://github.com/NativeScript/android/tree/fix/constructor-class-ref
Conversation 1 https://github.com/NativeScript/android/pull/2132
Commits 1 https://github.com/NativeScript/android/pull/2132/commits
Checks 8 https://github.com/NativeScript/android/pull/2132/checks
Files changed 1 https://github.com/NativeScript/android/pull/2132/files
fix(runtime): keep a constructed instance's recorded class https://github.com/NativeScript/android/pull/2132/files#top
Show all changes 1 commit https://github.com/NativeScript/android/pull/2132/files
3f56f9c fix(runtime): keep a constructed instance's recorded class edusperoni Nov 20, 2026 https://github.com/NativeScript/android/pull/2132/commits/3f56f9cf164eda27fed683131f6fc0a9e0290812
Clear filters https://github.com/NativeScript/android/pull/2132/files
Please reload this pagehttps://github.com/NativeScript/android/pull/2132/files
Please reload this pagehttps://github.com/NativeScript/android/pull/2132/files
test-app/runtime/src/main/cpp/Runtime.cpphttps://github.com/NativeScript/android/pull/2132/files#diff-b9490640f5d26f7cd6b9a176a2142b8e985a6aac9e2d64287de37fc694e80cc3
View file https://github.com/NativeScript/android/blob/3f56f9cf164eda27fed683131f6fc0a9e0290812/test-app/runtime/src/main/cpp/Runtime.cpp
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/NativeScript/android/pull/2132/{{ revealButtonHref }}
https://github.com/NativeScript/android/pull/2132/files#diff-b9490640f5d26f7cd6b9a176a2142b8e985a6aac9e2d64287de37fc694e80cc3
https://github.com/NativeScript/android/pull/2132/files#diff-b9490640f5d26f7cd6b9a176a2142b8e985a6aac9e2d64287de37fc694e80cc3
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.