Closed DontAskM8 closed 7 years ago
@RevivedSol, could you provide the command you are using to run the bot?
Node trade_offers.js
You need to create a config file containing your user information: https://github.com/jacobtruman/nodejs_steambot/wiki
Ive already done it though, even made a folder named configs and put it in there
As it says on the wiki node trade_offers.js username
, where username is the name of the config file you created. If you created the file configs/RevivedSol.json
, the command would be node trade_offers.js RevivedSol
Huh ? So i should do node trade_offers.js config. ?
Will try, will get back to you if there is still any issues
@jacobtruman Hmm i try reinstalling the bot and after i type npm install nodejs_steambot , it says "50 error Refusing to install nodejs_steambot as a dependency of itself" and is it possible to add me on steam? i think it will be much more easier or maybe facebook
How did you go about uninstalling the bot?
@jacobtruman what do you mean ? and i can only download the depencies using npm install
what did you do to uninstall it? what command did you run, or what exactly did you delete?
i deleted everything and redownload at github, the previous one's depencies were also installed using npm install
Delete everything again and run npm install nodejs_steambot
@jacobtruman It gave me this error
npm ERR! Windows_NT 10.0.15063 npm ERR! argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install" "nodejs_steambot" npm ERR! node v6.10.2 npm ERR! npm v3.10.10 npm ERR! code ENOSELF
npm ERR! Refusing to install nodejs_steambot as a dependency of itself npm ERR! npm ERR! If you need help, you may report this error at: npm ERR! https://github.com/npm/npm/issues
npm ERR! Please include the following file with any support request: npm ERR! C:\Users\JingYong-PC\Desktop\nodejs_steambot-master\npm-debug.log
have you found the fix ? @jacobtruman
I have never run into this problem and I am inclined to think it is an issue with how npm works, and not my code. Could you try running the install in a different directory?
is it something to do with the version of my nodejs ?
Not sure - a quick google search might help:
http://stackoverflow.com/questions/11940086/refusing-to-install-sqlite3-as-a-dependency-of-itself
kudos to this, it started downloading the dependices
Check if your project folder name is same as the module you are trying to install,
If you try to install express inside a project folder name express, you will get this error.
Rename your Project Folder, Your project Folder name should be unique compared to the npm module names
Also change the package.json file entry
"name": "xxxxx", "version": "1.0.0",
This is because you are running npm install nodejs_steambot
inside the steambot directory itself. If you run npm install [package]
, it will install [package]
in the node_modules
subdir
Run npm install
instead of npm install nodejs_steambot
. You are trying to install the project's dependencies, not the project itself.
now... when it finishes download the dependencies. it shows
npm WARN nodejssteambot@0.1.16 license should be a valid SPDX license expression
and when i try do node trade_offers.js
Error: Cannot find module 'steam-webapi
mm
Are you running just npm install
in the base directory? Which command spits out this error? steam-webapi
installs fine for me.
first i do this at cmd "cd C:\Users\JingYong-PC\Desktop\nodejs_steambot-master"
Then i typed npm install
And i type node trade_offers.js
edit i went to the node modules file and copy steam-web-api and rename to steam-webapi. The error dont show anymore but this came out ... (idk why is there so many problems zz)
TypeError: Cannot read property 'key' of undefined
at new tfprices (C:\Users\JingYong-PC\Desktop\nodejs_steambot-master\node_modules\tfprices\index.js:8:17)
at Object.
@jacobtruman it looks like this might be due to the dependency being namespaced under @doctormckay, but it's required in as just steam-webapi
and not @doctormckay/steam-webapi
.
Did this dependency change recently? It could be you still have a local copy of steam-webapi
so it's not failing for you.
@jpumford I am not sure, I have been using without issue for more than a year. My last update (which was unrelated to steam-webapi
) was 22 days ago. It looks like steam-webapi
was updated a little less than a year ago.
@jacobtruman is it possible that you give me a copy of yours ? Like maybe upload to mediafire or any link
It looks like I am running on version 0.6.5 of steam-webapi
, which might explain that.
@jacobtruman ive download the 0.6.5 version but now another issue -_-
C:\Users\JingYong-PC\Desktop\nodejs_steambot-master\node_modules\tfprices\index.js:8 p.key = options.key; ^
TypeError: Cannot read property 'key' of undefined
at new tfprices (C:\Users\JingYong-PC\Desktop\nodejs_steambot-master\node_modules\tfprices\index.js:8:17)
at Object.
I get that error as well. What does npm ls | grep tfprices
give you @jacobtruman?
The fix is quite simple... node index.js username
; the trade_offers.js
file is old - I need to update the wiki.
@jacobtruman so ive download the new one and where should i put my is and ss ?
C:\Users\JingYong-PC\Desktop\tf2 bot\index.js:443 if(account_config.steam_guard.shared_secret != undefined) { ^
TypeError: Cannot read property 'shared_secret' of undefined
at getLogonOptions (C:\Users\JingYong-PC\Desktop\tf2 bot\index.js:443:31)
at Object.
That all should be auto generated and written to the config file after you put in your steam guard code.
I cant even login though, it straight away show that error. And btw which smaple config should i use ? The one with custom sel/buy order or the one needed bp.tf api ?
@jacobtruman i still couldnt login, it keeps showing the error and wont let me type my steamguard code
C:\Users\JingYong-PC\Desktop\tf2 bot\index.js:443 if(account_config.steam_guard.shared_secret != undefined) { ^
TypeError: Cannot read property 'shared_secret' of undefined at getLogonOptions (C:\Users\JingYong-PC\Desktop\tf2 bot\index.js:443:31) at Object. (C:\Users\JingYong-PC\Desktop\tf2 bot\index.js:132:20) at Module._compile (module.js:570:32) at Object.Module._extensions..js (module.js:579:10) at Module.load (module.js:487:32) at tryModuleLoad (module.js:446:12) at Function.Module._load (module.js:438:3) at Module.runMain (module.js:604:10) at run (bootstrap_node.js:393:7) at startup (bootstrap_node.js:150:9)
What command are you using to start the bot?
Node index.js config
You need both config.json
and username.json
, where username is your username. Then your command should be node index.js username
where username is your username. For example: my username is jacobtruman, so the command I run is node index.js jacobtruman
.
Ops forgot to tell you ive tried that too :c
Ok, post your configs here - make sure you change passwords one keys.
@ok ive tried put both with the same thing
{ "username":"_________", "password":"________", "bot": { "item":"ITEM TO BE BOUGHT/SOLD", "purchase_price":0, "sale_price":0 } }
ive also tried setting the config.json to the default one
{ "username":"USERNAME", "password":"PASSWORD", "bot": { "item":"ITEM TO BE BOUGHT/SOLD", "purchase_price":0, "sale_price":0 } }
@jacobtruman anything wrong with the config ?
I am assuming your username is not *, and that you put your actual password in.
Huh ? I dont get it ...
What is the username you use to login to steam? That is what should be in the username field. The password you use to login to steam should go in the password field. The config you posted has "*" for the username. I don't want you to post your password here, but it should be in your config file.
thats what i did though :c
@jacobtruman add me on steam steamcommunity.com/id/tokenboi i think its easier and safer or can you help me by telling me what to do 1 by 1 ?
Or maybe skype? Ill share my screen
Ok, there is more that I need to document about how to setup your config - there are a few things generated when enabling steam guard that are not shown to you on your mobile device that need to be captured and added to the user config. I thought I had automated this in my script, but must not have. The problem with handling it automatically with the script is that you will no longer be able to use the steam guard codes generated on your mobile device. I will update the documentation that describes how to set this up for both your mobile device and the bot.
Stay tuned...
So its the scripts' problem?
No, it's a problem with your config
This the whole error code
SyntaxError: Unexpected token { in JSON at position 145 at Object.parse (native) at Object. (C:\Users\JingYong-PC\Desktop\nodejs_steambot-master\trade_offers.js:114:16)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
What is wrong here ?
// main config file if (fs.existsSync(configFile)) { var data = fs.readFileSync(configFile, 'utf8'); if (data != undefined){ config = JSON.parse(data); }else { throw Error("MISTAKE: there was a problem reading the config file: " + configFile); } } else { throw Error("MISTAKE: configFile does not exist: " + configFile); }
And if possible can someone add me on steam or facebook and teach me how to install it properly