SpikeHD / AmazonMonitor

Amazon price checker, item monitor and stock monitor, all shoved into a Discord bot
GNU General Public License v3.0
221 stars 38 forks source link

[ERROR] Bot terminates #78

Closed m4king closed 2 years ago

m4king commented 2 years ago

Hello Spike.

The bot terminates with this error, what can I do to correct it? I have use some new proxies.

gREETZ

Provide console output with debug mode enabled:

[MESSAGE]  Type: proxy
[MESSAGE]  Selected proxy URL: http://xyz:xyz@1.1.1.1:10 <- This is not real Proxy ;)
[ERROR]  Error: net::ERR_FAILED at https://www.amazon.de/dp/B07XTVTRLZ/
    at navigate (F:\bot\AmazonMonitor-master\node_modules\puppeteer\lib\cjs\puppeteer\common\FrameManager.js:115:23)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async FrameManager.navigateFrame (F:\bot\AmazonMonitor-master\node_modules\puppeteer\lib\cjs\puppeteer\common\FrameManager.js:90:21)
    at async Frame.goto (F:\bot\AmazonMonitor-master\node_modules\puppeteer\lib\cjs\puppeteer\common\FrameManager.js:417:16)
    at async Page.goto (F:\bot\AmazonMonitor-master\node_modules\puppeteer\lib\cjs\puppeteer\common\Page.js:784:16)
    at async Object.exports.getPage (F:\bot\AmazonMonitor-master\common\util.js:139:3)
    at async Object.exports.details (F:\bot\AmazonMonitor-master\common\Amazon.js:104:16)
    at async doCheck (F:\bot\AmazonMonitor-master\common\util.js:209:20)
F:\bot\AmazonMonitor-master\common\Amazon.js:115
  let category = $('#wayfinding-breadcrumbs_container').find('.a-list-item').find('a').text().trim().toLowerCase()
                 ^

TypeError: $ is not a function
    at parse (F:\bot\AmazonMonitor-master\common\Amazon.js:115:18)
    at Object.exports.details (F:\bot\AmazonMonitor-master\common\Amazon.js:111:10)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async doCheck (F:\bot\AmazonMonitor-master\common\util.js:209:20)
SpikeHD commented 2 years ago

Looks like the request to get the page is failing, though it doesn't really say why. I guess make sure the proxies are valid, and that the link also works without them.