Skip to content

Conversation

@Ethaga
Copy link

@Ethaga Ethaga commented Sep 9, 2025

Description

This PR updates the README.md to include troubleshooting steps for failed swap or transaction issues on KIIDEX.
Specifically, it documents how to adjust the transaction Nonce manually when a swap fails.

Type of change

  • Documentation (updates documentation on the project)

How Has This Been Tested?

  • Verified by simulating a failed swap transaction on KIIDEX.
  • Manually updating the Nonce value (e.g., setting it to 1 when suggested) successfully resolved the issue.

@coderabbitai
Copy link

coderabbitai bot commented Sep 9, 2025

Walkthrough

Adds a Troubleshooting section to the README titled "Troubleshooting Swap / Transaction Failures on KIIDEX," describing nonce-related failures and a three-step resolution: check the suggested nonce from the error or wallet, manually set the nonce to that value, and resend the transaction. Notes that this ensures proper transaction sequencing. Also applies a minor formatting tweak to the Testnet Faucet link.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Pre-merge checks (2 passed, 1 warning)

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description Check ⚠️ Warning The current description covers the summary of changes, type of change, and test steps but omits required sections from the repository’s template such as listing any dependencies and providing contextual motivation or related issue references. Please expand the PR description to reference any related issue numbers, include motivation or context for why the troubleshooting guide is needed, and explicitly list any dependencies (or state “none”) in accordance with the repository’s description template.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The title “docs: add troubleshooting guide for failed swap (Nonce fix)” succinctly highlights the core change—adding documentation for swap failures with a Nonce fix—and directly reflects the primary updates in the README without extraneous details. It uses a concise, clear phrasing with the appropriate “docs:” prefix, making it immediately obvious to reviewers that this PR adds documentation.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.

✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
README.MD (2)

59-66: Tighten nonce guidance: add authoritative check and replacement flow.
Prevents users from guessing and covers stuck-pending cases. Also keeps terminology consistent.

Apply this diff:

-### How to Fix Nonce Issues
-1. When a transaction fails, check the **suggested Nonce** from the error message or wallet prompt.  
-2. Manually set the Nonce value as suggested. For example:  
-   - If the error suggests **Nonce = 1**, then manually update the Nonce to `1`.  
-3. Confirm and resend the transaction.  
-
-This adjustment ensures the transaction is processed in the correct sequence by the network.  
+### How to fix nonce issues
+1) Determine your account’s pending nonce (recommended):  
+   • From your wallet/explorer, or via JSON‑RPC:  
+   ```bash
+   curl -s -X POST https://json-rpc.uno.sentry.testnet.v3.kiivalidator.com \
+     -H 'content-type: application/json' \
+     --data '{"jsonrpc":"2.0","id":1,"method":"eth_getTransactionCount","params":["0xYourAddress","pending"]}'
+   ```
+   Use the returned hex value as the nonce.
+2) If a tx is stuck, replace/cancel it:  
+   • Send a new tx with the same nonce and a slightly higher fee (EIP‑1559: bump maxPriorityFeePerGas/maxFeePerGas).  
+   • Or send a 0-value self‑transfer with the same nonce to cancel.  
+3) If your wallet suggests a nonce, use that exact value (e.g., “nonce = 1” → set nonce to 1) and resend.
+
+Note: Nonce is per‑account, starts at 0, and must be sequential. Skipping values will keep higher‑nonce txs queued until gaps are filled.

57-57: Consistency: lowercase “nonce”.
Use “transaction nonce” (lowercase) for standard EVM terminology.

-If you encounter a **failed transaction or swap** on [KIIDEX](https://kiidex.kiichain.io/), one possible cause is an incorrect **transaction Nonce**.  
+If you encounter a **failed transaction or swap** on [KIIDEX](https://kiidex.kiichain.io/), one possible cause is an incorrect **transaction nonce**.
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e479843 and 3eb6197.

📒 Files selected for processing (1)
  • README.MD (1 hunks)
🔇 Additional comments (1)
README.MD (1)

55-55: Nice addition: troubleshooting section is valuable for users.
Clear, discoverable heading. Good call-out to KIIDEX.

Comment on lines 71 to +73
More information about how to use our discord Faucet can be found at:

- [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
- [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix mismatch: mentions “discord Faucet” but links to Testnet Faucet docs.
Aligns wording with the actual link target.

-More information about how to use our discord Faucet can be found at:
+More information about how to use the Testnet Faucet can be found at:
 
-- [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
+- [Testnet Faucet Docs](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
More information about how to use our discord Faucet can be found at:
- [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
- [Testnet Faucet](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
More information about how to use the Testnet Faucet can be found at:
- [Testnet Faucet Docs](https://docs.kiiglobal.io/docs/build-on-kiichain/developer-tools/testnet-faucet)
🤖 Prompt for AI Agents
In README.MD around lines 71–73 the text says "discord Faucet" but the hyperlink
targets the Testnet Faucet docs; update the copy and/or link so they
match—either change the phrase to "Testnet Faucet" to match the existing URL, or
replace the URL with the correct Discord Faucet documentation link if the intent
was to reference a Discord faucet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant