charlesbel / Microsoft-Rewards-Farmer

A simple bot that uses selenium to farm Microsoft Rewards written in Python
MIT License
1k stars 266 forks source link

A lot of errors pop up when run in command prompt #345

Open HeathPitt opened 1 year ago

HeathPitt commented 1 year ago

Before submitting a bug report...

Title

Describe the bug

When I run in command prompt, it comes up with a lot of errors. Screenshot below

Copy and paste your error

Traceback (most recent call last): File "C:\Users\Owner\Downloads\Microsoft-Rewards-Farmer-master\Microsoft-Rewards-Farmer-master\main.py", line 175, in main() File "C:\Users\Owner\Downloads\Microsoft-Rewards-Farmer-master\Microsoft-Rewards-Farmer-master\main.py", line 21, in main loadedAccounts = setupAccounts() ^^^^^^^^^^^^^^^ File "C:\Users\Owner\Downloads\Microsoft-Rewards-Farmer-master\Microsoft-Rewards-Farmer-master\main.py", line 118, in setupAccounts loadedAccounts = json.loads(accountPath.read_text(encoding="utf-8")) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1520.0_x64qbz5n2kfra8p0\Lib\json\init.py", line 346, in loads return _default_decoder.decode(s) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1520.0_x64qbz5n2kfra8p0\Lib\json\decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.11_3.11.1520.0_x64__qbz5n2kfra8p0\Lib\json\decoder.py", line 353, in raw_decode obj, end = self.scan_once(s, idx) ^^^^^^^^^^^^^^^^^^^^^^ json.decoder.JSONDecodeError: Expecting ',' delimiter: line 6 column 5 (char 127)

Screenshots

image

Value of dashboard variable

https://gist.github.com/HeathPitt/889a1d31fcf100d24d52e009fdc3fa20

simon511000 commented 1 year ago

your accounts.json is not a valid JSON

HeathPitt commented 1 year ago

your accounts.json is not a valid JSON

AHA! It was because I deleted the proxy part instead of making it blank. Thank you mate, appreciate it 🙏

Also is it normal for login to take a while or is that another issue?

And will it work in any Chromium browser or only Chrome, and if it does how do I select which? I would be playing games while farming and because I usually do Roblox I keep Opera open. (I want to use edge for the bonus points it provides)

klept0 commented 1 year ago

Clear your sessions folder contents then run it again - see if that speeds up your login hanging at all.

If your problem is resolved - please close this issue out.