Vanilla Posted June 21, 2017 Report Posted June 21, 2017 (edited) Hello there, I found a weird problem when checking if an item is marketable or notI'm running 1:1 Card Trade (same-set) bot, and additionaly also accept 1:1 from non-marketable cards. The code I use to check if an item is marketable or not is something like this offer.itemsToReceive.forEach(function(item) { if ((item.type.includes("Trading Card") == true) && (item.marketable == false)){ itemBotReceive.push("Non-Marketable Trading Cards"); //Non-marketable cards will be pushed to new array } }); The problem is, when using above code, sometimes marketable cards will goes to non-marketable cardsThis screenshot is perfect example for what I mean: As you can see above, one of them is accepted, while the other one is rejected. Both trades come from same personWhen I check the log it say: 21/05/17 - 05:18:07 - Accepting (1:1) Trade Offer #2227108866 : (SteamID) 21/05/17 - 05:18:15 - Confirmed Trade Offer #2227108866 21/05/17 - 05:22:28 - Rejecting Trade Offer from (SteamID) - Reason: Cross-Set 21/05/17 - 05:22:28 - [INFO] givenlength: (1) receivelength: (1) tagged: (0) nonmarketable1: (0) nonmarketable2: (1) Mysterious card "3" for some reason will got tagged as "Non-Marketable Cards", but it's clearly that the cards is marketable --- Is this a bug or something? I can't reproduce this issueIt's been going on for pretty long time, but pretty rare (about 5% Trades will get rejected for same reason) Thanks Edited July 10, 2017 by Vanilla Quote
Dr. McKay Posted June 21, 2017 Report Posted June 21, 2017 It's possible Steam occasionally returns bad information (wouldn't be unheard of). It would be more helpful to have a full json dump of the item in question when this happens. Quote
Vanilla Posted June 21, 2017 Author Report Posted June 21, 2017 (edited) It's possible Steam occasionally returns bad information (wouldn't be unheard of). It would be more helpful to have a full json dump of the item in question when this happens. Thanks, I didn't save the full JSON dump when it happenI will reply this post when it's happening again. edit: typo Edited June 21, 2017 by Vanilla Quote
Vanilla Posted June 21, 2017 Author Report Posted June 21, 2017 (edited) Hello, it's happening again: http://i.imgur.com/QGThmOj.png 21/05/17 - 14:10:52 - Rejecting Trade Offer from 76561198367819501 - Reason: Cross-Set 21/05/17 - 14:10:52 - [INFO] givenlength: (2) receivelength: (2) tagged: (0) nonmarketable1: (2) nonmarketable2: (0) The offer object is in attachment.Looks like both cards in "itemsToGive" is marketable false. But the item is actually marketable http://steamcommunity.com/market/listings/753/639900-Mysterious%20Card%203http://steamcommunity.com/market/listings/753/639900-Mysterious%20Card%2010offer.txt Edited June 21, 2017 by Vanilla Quote
Dr. McKay Posted June 21, 2017 Report Posted June 21, 2017 I can't reproduce this. You say it only happens sometimes, not all the time for the same item? Quote
Vanilla Posted June 21, 2017 Author Report Posted June 21, 2017 (edited) I can't reproduce this. You say it only happens sometimes, not all the time for the same item?Yes, only happens sometimes.I can't also reproduce this, i'm not really sure what's happen tbh.. Additionally, is there other way to check if an item marketable or not other than using 'item.marketable'? Edited June 22, 2017 by Vanilla Quote
Dr. McKay Posted June 22, 2017 Report Posted June 22, 2017 No, not really. I see in your output that tradable is also false (which obviously cannot be true if it's in a trade offer). You may consider just failing the entire trade and trying again later if any item has that property as false. Vanilla 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.