Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception when auto-uploader runs at startup on Windows #31

Open
vaindil opened this issue Feb 15, 2018 · 14 comments
Open

Exception when auto-uploader runs at startup on Windows #31

vaindil opened this issue Feb 15, 2018 · 14 comments
Assignees
Labels

Comments

@vaindil
Copy link

vaindil commented Feb 15, 2018

The auto-uploader runs perfectly when I open it manually, but the exception below is thrown when it tries to run automatically at startup. I'm able to click OK on the exception window then immediately open it manually and it works properly.

capture

@Laukei
Copy link
Collaborator

Laukei commented Feb 15, 2018

It seems that "C:\Program Files (x86)\upload.farm\uploader.exe" --silent causes the error no matter when it's run.

First thoughts: it's because the current working directory hasn't changed to the upload.farm directory, so it't not searching the right folders for whatever DLL it's loading. This seems to be confirmed by testing "C:\Program Files (x86)\upload.farm\uploader.exe" which causes the error also.

@Laukei
Copy link
Collaborator

Laukei commented Feb 15, 2018

Looks like this issue

@Laukei
Copy link
Collaborator

Laukei commented Feb 15, 2018

So, placing sqlite.dll in the lib folder fixes the main issue, but brings a new one: the logo in the uploader doesn't load facepalm should be a relatively quick fix...

image

@Laukei
Copy link
Collaborator

Laukei commented Feb 15, 2018

Okay, bugs hopefully fixed, new binary uploaded to https://upload.farm/acc - can you double check this fixes the issue? I really need to do more beta-testing before release...

@vaindil
Copy link
Author

vaindil commented Feb 17, 2018

Sorry for the delay. I just uninstalled and made sure everything was deleted, then installed the newest version and restarted. The exception is still being thrown.

@Laukei
Copy link
Collaborator

Laukei commented Feb 17, 2018

Does it throw if you run it from the commandline, for example if you run "C:\Program Files (x86)\upload.farm\uploader.exe" --silent from the application bar or a cmd window? Or only when it fires on boot/login?

@vaindil
Copy link
Author

vaindil commented Feb 17, 2018

Just checked, command line has no issues. It's only at login that the problem happens.

@Laukei
Copy link
Collaborator

Laukei commented Feb 19, 2018

I've tested this on two systems now and using the newest version on upload.farm it seems to be working fine. Does your C:\Program Files (x86)\upload.farm\lib folder have a copy of sqlite.dll in it?

@vaindil
Copy link
Author

vaindil commented Feb 20, 2018

I have sqlite3.dll but not sqlite.dll. That file is also in the root directory.

@Laukei
Copy link
Collaborator

Laukei commented Feb 20, 2018

Apologies, I meant sqlite3.dll.

I can't reproduce the error on my system. I'll try a Windows 10 clean install in a virtual machine and test it there... In the mean time, apologies for the bug!

@Laukei Laukei self-assigned this Mar 19, 2018
@Laukei Laukei added the bug label Mar 19, 2018
@vaindil
Copy link
Author

vaindil commented Jan 14, 2019

Sorry to go back to an old bug, but I just picked up SDV again and I still have this issue. I've reinstalled Windows fresh at least once since I originally opened this, and the uploader is obviously freshly installed too.

@Laukei
Copy link
Collaborator

Laukei commented Feb 12, 2019

Apologies for the delayed reply, I meant to get back to this and just forgot.

My feeling is this bug comes from some of the files I trim out when the executable is frozen. I trim the libraries because cx_freeze gives an output that is about 600mb, most of which is unused. From what I understand, the bug only appears when the program automatically starts. My thinking is that it's to do with that the path the uploader is given when it's launched manually is different when launched by the system.

On the machines I've tested it on it presumably also sees my PATH, which includes my Python install, and so can find the required DLL from that. If it's run manually it presumably starts by looking in the directory it's in, and can find the required DLL from that. But if it's run by the system on a machine which doesn't have the required DLLs in the PATH, that must lead to this error.

I'll have to look into this more and perform some experiments on my PATH variable.

@Laukei
Copy link
Collaborator

Laukei commented Feb 12, 2019

(Actually, the stuff I wrote about trimming is a separate idea I had about what was causing it, that my second paragraph basically suggests isn't the case... I should probably reason out my ideas before writing, rather than by writing)

@CanadianMaple67
Copy link

Reviving a dormant thread to say that I'm getting the exact same error when loading at Windows startup. This was a fresh install, Windows 10 64. Computer is relatively new, built in February, so I haven't installed any new Python version (that's not included in Windows by default), git, etc. Not sure if that would matter.

As above, runs fine when I open it normally, syncs fine.

Just throwing things at the wall here, but I noticed in the installed folder under Program Files there are no files in the upload.farm/lib/cx_Freeze/initscripts folder.

If what I'm reading is right (I have minimal Python experience), but I'm guessing if I get Python setup properly then the PATH should update. When (if) I get some time I'll do a quick Python install and see if playing with my PATH does anything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants