Transaction problems
TX states, error codes, [TX id] logs, and items in mailbox / pending-returns.
Based on GrzybcioRynek 1.0.3 and web 0.1.0 source.
Buying is a state machine in MarketManager.buyItem. With transactions.logging: true every stage goes to the console.
Log
[TX <uuid>] <STAGE> listing=#<id> buyer=<uuid> seller=<uuid> price=... fee=... item=TYPExN state=... error=...Search for [TX and the ID. Disable logs: transactions.logging: false — states are still in market-data.yml.
States
CREATED → LISTING_RESERVED → MONEY_WITHDRAWN → SELLER_PAID → ITEM_DELIVERED → COMPLETED
Terminal: ROLLED_BACK, FAILED.
error codes
| Code | Meaning |
|---|---|
LISTING_REMOVE_FAILED | removeListing did not remove the listing |
WITHDRAW_FAILED | Vault did not take buyer money; listing restored |
SELLER_DEPOSIT_FAILED | seller UUID deposit failed; money returned to buyer |
ROLLBACK_SELLER_WITHDRAW_FAILED | could not take money from seller — buyer is not refunded (avoid mint) |
ROLLBACK_FAILED:<msg> | exception in rollbackBuy |
EXCEPTION_AFTER_<STATE> | exception in an unhandled state |
REFUND:<timestamp> | admin /market admin refund |
In the rollback log after item delivery: FINALIZED_AFTER_EXCEPTION (state stays COMPLETED).
Why you cannot buy
Player messages (not TX codes):
| Key | Text |
|---|---|
buy.not-enough-money | not enough money |
buy.own-listing | own listing |
buy.listing-locked | ID in reservedListings |
buy.inventory-full | no space (InventoryUtil.canFit) |
buy.not-available | no listing / AIR / bad price |
anti-abuse.* | cooldown / limit / max value |
buy.transaction-failed | general fail / rollback |
Item did not return to hands
- Mailbox (
market-data.yml→mailbox.<uuid>) — reasons includeexpired,removed,admin-removed,purchase-overflow,admin-refund. Command/market mailbox. pending-returns.<uuid>inlistings.yml— whenmailbox.enabled: falseand the player was offline. Delivery:PlayerJoinListener→deliverPendingReturns.- Reserved listing — expiry timer skips IDs in
reservedListings. Crash mid-buy: check[TXlog and whether the listing returned (restoreListing).
When mailbox is on, purchase overflow goes to the mailbox, not the ground. When off and the player is online: remainder drops on the ground.
“Stuck” TX
- Enable
transactions.logging: true, repeat the buy, copy[TX <id>]. /market admin inspect <listingId>— lineZablokowana: true/false.- Reload while reserved:
Trwają aktywne transakcje — spróbuj ponownie za chwilę. - Refund only for
COMPLETED:Można zwrócić tylko zakończone transakcje (stan: ...). Repeat refund:Ta transakcja została już zwrócona.
On ROLLBACK_SELLER_WITHDRAW_FAILED money may stay with the seller, and the listing may or may not return — read the log Rollback SELLER_PAID: nie udało się odjąć kasy sprzedawcy.