Skip to content
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

Infinite loop in v9.21.1 #1375

Closed
alxbradley opened this issue May 17, 2019 · 3 comments · Fixed by #1382
Closed

Infinite loop in v9.21.1 #1375

alxbradley opened this issue May 17, 2019 · 3 comments · Fixed by #1382
Assignees
Labels

Comments

@alxbradley
Copy link

Bug:

We're running into an infinite loop when a column has 0 width. The browser becomes unusable.

After digging a bit deeper I found that the it's related to the following PR:
#1312

@trxcllnt @wuweiweiwu

In the following line nearestCellIndex is always greater than this._lastMeasuredIndex:
https://github.com/trxcllnt/react-virtualized/blob/8fcc7031cbde72495e5fe3415e54c974b8d29880/source/Grid/utils/CellSizeAndPositionManager.js#L248

It seems that the problem is inside of the linear-vector-layout library function indexOfInternal or the handling of it's return index.

react-virtualized-infinite-loop

Bug seen in the following environment:

Browser Chrome, Firefox
OS Windows
React 16.6.3
React DOM 16.6.3
react-virtualized 9.21.1

Our Fix

Revert react-virtualized back to 9.21.0

@trxcllnt
Copy link
Contributor

ooh yikes, my apologies @alxbradley. @wuweiweiwu do you think we could revert my PR until I have time to finish cleaning the library up and adding more tests? I'm about two thirds of the way done, but I'm slammed with other stuff at the moment.

@wuweiweiwu wuweiweiwu self-assigned this May 22, 2019
@wuweiweiwu
Copy link
Contributor

@trxcllnt @alxbradley will update thread when done

@trxcllnt
Copy link
Contributor

@wuweiweiwu alternatively, I could add guards to disallow 0-sized elements for now.

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

Successfully merging a pull request may close this issue.

3 participants