Skip to content
This repository has been archived by the owner on Dec 19, 2022. It is now read-only.

"Locals" acts weird #145

Open
alexandernst opened this issue Feb 25, 2016 · 7 comments
Open

"Locals" acts weird #145

alexandernst opened this issue Feb 25, 2016 · 7 comments
Labels

Comments

@alexandernst
Copy link

It seems "Locals" is not emptied/filled with the variables from the current scope. Sometimes some variables are missing, sometimes variables get duplicated.

This is easily reproducible with randomly opening and closing the "Locals" element before/after stepping into a new context.

@codecontemplator
Copy link
Collaborator

I failed to reproduce this. Are there any errors logged to the console output (ctrl+alt+i to show) in atom?

@tokidoki11
Copy link

tokidoki11 commented Jul 24, 2016

screen shot 2016-07-25 at 1 51 37 am

When the string is long, I cannot see the value...
Anyway, The panel cannot be dragged, can it?


oh it can be dragged, but weird behaviour is happening..

@ztolley
Copy link

ztolley commented Aug 1, 2016

Whenever I try to use it the locals dropdown is empty so I have to add everything I want to watch.

@thomassuckow
Copy link

thomassuckow commented Nov 3, 2016

I also see it having the wrong value for the local variable

@Redsandro
Copy link

Redsandro commented Nov 3, 2016

@alexandernst said:

Sometimes some variables are missing, sometimes variables get duplicated.

I can confirm this. I sometimes see double variables or occasionally a value from the previous/next variable. I thought I was going crazy. Often I set a variables in watches because they are not showing in locals or just to be sure.

E.g. loops like

for (let i = 0, keys = Object.keys(obj), len = keys.length; i < len; i++)

There is no i, keys, len etc in the local variables.

Check this scope for example: Local is not local, watch is local:

image

@codecontemplator
Copy link
Collaborator

codecontemplator commented Nov 8, 2016

It seems like mercury hg.array suffers from some kind of disease...

Raynos/mercury#177

It could be worth trying to swap out the hg.array in the treeview in favor of the, not so convenient (in this case), hg.varhash.

@Redsandro Are you in a position to provide any reproduction steps for this bug?

@Redsandro
Copy link

It's difficult. I encounter this now and again with big code. When I try to simplify this, into reproduction code, it starts working. :(

The problem with the hidden vars is easier. You got that one confirmed, or do you prefer reproduction code for that too?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

6 participants