Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 267258 - Sources are absent in files view for a newly created project from binary
Sources are absent in files view for a newly created project from binary
Product: projects
Classification: Unclassified
Component: Generic Projects UI
PC Linux
: P2 (vote)
: 8.2
Assigned To: Tomas Zezula
Depends on:
  Show dependency treegraph
Reported: 2016-07-22 18:40 UTC by Vladimir Kvashin
Modified: 2016-09-13 17:19 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT

I thought this (adding listeners not after, but *before* getting source groups) will fix, but it didn't (919 bytes, patch)
2016-09-05 11:47 UTC, Vladimir Kvashin
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Kvashin 2016-07-22 18:40:14 UTC
I created a pkg-config-0.25 project:
- get source code
- created a build subdirectory inside
- configured and built it in this directory
(I did all above in console)
Then, in IDE:
- create a project from binary
- pointed to that binary, pressed finish

The project is created. Project metadata by default is put in NetBeansProject.

Project view contains pkg-config-0.25 files.
But files view contain only nbproject!
Comment 1 Alexander Simon 2016-08-22 15:16:10 UTC
In fact source root is added to project.
See Project properties->General->Source Folders.
Or close and open the project.

It seems something wrong in source root listeners.

Please reevaluate bug.
Comment 2 Alexander Simon 2016-08-22 15:22:41 UTC
it looks like a duplicate of the bug #197134
Comment 3 Vladimir Kvashin 2016-08-23 16:26:57 UTC
Yes, the effect seems to be the same as in bug #197134. However bug #197134 was fixed in 2011, and since that time this defect did not repeat. At least I checked NB 8.0 and 8.1. So this looks like regression in dev.

Now after your comment I also see that source root is shown in Project Properties (although for me as a user this does not matter - while its absence in Files view does).

What makes me think that it's probably not a P2 is that after reopen both roots are shown.
Comment 4 Vladimir Kvashin 2016-09-05 09:57:03 UTC
I don't yet know the fix, but I do know the exact change set that led to this behaviour. It's

changeset:   298604:530da4c29d0f
parent:      298530:a21c1feffe67
user:        Tomas Zezula <>
date:        Fri Jun 17 10:56:23 2016 +0200
summary:     #255220:org.openide.explorer.view.TreeView$ExplorerTree$GuardedActions.<init>: LowPerformance took 25968 ms.
Comment 5 Vladimir Kvashin 2016-09-05 11:34:12 UTC
This can be reproduced even easier:
- create a sample C/C++ project (I tried Welcome)
- go to project properties, "General" category, add a folder that resides outside of the project to "Source Folders" field, press "OK"
- Files pane does not contain this folder

After the project is reopened, File pane shows this folder OK
Comment 6 Vladimir Kvashin 2016-09-05 11:47:17 UTC
Created attachment 161908 [details]
I thought this (adding listeners not after, but *before* getting source groups) will fix, but it didn't
Comment 7 Vladimir Voskresensky 2016-09-06 10:23:24 UTC
Tomas, can you have a look, please, why your commit could break source roots. 
Comment 8 Tomas Zezula 2016-09-12 09:30:22 UTC
Fixed jet-main b815ca9972c6

Please verify, I will transplant the fix into nb 8.2.
Comment 9 Vladimir Kvashin 2016-09-12 15:27:22 UTC
Thank you so much for fixing this! I verified your changeset (although not in jet-main, but in cnd-main context - it takes too long to clone entire netbeans repo). It works fine.
Comment 10 Tomas Zezula 2016-09-12 15:38:50 UTC
Thanks a lot Vladimir!
I will transplant the fix into NB 8.2
Comment 11 Quality Engineering 2016-09-13 02:02:23 UTC
Integrated into 'main-silver', will be available in build *201609130002* on (upload may still be in progress)

User: Tomas Zezula <>
Log: #267258:Sources are absent in files view for a newly created project from binary
Comment 12 Tomas Zezula 2016-09-13 17:19:31 UTC
Transplanted into NB 8.2 e884c15ca7e1

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo