Author Topic: Internet toggle button! RESOLVED 2.43s  (Read 6770 times)

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
Internet toggle button! RESOLVED 2.43s
« on: November 14, 2007, 09:19:36 PM »
Clicking on the internet toggle button will cause a crash displaying 'Runtime Error 5: Invalid procedure call or argument.'

I prefer not to be forced to use internet mode if I don't want to.  

Also I haven't configured any folders for it and I have no FTP client so I doubt it works anyway, but I guess it will try and communicate with the server nevertheless.
« Last Edit: November 15, 2007, 08:58:28 PM by EricL »
The internet is corrupt and controlled by criminally minded people.

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #1 on: November 14, 2007, 10:44:42 PM »
I'll need more info than that as obviously there are a lot of people who click on the button and don't crash.  I certainly can't reproduce it without more specifics.   At least tell me the version you are using and post the sim you were running and whether you were enabiling or disabling Internet Mode.

You should not need to create any folders nor do you need any FTP client.  The folders will be created for you and DB contains all the FTP software necessary for communication.
« Last Edit: November 14, 2007, 10:45:33 PM by EricL »
Many beers....

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #2 on: November 15, 2007, 03:25:48 AM »
Okay, here's some more info. It's version 2.43r and the above crash appears if I delete the lastexit files in the save and settings folder before I start the program. Then when I've closed the dialogs and see the lone teleporter flooting around and I click the 'internet toggle button' the above mensioned crash appears.

If I have been running a sim WITHOUT clicking the toggle button and quit the sim, then start the program again and let it load the lastexit file, then internet mode will be disabled instead. If I then click on the button I will get this error: Runtime error '35754': Unable to connect to remote host.

I've just tested a little more here and that toggle button seem totally screwd up. Sometimes it connects instead of disconnects when you click on it and vice versa. I know it because the firewall poped up a warning when I clicked to disable, but no warning when it was enabled. ...and sometimes the other way around.

Well, I'm testing when I'm writing this and now when I click on it it appears to be working as it should. I get dialog showing internet populations when I enable and no problems when disable. It just seem to be an unstable function.
« Last Edit: November 15, 2007, 03:28:02 AM by Testlund »
The internet is corrupt and controlled by criminally minded people.

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #3 on: November 15, 2007, 12:17:00 PM »
By deleting the lastexit files, you are telling the program that you are a new user, that DB has never been run on that computer.  I'm not sure why you are doing this (you can always load a sim after startup) but I made the recent change (by request) to have internet mode be the default mode for new users.  If there is no lastext.sim, I automatically enter internet mode at startup.  If there is, I don't.

What you are seeing via your firewall w.r.t. DB trying to communicate on the network when disabling IM is expected.  When you hit the IM button to leave IM, I attempt to delete the population file on the server for your sim as you are disconnecting from the megasim and I need to tell all the other sims your are leaving, so yes, communication on the network is attempted when you leave IM (or quit the program while in IM).  If you leave IM immediatly after entering IM, before 100 cycles typically, this attempt may be the first network communication attempted by DB.

The crashes are still very valid bugs, probably have to do with trying to close the Internet graphs when they arn't open.  In the new user start up path, I don't automatically open the internet mode log or populations graph so as to make the first time expereince as clean as possible.  I am probably trying to close them when they arn't open or somethign similar and this is the crash you are seeing.  I'll take a look, but if you figure out a deterministic way to cause the crashes, that would be useful.
Many beers....

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #4 on: November 15, 2007, 02:31:02 PM »
The reason why I delete the lastexit files is because I can't start a new sim or load an existing one if I have those files in the folders, because the program force the lastexit files to load instead of my sim. I explained that in another topic but you couldn't reproduce that either. So maybe we have some differences in the operating system or DB install.

I don't know how to explain it better. Delete the lastexit files, start DB, click on 'internet toggle button'. That's the only thing that caused the runtime error 5.

Also I can mension that it doesn't work to close the program from the file menu or closing the dialog popup with the word 'sparsi' on it anylonger. Can only close by clicking on the X button in the upper right corner, but that's minor. Just thought I would mension it.
« Last Edit: November 15, 2007, 02:37:36 PM by Testlund »
The internet is corrupt and controlled by criminally minded people.

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #5 on: November 15, 2007, 02:54:40 PM »
Quote from: Testlund
The reason why I delete the lastexit files is because I can't start a new sim or load an existing one if I have those files in the folders, because the program force the lastexit files to load instead of my sim. I explained that in another topic but you couldn't reproduce that either. So maybe we have some differences in the operating system or DB install.

Are you really saying that you can't do File->Load Simulation or File->New Simulation with a running sim?  That is a serious bug if so.

Quote from: Testlund
I don't know how to explain it better. Delete the lastexit files, start DB, click on 'internet toggle button'. That's the only thing that caused the runtime error 5.
Does this happen everytime?

Quote from: Testlund
Also I can mension that it doesn't work to close the program from the file menu or closing the dialog popup with the word 'sparsi' on it anylonger. Can only close by clicking on the X button in the upper right corner, but that's minor. Just thought I would mension it.
That's not minor.  I have no idea why this is.  What does "sparsi" mean and where are you seeing that?
Many beers....

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #6 on: November 15, 2007, 03:45:35 PM »
[quote name='EricL' date='Nov 15 2007, 08:54 PM' post='1372496']
Does this happen everytime?[/quote]

Yep, the runtime error 5 happens everytime. Also the sim stays frozen until a connection has been established before that little blue teleporter starts moving around. I'm testing it right now and it appears that if there is a problem with the connection, the program stays frozen. Right now the front screen on the button is green while the one behind it is orange. It seems to shift colors from green, red, orange for some reason. Ok, I've looked at the moving teleporter. Clicking the toggle button. CRASH! But the program doesn't close when I close the crash dialog. Now, let's try it again. This time I will block the connection with my firewall:
Ok, the program just froze a little for a couple of seconds then the teleporter started moving. Clicking the button...crash.[/quote]

Quote
That's not minor.  I have no idea why this is.  What does "sparsi" mean and where are you seeing that?

You don't get that dialog?? I remember someone mension here a long time ago that it is italian and means 'close' or 'OK'. It's the big dialog that gives an explanation about DB when you start it.

I seem to have problems reproduce the 'lastexit' problem too now. I suspect it may be related to how many bots you start a new sim with. I'll check it out some more.
The internet is corrupt and controlled by criminally minded people.

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #7 on: November 15, 2007, 03:56:04 PM »
Okay, this helps.  Thanks.  I'll do some investigation.

You might try doing Ctl-Alt-Del and looking at how many instances of the DB exe are running and killing off the ones you don't want.  I bet when it crashes it doesn't exit clean adn this may be causing issues with open files or network communication.  DB's networking stuff is flaky and I'm doing my best to work around it.  The program doesn't actually hang, you are seeing very long time outs for network communication.  If you wait long enough, it should time out I hope.   I'll try to make some improvements overall and in the specific areas here.

The blue sparsi dialog only comes up now on the newbie path - when you delete lastexit.sim.  It's informational only.  The X closes that dialog, but not the DB program itself.

I'm still not clear on whether File->New Simulation is working for you or not.
Many beers....

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #8 on: November 15, 2007, 04:31:22 PM »
Quote from: EricL
I bet when it crashes it doesn't exit clean

This is true.  I've had like 5 or 6 instances of DB running because of various crashes that never cleaned themselves off.  When DB crashes, you need to make sure that it's gone from the "processes" tab in alt-ctrl-del.

Testlund, are you running Vista?

Offline Testlund

  • Bot God
  • *****
  • Posts: 1574
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #9 on: November 15, 2007, 04:45:57 PM »
Quote from: EricL
You might try doing Ctl-Alt-Del and looking at how many instances of the DB exe are running and killing off the ones you don't want.

Is that a fact?  

Quote from: Numsgil
Testlund, are you running Vista?

No, XP Pro SP 2.
The internet is corrupt and controlled by criminally minded people.

Offline Numsgil

  • Administrator
  • Bot God
  • *****
  • Posts: 7742
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #10 on: November 15, 2007, 08:14:09 PM »

Offline EricL

  • Administrator
  • Bot God
  • *****
  • Posts: 2266
    • View Profile
Internet toggle button! RESOLVED 2.43s
« Reply #11 on: November 15, 2007, 08:56:42 PM »
Quote from: Testlund
Clicking on the internet toggle button will cause a crash displaying 'Runtime Error 5: Invalid procedure call or argument.'

I have found this.  The crash is happening when I attempt to change the Main Window caption when toggling off Internet Mode.  In thenewbie start up case, I neglected to add "Internet Mode" to the Window Title.  But hen you switch out of Intenet Mode, I still tried to remove the string.  This caused the crash as I was attempting to change the main window caption to a string of negative length.

Fixed in 2.43s.
Many beers....