Skip to content

Conversation

@ckeshava
Copy link
Collaborator

High Level Overview of Change

This PR aims to remove snippets-related files from the javascript client library. These files have been migrated to a new location.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

  • New feature (non-breaking change which adds functionality)

  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

  • Refactor (non-breaking change that only restructures code)
    This PR aims to remove code, no new features are added.

  • Tests (You added tests for code that already exists, or your new feature included in this PR)

  • Documentation Updates

  • Release

Did you update HISTORY.md?

  • Yes
    This change does not affect external API. However, for the sake of transparent communication, the note in the Changelog will be helpful.
  • [] No, this change does not impact library users

Test Plan

The Github Actions CI will be updated. The mandatory run of snippets CI is no longer necessary. No new tests are added.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jul 28, 2025

Walkthrough

This change removes the entire XRPL code snippets subsystem, including all TypeScript snippet example files, related documentation, TypeScript configuration, ESLint and build script overrides, and the associated GitHub Actions workflow job. All snippet-related scripts and references are eliminated from the package configuration and tooling.

Changes

Cohort / File(s) Change Summary
GitHub Actions Workflow
.github/workflows/nodejs.yml
Removes the snippets job, eliminating all snippet build and test steps from CI.
ESLint & TypeScript Config
packages/xrpl/.eslintrc.js, packages/xrpl/tsconfig.eslint.json
Removes overrides and file inclusions for snippet files from ESLint and TypeScript linting configuration.
Build & NPM Scripts
packages/xrpl/package.json
Removes all snippet-related scripts from the build process and NPM scripts.
Documentation & Config
packages/xrpl/snippets/README.md, packages/xrpl/snippets/tsconfig.json
Deletes the snippet README and TypeScript project configuration.
Snippet Source Files
packages/xrpl/snippets/src/claimPayChannel.ts, .../getTransaction.ts, .../multisigning.ts, .../partialPayment.ts, .../paths.ts, .../permissionedDEX.ts, .../reliableTransactionSubmission.ts, .../sendEscrow.ts, .../setRegularKey.ts
Deletes all TypeScript snippet example files demonstrating various XRPL features.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~15 minutes

  • The changes span multiple configuration files, scripts, and the removal of several source files, but are conceptually straightforward as they focus on subsystem removal.

Possibly related PRs

Poem

A bunny hops where snippets lay,
Sweeping old code clean away.
No more samples, no more test,
The docs and scripts now take a rest.
With configs trimmed and actions neat,
The garden’s rows are now complete!
🐇✨

Note

⚡️ Unit Test Generation is now available in beta!

Learn more here, or try it out under "Finishing Touches" below.


📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0744d0d and 6cad766.

📒 Files selected for processing (1)
  • packages/xrpl/package.json (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/xrpl/package.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: semgrep-cloud-platform/scan
  • GitHub Check: browser (22.x)
  • GitHub Check: integration (20.x)
  • GitHub Check: integration (22.x)
  • GitHub Check: unit (20.x)
  • GitHub Check: build-and-lint (22.x)
  • GitHub Check: unit (22.x)
  • GitHub Check: Analyze (javascript)
✨ 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
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

* Fail faster on `tem` errors with `submitAndWait`
* Improved type-checking in models
* Fix issue with some transactions that would crash in validation
* Code snippets are removed from the xrpl.js client library. They have been [moved to a different location](https://github.com/XRPLF/xrpl-dev-portal/tree/master/_code-samples).
Copy link
Collaborator

Choose a reason for hiding this comment

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

This doesn't need to go in the HISTORY, since it won't affect downstream library users

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I agree that it won't affect users. However, if somebody comes around looking for these snippets in xrpl.js, shouldn't we direct them to the correct location?

Copy link
Collaborator

Choose a reason for hiding this comment

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

The README is a better place for that

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

change reverted in 62b0e71

@Patel-Raj11 Patel-Raj11 self-requested a review July 28, 2025 21:12
Copy link
Collaborator

@Patel-Raj11 Patel-Raj11 left a comment

Choose a reason for hiding this comment

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

LGTM!

@ckeshava ckeshava merged commit de28f40 into XRPLF:main Aug 6, 2025
12 checks passed
@coderabbitai coderabbitai bot mentioned this pull request Aug 13, 2025
9 tasks
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.

4 participants