PB Windows IDE not responding for a long time

Everything else that doesn't fall into one of the other PB categories.
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

PB Windows IDE not responding for a long time

Post by RSrole »

This just happened yesterday. It happens with both x86 and x64. Using the C backend. The day before yesterday all was well. The only change that I made was installing SpiderBasic Demo, which I like and will be purchasing. I don't know if that has anything to do with it. After it happened, I updated windows just in case.

Windows 10
Processor Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz 3.60 GHz
Installed RAM 16.0 GB
System type 64-bit operating system, x64-based processor
Pen and touch No pen or touch input is available for this display
Purebasic 6.00 LTS
Anyone have any thoughts?
User avatar
idle
Always Here
Always Here
Posts: 5901
Joined: Fri Sep 21, 2007 5:52 am
Location: New Zealand

Re: PB Windows IDE not responding for a long time

Post by idle »

Updated windows. Maybe?
There was a post about the latest windows 10 update which broke https, maybe the ide is calling home to check for updates and hanging.

Can you describe in a bit more detail how it's hanging. Doesn't really make any sense that it would change the ide behavior. Maybe it's the code history.
Or windows offender.
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

Re: PB Windows IDE not responding for a long time

Post by RSrole »

It just sits there on the splash screen and if I look in task manager, it says "Not Responding". Eventually something breaks free and the IDE is displayed. It doesn't matter if I have a project to automatically load, which is normal for me, or if I've closed everything the last time and it's coming up in a virgin state. If I have nothing loaded on startup and then tell it to load a project, it also hangs for awhile and eventually the project loads. These aren't large projects and until this happened yesterday, the Ide was very responsive.

I tried uninstalling 6.0 and installing 5.73 but it does the same thing. So I re-installed 6.0
User avatar
Caronte3D
Addict
Addict
Posts: 1361
Joined: Fri Jan 22, 2016 5:33 pm
Location: Some Universe

Re: PB Windows IDE not responding for a long time

Post by Caronte3D »

Maybe you have a very large Session History?
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

Re: PB Windows IDE not responding for a long time

Post by RSrole »

That's a good hint. I deleted the session history and let it create a new one. It was still very slow getting going and shutting down. So (for the moment), I've turned off recording Session History and now it's very snappy again. Of course, I would rather have Session History on, but maybe someone can figure out why, all of a sudden it's really slow. It's an sqlite db, and I use the very same in some of my programs, but never with such terrible performance. I don't see the sqlite.dll in the \Purebasic folder, so I don't know which version it's using. I suppose it's possible that when I installed spiderbasic, it changed the sqlite.dll and something is now amiss.
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

Re: PB Windows IDE not responding for a long time

Post by RSrole »

Still very weird! I disabled Session History and Check for updates and it started up very quickly, once. And then back to slow. It is also hanging on OK from compiler options. Something is weird when it's writing to disk. I don't think it's a PB problem per se, but so far it's only affecting PB. I'm open to other suggestions.
fryquez
Enthusiast
Enthusiast
Posts: 391
Joined: Mon Dec 21, 2015 8:12 pm

Re: PB Windows IDE not responding for a long time

Post by fryquez »

Disable Anitvirus and see if it makes a difference. Also the IDE is Open Source, so you could debug it.
BarryG
Addict
Addict
Posts: 4173
Joined: Thu Apr 18, 2019 8:17 am

Re: PB Windows IDE not responding for a long time

Post by BarryG »

Caronte3D wrote: Sat Nov 05, 2022 9:42 pmMaybe you have a very large Session History?
I doubt it's a large Session History problem - mine is 727 MB and the IDE starts instantly. Even when the IDE is loading a source file of almost 2 MB it's still fairly fast (just a few seconds).
User avatar
Caronte3D
Addict
Addict
Posts: 1361
Joined: Fri Jan 22, 2016 5:33 pm
Location: Some Universe

Re: PB Windows IDE not responding for a long time

Post by Caronte3D »

I don't know what the slow problem is, but my PB takes almost 20 seconds to respond.
I have already gotten used to it :?
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

Re: PB Windows IDE not responding for a long time

Post by RSrole »

I downloaded the source for the ide from git hub. The source has a couple of lines to
XIncludeFile "Build/BuildInfo.pb"
and
IncludeBinary "Build/DefaultTheme.zip"

but sadly no "build folder" and no Buildinfo.pb or DefaultTheme.zip. If anyone has those, I'll be grateful.
fryquez
Enthusiast
Enthusiast
Posts: 391
Joined: Mon Dec 21, 2015 8:12 pm

Re: PB Windows IDE not responding for a long time

Post by fryquez »

There is a PureBasicIDE/MakeWindows.cmd batch that creates these files and build the IDE.
BarryG
Addict
Addict
Posts: 4173
Joined: Thu Apr 18, 2019 8:17 am

Re: PB Windows IDE not responding for a long time

Post by BarryG »

I think I read here before that it can be slow with Syntax Highlighting turned on. So turn it off as a test?
Marc56us
Addict
Addict
Posts: 1600
Joined: Sat Feb 08, 2014 3:26 pm

Re: PB Windows IDE not responding for a long time

Post by Marc56us »

Look windows log

Win + R
eventvwr

(see system log: red and yellow icons)
:wink:
BarryG
Addict
Addict
Posts: 4173
Joined: Thu Apr 18, 2019 8:17 am

Re: PB Windows IDE not responding for a long time

Post by BarryG »

Just found my old post here about slow IDE startup -> viewtopic.php?t=74256

I totally forgot about that issue. So maybe test that Windows setting?
RSrole
User
User
Posts: 71
Joined: Fri Apr 29, 2022 8:27 pm

Re: PB Windows IDE not responding for a long time

Post by RSrole »

Okay, I found the culprit, sort of. I was working on a program for both windows and mac. I was doing most of the work on my windows 10 machine and had my macbook open next to me and connected via the network. On one occasion, I mistakenly opened the project folder in the explorer window that was pointing to the mac source code folder, oops! I realized my mistake quickly, and closed it. Then reopened from the correct local folder. All well and good. However the next time I used PB, with the macbook shut down when Procedure RecentFiles_AddMenuEntries(IsProject) ran and it hit that entry which was \\192.168.0.17\blablabla it hung. It looks like it's trying to access the file, but with the mac shut down, it can't. So the delay I'm seeing is the network timeout! If I turn on the macbook, everything starts up quickly.

Digging a little deeper I found the problem:

Code: Select all

Procedure.s RecentFiles_EntryString(Index)
  
  If Index > #MAX_RecentFiles ; its a project    
    Name$ = ProjectName(RecentFiles(Index))
    If Name$ <> ""
      Name$ = "  (" + Name$ + ")"
    EndIf    
    ProcedureReturn RSet(Str(Index-#MAX_RecentFiles), Len(Str(FilesHistorySize))) + ")  " + GetFilePart(RecentFiles(Index)) + Name$   
  Else ; its a source file
    ProcedureReturn RSet(Str(Index), Len(Str(FilesHistorySize))) + ")  " + RecentFiles(Index) ; Display full path here, to avoid issue if some files gets same name (ie: main.pb) https://www.purebasic.fr/english/viewtopic.php?f=3&t=60650
  EndIf
  
EndProcedure
GetFilePart appears to be trying to access the file, which fails if it's a remote machine and it's not available.

So for the moment, how can I remove the entry from the database? I don't know where it's stored.

Thanks
Russ
Post Reply