My master mason trades emeralds for stone at a discounted price of 19 (from 20). However, when I activate the trade, the mason takes 39 stone, the combined price of the discount and the original price. (Sometimes the mason takes 47 stone, but I can't figure out why it chooses that number specifically.)
EDIT: This seems to be a UI issue with discounts and displaying increased price due to constant demand. After not trading with the villager for a couple days, their "discount" was removed and the price was reset to 20 stone, which functioned correctly.
Related issues
duplicates
Comments

Duplicate of MC-151282.