Author Topic: Delayed context tagging  (Read 869 times)

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Delayed context tagging
« on: March 12, 2019, 05:48:54 pm »
I have a problem with context tagging which seems to have dragged on between SE versions, so perhaps it's a setting I've made (or not made) rather than an issue per se. Maybe it rings a bell with someone...

What it is is that context tagging doesn't work for the file I am editing. That is, in one file I will create a typedef struct, say, and in another file when I use that definition I don't got code completion and nothing in the preview window. I check that the background tagging is complete (from the status bar), save the edited file, etc., but generally nothing helps. Close and restart SE and it's working great.

I am not sure if this only occurs, or perhaps is worse, if I create the file during that session (file, new). Despite it being added to the project, perhaps SE doesn't recognise it as so until a restart.

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2900
  • Hero Points: 438
Re: Delayed context tagging
« Reply #1 on: March 12, 2019, 07:48:40 pm »
If you can put together a small sample to reproduce this, or a complete set of steps to reproduce it, we'll see if we can find a solution.

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #2 on: March 12, 2019, 09:36:00 pm »
Yes. Trouble is it pops up out of the blue and when I'm intentionally remembering what I'm doing it tends not to happen :)

Just wondered if it rang a bell with anyone, but I'll try and work out the definitive steps.

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #3 on: December 17, 2019, 01:58:36 am »
This is happening again in V24.0.0.8.

Earlier on SE was failing to find uint32_t and the like. I added the compiler include directory and it then took quite a while to actually resolve things, but I put it down to one of those things.

Just now I was editing a src.h file and the additions I made didn't show up in the src.c at all (the files are next to each other in a folder). I went as far as adding the folder as a compiler include directory but it made no difference. Rebuilt the workspace tag file with no change. Closed and reopened SE and it worked fine.

Is there something I can do or look at when this is happening to pinpoint the cause?

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2900
  • Hero Points: 438
Re: Delayed context tagging
« Reply #4 on: December 19, 2019, 01:15:16 am »
You can try the attached experimental hot fix.

Note, because of the nature of how the cumulative hot fixes are loaded, this fix might be kind of a one-off.  You can load it, but it might only be effective for your current session.

If it works, it will be part of the next cumulative hot fix for 24.0.0.

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #5 on: December 19, 2019, 11:06:45 am »
Thanks, Dennis. When you say "if it works", what should I be looking for? I mean, since it's a flaky problem do I just not get that any more, or should I load it when the problem occurs? Sorry for being dense...

Dennis

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2900
  • Hero Points: 438
Re: Delayed context tagging
« Reply #6 on: December 19, 2019, 03:05:38 pm »
Actually.  I have to apologize, I mistook your post for another problem that involved a different kind of delays.  This fix does not address what you have been seeing.  I do plan on looking into your problem, but I've chased this one before, and have not been able to isolate it.  So that reproducible case still would be invaluable.

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #7 on: December 19, 2019, 03:11:10 pm »
No worries. I understand that it is really tricky to figure out problems from just a vague report and no means to replicate them :)

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #8 on: December 23, 2019, 12:06:22 pm »
This is very bad indeed, now. I can pretty much guarantee that adding a #define or something to a .h won't be picked up until SE is restarted.

It's not just one project but all the ones I am currently working on. Unusually (for me) the workspaces hold the primary project (embedded firmware code) and then I've added a non-editing project (manufacturer hardware API) for middleware function/type lookup. I am thinking that perhaps it's this combination of projects in a workspace which may be causing the issue.

Additionally, the SE workspace and project configs are in one directory but the code is in another. That applies to both the project I am editing and the associated project I have for reference. Don't know if this mix of paths is contributing, too...

I'll try and narrow down the similarities between projects where this occurs, but I thought I'd mention it now in case it rings a bell.

Graeme

  • Senior Community Member
  • Posts: 2425
  • Hero Points: 322
Re: Delayed context tagging
« Reply #9 on: December 24, 2019, 12:27:46 am »
This is very bad indeed, now. I can pretty much guarantee that adding a #define or something to a .h won't be picked up until SE is restarted.

Do you mean it goes wrong soon after you restart slick  - or does it take a while.

One thing you could try is make a copy of the tag file at the time it's going wrong, then restart slick and if it is then working correctly for that symbol, compare the saved tag file with the current tag file. 

If it goes wrong quickly after you restart slick then it suggests that it's something specific to your system rather a random overwrite problem or something.

You could also try rebuilding your configuration folder.  Save all your settings using options export then import to a new config and see if it takes longer before the problem starts.

Another thing you could try is
1. check whether it's only a specific type of symbol that goes wrong
2. check whether other nearby symbols can still be found

Once it goes wrong does it go wrong for all new symbols in all files?
Are namespaces involved?
Is it C or C++?
If it's readily reproducible, maybe you can use the slick C debugger to locate the code that fails.
Does find symbol or push-tag work?

dunkers

  • Senior Community Member
  • Posts: 658
  • Hero Points: 28
Re: Delayed context tagging
« Reply #10 on: December 24, 2019, 12:35:40 am »
Thanks for the ideas, Graeme - I'll check them off as it happens.