SpikeHD / AmazonMonitor

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

Showing wrong price #17

Closed Lukemul6 closed 4 years ago

Lukemul6 commented 4 years ago

Not entirely sure what is happening, I have an item that comes through on the monitor as $1200 but when you click the link it shows as $820 on amazon. I think it is showing the reseller prices? Any way to fix that?

SpikeHD commented 4 years ago

Can you link the item?

Lukemul6 commented 4 years ago

https://www.amazon.com/dp/B001ARYU58/ Its showing OOS now. But every time I get it through it shows $1200

Lukemul6 commented 4 years ago

Once it was even $1349.

Lukemul6 commented 4 years ago

I just checked mysql database and its lastprice was set to $1. I just set it to $0. See what happens.

SpikeHD commented 4 years ago

I found a bug that related to price getting, which was the source of your $1 last price. Fixed and pushed that, so try git pulling and lemme know how it goes

Lukemul6 commented 4 years ago

Thanks!

Lukemul6 commented 4 years ago

Just updated everything (I havent updated since you first released it) but now my discord bot isnt sending anything? I see the items in mySQL getting prices for the ones in stock but nothing on discord.

Lukemul6 commented 4 years ago

Got this error trying to watch an item

(node:8760) UnhandledPromiseRejectionWarning: DiscordAPIError: Cannot send an empty message
    at RequestHandler.execute (C:\Users\Administrator\Desktop\AmazonMonitor-master (1)\AmazonMonitor-master\AmazonMonitor-master\node_modules\discord.js\src\rest\RequestHandler.js:170:25)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:8760) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:8760) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Lukemul6 commented 4 years ago

Downloaded a completely fresh copy and got this error

(node:28392) UnhandledPromiseRejectionWarning: DiscordAPIError: Cannot send an empty message
    at RequestHandler.execute (C:\Users\Luke\Downloads\AmazonMonitor-master (1)\AmazonMonitor-master\node_modules\discord.js\src\rest\RequestHandler.js:170:25)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)
(node:28392) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:28392) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
SpikeHD commented 4 years ago

Works fine for me, are you trying to watch the same item you linked before?

Lukemul6 commented 4 years ago

Nope started a whole new database and downloaded a new copy of your monitor :/

Lukemul6 commented 4 years ago

Its not adding anything to the watchlist. I added a completely random item on amazon. The discord bot responded saying it has added it to the watchlist but cmd throws an error and I type !watchlist and get nothing.

Lukemul6 commented 4 years ago

Man, I am dumb. I missed the part where you said to run

ALTER TABLE watchlist ADD COLUMN priceLimit FLOAT NOT NULL DEFAULT 0;

Got it working again! Thanks!

SpikeHD commented 4 years ago

No worries, glad it working!