Navigation problem - How to refresh source code links?

Hi,
I have webstorm 11. CTRL-B navigation - to jump to a declaration - usually works, but recently, and often, the link fails. The only way I can reset it is to close down webstorm and open it up again. Which is a pain. Then this navigation works (for about 5 minutes).

Is there a way to "refresh the webstorm database" without having to close and restart?

cheers
Steve

10 comments
Comment actions Permalink

Please try invalidating caches (File/Invalidate caches, Restart) - does the issue persist?


0
Comment actions Permalink

Hi,
Thanks.
Yes, I have done that. Then it works for a while. After 10 minutes it happens again. It cannot even got to a declaration in the same file/class (but it will work in other files, so it's not a "global failure").  I have tried doing a reformat in Dart style for the files that develop the problem (I don't see any pattern yet), but that doesn't fix it.

regards
Steve

0
Comment actions Permalink

What Dart SDK is being used? Can you attach your idea.log?


0
Comment actions Permalink

Hi,

Thanks.

I'm using Dart SDK 1.13 Dev 7.10

I attach a few logs.
Cheers
Steve



Attachment(s):
webstorm temp feedback.zip
0
Comment actions Permalink

Thank you for the log files, we are investigating it.
Meanwhile Dart SDK 1.13 final release is out and it contains some fixes related to your problem. Please let us know if it works better for you.
Dart SDK 1.14.0-dev.1.0 might contain even more fixes.
If the problem is still there try to click 'Reanalyze Dart Sources' button in the Dart Analysis tool window instead of restarting the IDE, will it help?

Related questions: how big is your project? How many pubspec.yaml files? How long does initial 'Dart Analysis...' progress take (see IDE status bar)?

0
Comment actions Permalink

Hi,

My project is not particularly large: around 60 dart files, 25 html files.

I don't see how long it takes to do a Dart analysis in the status bar, but it's taking about 2 seconds (i5 1.7Ghz)

I suppose I should start a new thread with this, but I also experience another fault that re-doing a Dart analysis does not fix.

I have:

 
PaperInput pi= document.querySelector('#idsomename');


which works fine for several debug runs, and then in the debug control pane I get:

Exception: Uncaught Error: type 'HtmlElement' is not a subtype of type 'PaperInput' of 'pi'.

It also happens on PaperButtons. I have to restart webstorm and then the complaint disappears.

cheers
Steve

0
Comment actions Permalink

Is the original problem with navigation solved by updating Dart SDK?
If not, does Reanalyze Dart Sources button help?

As for the new problem with "Exception: Uncaught Error..." it looks like a problematic code (non checked cast) and not related to the IDE. Debugging might help to catch it.

0
Comment actions Permalink

Hi,
1) no, the problem has not gone away by updating the dart sdk. Reanalyse dart does not fix it.

2) the new problem only occurs under debug (I guess it's hidden in a normal run). I break on the line,
then single step F8, and the
exception occurs. I have tried a couple of methods to trick it, like definīng a new intermediate variable and
using "as PaperInput" but it never works until I restart webstorm and all is well again.

If i use

var pi =...

It says that pi is a PaperInput. The next line I step to has :

PaperInput pi1 =...

and it has the exception that pi1 is an htmlelement!


Both problems are intermittent but frequent.


cheers

Steve

0
Comment actions Permalink

1. 'Go to declaration' is powered by the Dart Analysis Server from the Dart SDK. We need to localize the issue and file a bug in their issue tracker. Can you please do the following:
- Delete old logs (Help | Show Log)
- Add #com.jetbrains.lang.dart.analyzer.DartAnalysisServerService to the Help | Configure Debug Log Settings
- Reproduce the problem with not working navigation. Press Reanalyze Dart Sources and make sure it doesn't help.
- Attach idea.log file here.
- Provide a screenshot, showing what navigation stopped working.

2. I'll try to help if I have a reproducible case on my end. Is the project open-source?

0
Comment actions Permalink

Hi,

I haven't forgotten!

Sorry, no, it's not open source, but it will be free to use.

An update: I dropped back to Dart 1.13.0 Stable:

1) the CTRL-B navigation problem seems not to be present, so far.
2) the PaperInput/HtmlElement problem is present.

cheers
Steve

0

Please sign in to leave a comment.