New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 806225 link

Starred by 2 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug



Sign in to add a comment

'Search' tab matches build and other files

Reported by davidmax...@gmail.com, Jan 26 2018

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.119 Safari/537.36

Steps to reproduce the problem:
1. Clone a project that has 'index.html' in its root, and builds into a subdirectory (eg build/).
2. Serve project (I use 'polymer serve').
3. Open page and devtools.
4. Add project directory as a workspace.
5. In the dev tools 'Search' tab, search for some string in one of the source files.
6. Notice that is matches the files correctly, and output is useful.
7. Now build the project.
8. Re-run the search.

What is the expected behavior?
I expect the build/ directory to be ignored (since it is not being 'served').

What went wrong?
I get matches from the build/ directory too, which obfuscates the results.

Did this work before? N/A 

Chrome version: 64.0.3282.119  Channel: stable
OS Version: 
Flash Version: 

Please consider adding a facility to only search files that are part of the app being served, even if I have to specify them.
If the search term is general enough (eg 'button'), I get all sorts of rubbish (eg package.json).

I realise it might be better to have a directory that is self-contained, so the 'workspace' is just that directory; but I think that having index.html in the project root is pretty common, so it would be very useful to be able to limit searches to specific directories.
 
Labels: Needs-Triage-M64
Cc: einbinder@chromium.org vamshi.k...@techmahindra.com
Labels: Triaged-ET
Thanks for filing the issue!

As ET team doesn't have polymer server and project set up on the system to test and confirm this as of now, hence requesting some one from DevTools team for help in triaging the issue further.
This bug isn't related to polymer, so you don't need to use 'polymer serve' - any dev server will do. A common alternative is: 'python -m SimpleHTTPServer 8000'.

Anyway, it occurs to me that using the polymer starter kit should work for this too, and has easy-to-follow instructions:

https://developers.google.com/web/tools/polymer-starter-kit/

HTH
Labels: Needs-Feedback
@Reporter: Could you please provide sample test file to check this issue. If possible please guide us with video on how to reproduce this issue. This would help in further triaging of the issue.

Thanks!

Comment 5 by l...@chromium.org, Jan 31 2018

Owner: l...@chromium.org
Status: Assigned (was: Unconfirmed)
Thanks for the report.  Would 'include'/'exclude' input filters address the issue?
Owner: einbinder@chromium.org
I would imagine 'include'/'exclude' input filters might address the issue - though I'm not completely sure what is being suggested - I'm not sure that files that aren't ever going to be needed to be seen when debugging need to be included at all. Thinking about it, 'include'/'exclude' might be OTT - the files needed for debugging already seem to have been identified by little green ticks (right?), so perhaps the option just needs to be such that only those files are searched?
Project Member

Comment 8 by bugdroid1@chromium.org, Dec 4

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/547cbfbc4c2839009210ce02c1bedae2f096d5d1

commit 547cbfbc4c2839009210ce02c1bedae2f096d5d1
Author: Joel Einbinder <einbinder@chromium.org>
Date: Tue Dec 04 02:14:44 2018

DevTools: Favor search results from the network

Files not from the filesystem, or not with green dots, are way more
likely to be relevant to the user.

Bug: 806225
Change-Id: I59e9727cf336299a459323a8357c3c242d965034
Reviewed-on: https://chromium-review.googlesource.com/c/1359468
Reviewed-by: Erik Luo <luoe@chromium.org>
Commit-Queue: Joel Einbinder <einbinder@chromium.org>
Cr-Commit-Position: refs/heads/master@{#613395}
[modify] https://crrev.com/547cbfbc4c2839009210ce02c1bedae2f096d5d1/third_party/blink/renderer/devtools/front_end/sources/SourcesSearchScope.js

> Files not from the filesystem, or not with green dots, are way more
likely to be relevant to the user.

I might be missing something, but that comment seems to be suggesting the opposite of what I am asking for..?

Sign in to add a comment