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.
This issue occurs when using twig blocks and having the twig plugin activated (default). # Scenario 1 - IDE freezes on save Reproduce: 1) create new PHP project 2) add new "Twig HTML File" 3) enter the following content into twig file {% block content %}test{% endblock %} (or the sample from http://twig.sensiolabs.org/doc/tags/extends.html) 4) save file -> IDE freezes # Scenario 2 - endless background scanning, unable to save edited files Reproduce: 1) Disable Twig Plugin (and restart IDE) 2) Do the same as in scenario 1 3) Enable Twig Plugin (and restart IDE) -> never ending background scanning (indexer: text/x-twig>)
Sorry, can't reproduce. File is saved and no endless BG scan. Sorry. Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1 Java: 1.7.0_51; Java HotSpot(TM) 64-Bit Server VM 24.51-b03 Runtime: Java(TM) SE Runtime Environment 1.7.0_51-b13 System: Linux version 3.13.0-24-generic running on amd64; UTF-8; cs_CZ (nb)
Ou, sry...I got it. "Editor Parsing Loop (201403101706)" daemon prio=10 tid=0x00007f65d42b0000 nid=0xd38 runnable [0x00007f65e2991000] java.lang.Thread.State: RUNNABLE at org.netbeans.modules.php.twig.editor.parsing.TwigParser.parse(TwigParser.java:179) at org.netbeans.modules.parsing.impl.TaskProcessor.callParse(TaskProcessor.java:605) at org.netbeans.modules.parsing.impl.SourceCache.getResult(SourceCache.java:245) at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:727) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1423) at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)
Observation: Freeze on save does not occur if Twig plugin is activated and the settings in Tools->Options->Editor->On Save for Language Twig* are set to 'None' Both scenarios and avove tested with Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1 Java: 1.7.0_15; Java HotSpot(TM) 64-Bit Server VM 23.7-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_15-b03 System: Windows 7 version 6.1 running on amd64; Cp1252; de_DE (nb) and Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1 Java: 1.7.0_55; Java HotSpot(TM) 64-Bit Server VM 24.55-b03 Runtime: Java(TM) SE Runtime Environment 1.7.0_55-b13 System: Linux version 3.2.0-4-amd64 running on amd64; UTF-8; en_US (nb) Thanks for looking into it!
Can you test it in the dev [1] build? I'm not able to reproduce that there. Try clean install please (no imported old settings). [1] http://bits.netbeans.org/download/trunk/nightly/latest/
Created attachment 147027 [details] project that causes endless background scanning if opend issue caused by content of newTwigTemplate.html.twig
Created attachment 147028 [details] java tacktrace(?) from cancelling background scanning
Issues from both scenarios remain. Product Version: NetBeans IDE Dev (Build 201404300001) Java: 1.7.0_15; Java HotSpot(TM) 64-Bit Server VM 23.7-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_15-b03 System: Windows 7 version 6.1 running on amd64; Cp1252; de_DE (nb) Allthough I declined importing old settings, it seems that at least Tools->Options->Editor->On Save is shared system-wide. I removed %APPDATA%\Roaming\NetBeans\dev an retried, no change. If I can provide you with more logs or data, please tell me. I have attached - an exported mini-project that should trigger the issue - the java stacktrace(?) that was presented to me when I tried to cancel the scanning.
*** Bug 244220 has been marked as a duplicate of this bug. ***
Created attachment 147048 [details] Patched twig.jar Can you try to replace old twig.jar with this one? It should work. Thanks. You can find it in "NB instal dir/php/modules"
I replaced org-netbeans-modules-php-twig.jar as proposed, deactivated the old plugin and activated the new one -> both scenarios are working again. Consider this fixed, crongrats! Tested with Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1 Java: 1.7.0_55; Java HotSpot(TM) 64-Bit Server VM 24.55-b03 Runtime: Java(TM) SE Runtime Environment 1.7.0_55-b13 System: Linux version 3.2.0-4-amd64 running on amd64; UTF-8; en_US (nb) Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1 Java: 1.7.0_15; Java HotSpot(TM) 64-Bit Server VM 23.7-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_15-b03 System: Windows 7 version 6.1 running on amd64; Cp1252; de_DE (nb Product Version: NetBeans IDE Dev (Build 201404300001) Java: 1.7.0_15; Java HotSpot(TM) 64-Bit Server VM 23.7-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_15-b03 System: Windows 7 version 6.1 running on amd64; Cp1252; de_DE (nb)
Unfortunately the patched twig.jar didn't work for me. After the I opened the symfony project, the background scanner quickly moved to 100% and stayed there (also one of the CPU cores went to 100%). I had to close the project (in netbeans) then closed netbeans itself and kill the "orphaned" java process through htop. I finally was able to open the file though, by deleting the the *-twig.jar from /usr/local/netbeans-8.0/php/modules. This generates an exception in the logs, but the background scanner "completes" and I'm able to keep the project open.
Correction: where I said "file" in previous I meant "project". Just to confirm, after having successfully being able to open the project (by me previous method, of remove the twig.jar). I closed netbeans, replace the twig.jar, with the one attached here and re-opened Netbeans. Low and behold, the scanner locked (this time at 56%) and I had to go through the kill process.
pjacferreira: imho you did something wrong, it must work ;) Attach a thread dump...it's probably another issue. And attach a sample project, where the problem can be reproduced. Thanks.
Fixed in web-main #dbc9dbbf904b Can't reproduce any of reported issues. Reporters, please try the PHP daily build (at least #502) [1] and if the problem still occurs, attach a sample project where it can be reproduced and thread dump. Thanks. Lado, can you look at it a bit? Thanks. [1] http://deadlock.netbeans.org/job/PHP-build/502/
(In reply to pjacferreira from comment #12) > I closed netbeans, replace the twig.jar, with the one attached here and > re-opened Netbeans. @pjacferreira: You need to deactivate the Twig plugin via Tools->Options->Plugins, restart the IDE, activate the plugin and restart again to make NetBeans load the replaced one. Also check the version of the plugin, the new one is 1.20.
(In reply to elgrafico from comment #15) > (In reply to pjacferreira from comment #12) > > I closed netbeans, replace the twig.jar, with the one attached here and > > re-opened Netbeans. > > @pjacferreira: > You need to deactivate the Twig plugin via Tools->Options->Plugins, restart > the IDE, activate the plugin and restart again to make NetBeans load the > replaced one. > Also check the version of the plugin, the new one is 1.20. Okay, I think @elgrafico was correct and Netbeans was not assuming the new module. I moved the jar back into /usr/local/..../modules/php (global install directory) and removed my local user directory (~/.netbeans). When I restarted Netbeans, and re-opened the project the background scanner didn't lock up, and the TWIG editor/module is working. I verified the module version number in the logs, and it now shows up as 1.20 Thank you, This problem is also solved for Me.
Yap, worked for me, too! Thanks for the fix.
I've tried it twice (each time I opened 2 Symfony2 projects and the attached project here), seems OK to me. I'll wait with verification for trunk Dev build. Product Version: NetBeans IDE Dev (Build web-main-776-on-20140502) Java: 1.8.0_05; Java HotSpot(TM) 64-Bit Server VM 25.5-b02 Runtime: Java(TM) SE Runtime Environment 1.8.0_05-b13 System: Mac OS X version 10.9.2 running on x86_64; UTF-8; en_US (nb)
Created attachment 147077 [details] npss snapshot with the last dev version 201405010001 The dev version doesn't solve the problem, after remove user and cache dir, the scanning project task continue to stuck at 100%.
*** Bug 244246 has been marked as a duplicate of this bug. ***
Integrated into 'main-silver', will be available in build *201405030001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/dbc9dbbf904b User: Ondrej Brejla <obrejla@netbeans.org> Log: #244197 - Twig blocks prevent saving files / background scanning stalls
*** Bug 244277 has been marked as a duplicate of this bug. ***
*** Bug 234470 has been marked as a duplicate of this bug. ***
*** Bug 244288 has been marked as a duplicate of this bug. ***
Verified Product Version: NetBeans IDE Dev (Build 201405050001) Java: 1.8.0_05; Java HotSpot(TM) 64-Bit Server VM 25.5-b02 Runtime: Java(TM) SE Runtime Environment 1.8.0_05-b13 System: Mac OS X version 10.9.2 running on x86_64; UTF-8; en_US (nb)
Transplanted to release80 branch http://hg.netbeans.org/releases/rev/828b9fda2842 and spec version increased in commit http://hg.netbeans.org/releases/rev/5e72f2909ba1
Integrated into 'releases/release80', will be available in build *201405051654* or newer. Wait for official and publicly available build. Changeset: http://hg.netbeans.org/releases/rev/828b9fda2842 User: Ondrej Brejla <obrejla@netbeans.org> Log: #244197 - Twig blocks prevent saving files / background scanning stalls
Verified in patch1.1. I can no longer reproduce the scanning loop Product Version: NetBeans IDE 8.0 (Build 201403101706) Updates: NetBeans IDE is updated to version NetBeans 8.0 Patch 1.1 Java: 1.8.0_05; Java HotSpot(TM) Client VM 25.5-b02 Runtime: Java(TM) SE Runtime Environment 1.8.0_05-b13 System: Linux version 3.2.0-60-generic-pae running on i386; UTF-8; en_US (nb)
*** Bug 244331 has been marked as a duplicate of this bug. ***
*** Bug 244334 has been marked as a duplicate of this bug. ***
*** Bug 231579 has been marked as a duplicate of this bug. ***
*** Bug 244262 has been marked as a duplicate of this bug. ***
*** Bug 244488 has been marked as a duplicate of this bug. ***
*** Bug 244429 has been marked as a duplicate of this bug. ***
Hey, I don't use the TWIG plugin but the bug rise whatever on PHP project.