question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot redefine property: logout

See original GitHub issue

Goals

Run Realm

Expected Results

App loads

Actual Results

I get “Cannot redefine property: logout” red screen error

Steps to Reproduce

First comment out subscription line as stated in https://github.com/realm/realm-js/issues/1711 . Import realm from anywhere and run app

Code Sample

import Realm from "realm";

Version of Realm and Tooling

  • Realm JS SDK Version: ?

  • Node or React Native: ? “realm”: “^2.2.18”, “react”: “16.0.0-alpha.6”, “react-native”: “0.44.0”,

  • Client OS & Version: Any

  • Which debugger for React Native: standard

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

6reactions
tomsjansonscommented, Apr 22, 2018

I’ve done a little workaround that seems to be working for now. But i’m sure a proper fix would be required. The below changes are in \node_modules\realm\lib\extensions.js:132:15 Basically check if property logout already exists and if it does, remove it from the list of properties to be defined image

4reactions
tomsjansonscommented, Apr 25, 2018

@macceth it is not perfect, you will get an error when stopping remote debugging unfortunately. I will try to address this issue when i get a chance.

Read more comments on GitHub >

github_iconTop Results From Across the Web

spyOn: Cannot redefine property #26 - aelbore/esbuild-jest
While mocks are working great for me, I'm having some trouble with spies. I created this code. import { moduleDependency } from "....
Read more >
jest spyOn not working on index file, cannot redefine property
I have UserContext and a hook useUser exported from src/app/context/user-context.tsx . Additionally I have an index.tsx file in src/app/context ...
Read more >
Error “Cannot redefine non-configurable property 'location'” on ...
While googling I found that the now the window.location is readonly and not writable, so it cannot be overridden. For reference, it can...
Read more >
Guides | ServiceNow Developers
Q: With translations set, when I run snc ui-component develop , I see the following error in my browser: Uncaught TypeError: Cannot redefine...
Read more >
Need help with routes Laravel & vueJs 2.: Uncaught TypeError ...
Uncaught TypeError : Cannot redefine property: $router ... component: settings }, { path: '/logout', component: logoutScreen } ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found