This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 198307 - UserTask is not run in some circumstances.
Summary: UserTask is not run in some circumstances.
Alias: None
Product: editor
Classification: Unclassified
Component: Parsing & Indexing (show other bugs)
Version: 7.0
Hardware: PC Linux
: P1 normal (vote)
Assignee: Tomas Zezula
Depends on:
Blocks: 197887
  Show dependency tree
Reported: 2011-05-04 09:16 UTC by Petr Pisl
Modified: 2011-05-20 07:58 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:

PHPCTF.diff (3.66 KB, patch)
2011-05-04 11:16 UTC, Tomas Zezula
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Petr Pisl 2011-05-04 09:16:14 UTC
PHP templates are applied according the context. For this reason the PHPCodeTemplateFilter should have uptodate parse result and run an UserTask to find the context. The PHPCodeTemplateFilter should wait for the result of UserTask, but the user task is not returned due to a deadlock in Parsing API.
Comment 1 Tomas Zezula 2011-05-04 09:51:16 UTC
The reason is that PHP submits twice the UT (PHPCodeTeplateFilter) into runWhenScanFInished one by CC second by teb expansion. The CC thread locked the infrastructure and wait until the rWSF is done but it cannot complete as it waits on the end of CC.
Comment 2 Tomas Zezula 2011-05-04 11:13:16 UTC
Fixed jet-main
Comment 3 Tomas Zezula 2011-05-04 11:15:48 UTC
Don't forgot to fix the PHPCodeTemplateFilter to use the Future<Future<Void>> :-)
See attached diff, only the future.get(),get() should be changed to:
try {
} catch (TimeoutException te) {
Comment 4 Tomas Zezula 2011-05-04 11:16:17 UTC
Created attachment 108099 [details]
Comment 5 Petr Pisl 2011-05-04 12:58:27 UTC
Thanks to Tomas for the quick fix.
Comment 6 Tomas Zezula 2011-05-04 13:08:52 UTC
Comment 7 Marian Mirilovic 2011-05-04 15:13:07 UTC
This issue is connected with issue 197887 (P1) ... so Petr, would you mind to fix it into 7.0 Patch 1 ?
Comment 8 Petr Pisl 2011-05-04 15:32:51 UTC
Yes, it would be good to have it in the patch. Without this, the fix for issue #197887 doesn't work.
Comment 9 Tomas Zezula 2011-05-04 17:02:47 UTC
Unfortunately the fix is even more complicated.
Some refactoring unit tests are failing as they expect that parseWhenScanFinished do ordering, this is not stated in the javadoc, but semantic of the method does it. So there can be clients which relay on it as the refactoring unit test.
I have changed the fix.
Comment 10 Tomas Zezula 2011-05-04 17:08:01 UTC
Fixed jet-main
Comment 11 Quality Engineering 2011-05-05 06:13:18 UTC
Integrated into 'main-golden', will be available in build *201105050000* on (upload may still be in progress)
User: Tomas Zezula <>
Log: #198307:UserTask is not run in some circumstances
Comment 12 Tomas Zezula 2011-05-16 16:35:05 UTC
For the list of included fixed bugs please check