I personally think it would be best, if vendors would only trade with the items specific for their trade specialization. It seems like the only right solution...
Example: GUNSshop vendor will ONLY accept caps and guns or ammo, so he will allways only have guns and ammo to sell, since he won't be buying anything else. GENERAL store - the same but opposite, he buys your gecko hides, metal parts, ropes and fruits, and other trash but you couldn't rape his inventory by selling 10000 fruits because he would only have the same kind of stuff to sell - materials and general stuff, no guns. Same goes for doctors and healing stuff, bartenders and alcohol, armorers and armor.
This would make trading more logical and instinctive (instead of going everywhere searching for some usefull stuff at any vendor you would just go to GUNS-SHOP to buy guns, GENERAL to buy general materials, etc.) And most important - it would fix the 'useless junk rape' problem, since the more or less uselless stuff would mass at a merchant, who can only sell you other 'useless stuff' in exchange.