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

Prevent NPEs when tab document is null #4596

Merged
merged 1 commit into from Aug 1, 2016

Conversation

Projects
None yet
2 participants
@JakubValtar
Contributor

JakubValtar commented Aug 1, 2016

JavaMode visits all tabs on sketch load to extract breakpoints, so doc
is always set (except when running Tweak mode; it sets docs to null to
force reload). Other modes have null docs until the tabs are visited
manually.

Fixes #4555

Prevent NPEs when tab document is null
JavaMode visits all tabs on sketch load to extract breakpoints, so doc
is always set (except when running Tweak mode; it sets docs to null to
force reload). Other modes have null docs until the tabs are visited
manually.

Fixes #4555

@benfry benfry merged commit 21900a8 into processing:master Aug 1, 2016

@benfry

This comment has been minimized.

Show comment
Hide comment
@benfry

benfry Aug 1, 2016

Member

Thanks; maybe we'll do a 3.1.3 with this.

Member

benfry commented Aug 1, 2016

Thanks; maybe we'll do a 3.1.3 with this.

@JakubValtar

This comment has been minimized.

Show comment
Hide comment
@JakubValtar

JakubValtar Aug 1, 2016

Contributor

There are two other places where null doc can be a problem. One is main error checker loop, it uses docs to get tab contents. It will spit an exception into console, but keep running. Other place is Rename, it will also spit an exception and do nothing. I need to revise this later and make sure there are some clear rules how document works.

Edit: this is only a problem in JavaMode, after running Tweak Mode

Contributor

JakubValtar commented Aug 1, 2016

There are two other places where null doc can be a problem. One is main error checker loop, it uses docs to get tab contents. It will spit an exception into console, but keep running. Other place is Rename, it will also spit an exception and do nothing. I need to revise this later and make sure there are some clear rules how document works.

Edit: this is only a problem in JavaMode, after running Tweak Mode

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment