Title: Unexpected error "Cannot read private member #availableParallelism from an object whose class did not declare it" · Issue #63513 · nodejs/node · GitHub
Open Graph Title: Unexpected error "Cannot read private member #availableParallelism from an object whose class did not declare it" · Issue #63513 · nodejs/node
X Title: Unexpected error "Cannot read private member #availableParallelism from an object whose class did not declare it" · Issue #63513 · nodejs/node
Description: Version v26.0.0 Platform Linux eric-cornelissen-Latitude-7640 6.17.0-29-generic #29~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon May 11 10:30:58 UTC 2 x86_64 x86_64 x86_64 GNU/Linux Subsystem node:internal/navigator What steps will reproduce t...
Open Graph Description: Version v26.0.0 Platform Linux eric-cornelissen-Latitude-7640 6.17.0-29-generic #29~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon May 11 10:30:58 UTC 2 x86_64 x86_64 x86_64 GNU/Linux Subsystem node:intern...
X Description: Version v26.0.0 Platform Linux eric-cornelissen-Latitude-7640 6.17.0-29-generic #29~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon May 11 10:30:58 UTC 2 x86_64 x86_64 x86_64 GNU/Linux Subsystem node:intern...
Opengraph URL: https://github.com/nodejs/node/issues/63513
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Unexpected error \"Cannot read private member #availableParallelism from an object whose class did not declare it\"","articleBody":"### Version\n\nv26.0.0\n\n### Platform\n\n```text\nLinux eric-cornelissen-Latitude-7640 6.17.0-29-generic #29~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon May 11 10:30:58 UTC 2 x86_64 x86_64 x86_64 GNU/Linux\n```\n\n### Subsystem\n\nnode:internal/navigator\n\n### What steps will reproduce the bug?\n\nFor the error mentioned in the title:\n\n```\nnode -e 'globalThis.Navigator.prototype.hardwareConcurrency'\n```\n\nThis applies to other getters of this object too, namely:\n\n```\nnode -e 'globalThis.Navigator.prototype.locks'\nnode -e 'globalThis.Navigator.prototype.languages'\nnode -e 'globalThis.Navigator.prototype.userAgent'\nnode -e 'globalThis.Navigator.prototype.platform'\n```\n\n\n### How often does it reproduce? Is there a required condition?\n\nAlways\n\n### What is the expected behavior? Why is that the expected behavior?\n\nNot an internal error about the implementation of the `Navigator`.\n\nBased on the behavior of browsers[^1], a `TypeError` is still expected, but instead something like:\n\n```\nUncaught TypeError: 'get hardwareConcurrency' called on an object that does not implement interface Navigator.\n```\n\n\n[^1]: I only tried Firefox.\n\n### What do you see instead?\n\nFor `hardwareConcurrency`:\n\n```\nnode:internal/navigator:100\n this.#availableParallelism ??= getAvailableParallelism();\n ^\n\nTypeError: Cannot read private member #availableParallelism from an object whose class did not declare it\n at get hardwareConcurrency (node:internal/navigator:100:9)\n at Reflect.get (\u003canonymous\u003e)\n at [eval]:1:9\n at runScriptInThisContext (node:internal/vm:219:10)\n at node:internal/process/execution:483:12\n at [eval]-wrapper:6:24\n at runScriptInContext (node:internal/process/execution:481:60)\n at evalFunction (node:internal/process/execution:315:30)\n at evalTypeScript (node:internal/process/execution:327:3)\n at node:internal/main/eval_string:71:3\n```\n\nFor the other properties a similar error about using a private member.\n\n### Additional information\n\n1. I tested the `hardwareConcurrency` property on older versions too and found the report applies to v24.15.0 and v22.0.0 too, in v20.20.2 the Navigate global did not yet exist.\n\n2. Interestingly the following property does not result in an error\n\n ```\n node -e 'console.log(globalThis.Navigator.prototype.language)'\n ```\n\n This might be a bug as well given that in browsers the only properties that can be accessed on this object are functions (whereas this is also a getter), which you can verify using:\n\n ```js\n for (const key of Object.keys(Navigator.prototype)) { try { Navigator.prototype[key]; console.log(\"no error for\", key, typeof Navigator.prototype[key]) } catch { } }\n ``` ","author":{"url":"https://github.com/ericcornelissen","@type":"Person","name":"ericcornelissen"},"datePublished":"2026-05-23T14:00:21.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/63513/node/issues/63513"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:996535c8-728f-e74d-12a2-3042f11504e5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8C64:1A0CEA:1BB2167:26DDBC4:6A4CC627 |
| html-safe-nonce | cd2998f1222812cfb58afddfc8d13f0fb59d1b506dabf45abb4bf0f92122fb04 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4QzY0OjFBMENFQToxQkIyMTY3OjI2RERCQzQ6NkE0Q0M2MjciLCJ2aXNpdG9yX2lkIjoiNjEzMzQ0MzIzMTU0NTYwNzcxOSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | ddfd79168d08cae6337924aaad76aa9fc14982ce2dd2cd11951f462f86d6fc48 |
| hovercard-subject-tag | issue:4508405789 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/63513/issue_layout |
| twitter:image | https://opengraph.githubassets.com/382edf176ca5e6449424d5f5b843a5e888daa712c5d21d3ee1799ccb1db6cdf7/nodejs/node/issues/63513 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/382edf176ca5e6449424d5f5b843a5e888daa712c5d21d3ee1799ccb1db6cdf7/nodejs/node/issues/63513 |
| og:image:alt | Version v26.0.0 Platform Linux eric-cornelissen-Latitude-7640 6.17.0-29-generic #29~24.04.1-Ubuntu SMP PREEMPT_DYNAMIC Mon May 11 10:30:58 UTC 2 x86_64 x86_64 x86_64 GNU/Linux Subsystem node:intern... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ericcornelissen |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | d0da0eb92994395299ed4450bf67b0373005be36 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width