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 225908 - Recursive error icon in project tree for HTML files
Summary: Recursive error icon in project tree for HTML files
Status: RESOLVED DUPLICATE of bug 233066
Alias: None
Product: javascript
Classification: Unclassified
Component: Editor (show other bugs)
Version: 7.3
Hardware: All All
: P3 normal with 7 votes (vote)
Assignee: Petr Hejl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-02-08 17:28 UTC by daorus
Modified: 2013-07-19 12:36 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Annoying error motivation killing icon (17.14 KB, image/png)
2013-02-08 17:28 UTC, daorus
Details
Mix of HTML + PHP + Javascript (68.16 KB, image/png)
2013-04-03 04:32 UTC, eddyvlad
Details
A valid JSON file (27.63 KB, image/png)
2013-04-03 04:34 UTC, eddyvlad
Details
Markdown file (96.68 KB, image/png)
2013-04-03 04:34 UTC, eddyvlad
Details

Note You need to log in before you can comment on or make changes to this bug.
Description daorus 2013-02-08 17:28:02 UTC
Created attachment 131168 [details]
Annoying error motivation killing icon

I use Netbeans 7.3 Beta 2 and there is no such a problem.
The problem appead in 7.3 RC2

In all *.html files in our project 7.3 RC found javascript errors and now marked all the files with error icon, and moreover, this icon is recursivly upstreamed up and up and mark the whole project as errored! We found no way to disable this error icons or disable error checks at all.

I repeat - there is no such a problem in 7.3 Beta 2
Comment 1 Ondrej Brejla 2013-02-08 17:31:31 UTC
I think that it's JS issue. But you should provide us that HTML files, which cause that errors for further evaluation. Then simply reopen. Thanks.
Comment 2 daorus 2013-02-08 18:14:08 UTC
it is useless to provide you with these files, cause they 100% contain error for a simple reason - they are templated

e.g.

var list = [ ##IMAGE_LIST## ];

and this ##IMAGE_LIST## is filled by php script

I wonder why beta works with no marks and release works with marks??
Comment 3 Petr Pisl 2013-02-11 13:18:04 UTC
I expect that the html code contains something like:

<script type="text/javascript">
    var list = [ ##IMAGE_LIST## ];
</script>

If it's true, then the problem is that the javascript parser reports error here, because it doesn't understand it. Petr is working on the solution, which switch off the reporting in the embedding cases.
Comment 4 Petr Hejl 2013-02-11 13:51:27 UTC
The problem is that it is a real error. You have plain HTML file and there is JS containing invalid syntax. In other words it is not a HTML file.

Otherwise the error checking would have to be completely disabled.
Comment 5 daorus 2013-02-11 16:47:44 UTC
> which switch off the reporting in the embedding cases

that is not help to solve the problem, cause we have html triks as well

e.g.

<table><tr>##TOP_MENU_CELLS##</tr></table>

> In other words it is not a HTML file.

we do need html, javascript and other parsers and color syntax as usual in these files

moreover, it is OK that it shows errors
that is ok!!

the problem is that it marks the file with error icon and this icon recursivly repeats up till the project self and therefore all our projects now are marked as errored

> Otherwise the error checking would have to be completely disabled.

No, no, no, no!! We need to disable small error red subicons in project tree and let everything stay the same.

* * * * * * * * * * * * * * * * * * * * * * * * * *

I remind you once more, in 7.3 Beta 2 everything is great. The problem in 7.3 RC2 only.
Comment 6 daorus 2013-02-11 16:50:02 UTC
See the image I enclosed to this bug and you get the problem not in error checking, but in project tree.
Comment 7 Petr Hejl 2013-02-11 21:00:33 UTC
(In reply to comment #5)
> * * * * * * * * * * * * * * * * * * * * * * * * * *
> 
> I remind you once more, in 7.3 Beta 2 everything is great. The problem in 7.3
> RC2 only.
Well the way it is in Beta 2 is a bug. Usually users do want to see if they have broken files in their project. Consider somebody really has syntax error in JS file he wants to know the project is broken.

So the problem imo is you want to disable it for your particular case where you _know_ and/or _suppose_ your files are ok. There is no such option now.
Comment 8 daorus 2013-02-12 05:33:15 UTC
> Well the way it is in Beta 2 is a bug.

No.
We used 7.0.1 for a long time and there was no such an icon.

> So the problem imo is you want to disable 
> it for your particular case where you
> _know_ and/or _suppose_ your files are ok

No, no, no no.
We do not want to disable cheking, we want to disable error icons;

> There is no such option now.

Option is to use 7.3 Beta 2
Comment 9 Petr Hejl 2013-02-12 09:29:51 UTC
(In reply to comment #8)
> > Well the way it is in Beta 2 is a bug.
> 
> No.
> We used 7.0.1 for a long time and there was no such an icon.
And that was bug as well.

> 
> > So the problem imo is you want to disable 
> > it for your particular case where you
> > _know_ and/or _suppose_ your files are ok
> 
> No, no, no no.
> We do not want to disable cheking, we want to disable error icons;
Yep that's what I'm saying:
So the problem imo is you want to disable it (error icons) for your particular case where you _know_ and/or _suppose_ your files are ok.

Others will report this a defect, because project won't be marked red when there are broken files.

> 
> > There is no such option now.
> 
> Option is to use 7.3 Beta 2
By option I meant configuration option.
Comment 10 daorus 2013-02-21 05:33:28 UTC
for those who wants mannually disable checking
there is a file in user dir (see the exact path in About dialog)
%netbeans_user_dir%/var/attributes.xml

<attributes version="1.0">
    <fileobject name="D:|projects|lazychicken|blanks|country.htm">
        <attr name="disable_error_checking" boolvalue="true"/>
    </fileobject>
    ...
</attributes>

So, remember, html error check disabling is not stored in the project, it is stored in the user dir folder for netbeans itself.
Comment 11 bftanase 2013-03-06 06:36:51 UTC
I think of better way of solving this is to provide some option of ignoring certain files/folders from JS error checking.

There are lots of third party libraries that have those JS "errors" and there's nothing a user can do about this.

Currently I have this issue with a Symfony 2 project (which BTW, the support for Symfony in NB rocks!) and there are lots of bundles in the vendors folder that have "errors".

I am aware there's an option of ignoring a folder completely but this has some unpleasant side effects, like auto-complete not working, and others.
Comment 12 bgunnink 2013-03-06 16:38:17 UTC
Whether a templating/view language embedded within javascript in an HTML/JSP/foo file is syntactically valid is irrelevant here.  The point is that the developer can know better than Netbeans what is and isn't valid (at least I do), and marking a file and/or the entire project as being in error is, at a minimum, counterproductive.

This behavior makes working with 7.3 incredibly frustrating, as I can't tell the "real" errors from these ersatz errors.
Comment 13 daorus 2013-03-06 16:52:58 UTC
bftanase and bgunnink,

thank you so much for moral support and understanding. I do share completly your feelings about this error icons and hope this "great feature" will be eliminated or at least parametalized in future releases.

For now our team is using NB 7.3 Beta 2 and there are no these pleasant error icons!
Comment 14 eddyvlad 2013-04-03 04:32:19 UTC
Created attachment 133269 [details]
Mix of HTML + PHP + Javascript
Comment 15 eddyvlad 2013-04-03 04:34:10 UTC
Created attachment 133270 [details]
A valid JSON file
Comment 16 eddyvlad 2013-04-03 04:34:31 UTC
Created attachment 133271 [details]
Markdown file
Comment 17 eddyvlad 2013-04-03 04:51:36 UTC
Of course the best approach is to provide the option to disable this feature or at least an ignore option. 

It may be just icons but it can really affect productivity due to confusion and doubts.
Comment 18 rodcdv 2013-06-10 13:45:22 UTC
Please give us the right to choose if it's a javascript error or not, it kills productivity to see all the project with the error icon just because Netbeans "thinks" that a .js file contains errors.
Comment 19 qazzi76 2013-07-04 11:44:36 UTC
I am currently suffering countless lost hours of production due to this bug as well...

Seriously... We need an option to disable error checking on certain files as the false positives are deeply frustrating...

I have filed 2 bugs that are somewhat related... (232196 and 232197)

Just need an option to disable those red exclamation marks for certain files.
Comment 20 Petr Hejl 2013-07-19 12:36:20 UTC

*** This bug has been marked as a duplicate of bug 233066 ***