-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
I have an issue redeeming tokens:
it works smoothly on some markets (e.g., BTC 15 Minutes),
but it doesn’t work at all on football markets.
I’m using the same code in both cases:
const ctfAddress = "0x4d97dcd97ec945f40cf65f87097ace5ea0476045";
const collateralToken = "0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174";
const parentCollectionId = "0x0000000000000000000000000000000000000000000000000000000000000000";
const indexSets: number[] = [1, 2]; //any combination here was used - restricted to owned tokens, and generic 1 and 2 as well
const redeemTx: SafeTransaction = {
to: ctfAddress,
operation: OperationType.Call,
data: ctfInterface.encodeFunctionData("redeemPositions", [
collateralToken,
parentCollectionId,
conditionId,
indexSets
]),
value: "0"
};
const response = await client.execute(
[redeemTx],
"Simple redeem test"
);
In both cases the transactions are created and appear on Polygonscan as successful, but for football markets the positions remain unredeemed.
There is a difference on the logs on polygonscan; for football there seem to be 4 "steps":
- SafeMultiSigTransaction (address to, uint256 value, bytes data, uint8 operation, uint256 safeTxGas, uint256 baseGas, uint256 gasPrice, address gasToken, address refundReceiver, bytes signatures, bytes additionalInfo)[View Source]
- PayoutRedemption (index_topic_1 address redeemer, index_topic_2 address collateralToken, index_topic_3 bytes32 parentCollectionId, bytes32 conditionId, uint256[] indexSets, uint256 payout)[View Source]
- ExecutionSuccess (bytes32 txHash, uint256 payment)[View Source]
- LogFeeTransfer (index_topic_1 address token, index_topic_2 address from, index_topic_3 address to, uint256 amount, uint256 input1, uint256 input2, uint256 output1, uint256 output2)[View Source]
while bitcoin market (the working one) is like:
- SafeMultiSigTransaction (address to, uint256 value, bytes data, uint8 operation, uint256 safeTxGas, uint256 baseGas, uint256 gasPrice, address gasToken, address refundReceiver, bytes signatures, bytes additionalInfo)[View Source]
- TransferSingle (index_topic_1 address operator, index_topic_2 address from, index_topic_3 address to, uint256 id, uint256 value)[View Source]
- TransferSingle (index_topic_1 address operator, index_topic_2 address from, index_topic_3 address to, uint256 id, uint256 value)[View Source]
- Transfer (index_topic_1 address from, index_topic_2 address to, uint256 value)
- PayoutRedemption (index_topic_1 address redeemer, index_topic_2 address collateralToken, index_topic_3 bytes32 parentCollectionId, bytes32 conditionId, uint256[] indexSets, uint256 payout)
- ExecutionSuccess (bytes32 txHash, uint256 payment)
- LogFeeTransfer (index_topic_1 address token, index_topic_2 address from, index_topic_3 address to, uint256 amount, uint256 input1, uint256 input2, uint256 output1, uint256 output2)
Metadata
Metadata
Assignees
Labels
No labels