Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions .github/workflows/integration_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ on:
name: Integration Test

env:
RIPPLED_DOCKER_IMAGE: rippleci/rippled:develop
# Pin to known-good digest; rippleci/rippled:develop broke after 2026-04-01
RIPPLED_DOCKER_IMAGE: rippleci/rippled:develop@sha256:328175bf14b7b83db9e5e6b50c7458bf828b02b2855453efc038233094aa8d85

jobs:
integration_test:
Expand Down Expand Up @@ -41,10 +42,22 @@ jobs:

- name: Wait for rippled to be healthy
run: |
until docker inspect --format='{{.State.Health.Status}}' rippled-service | grep -q healthy; do
echo "Waiting for rippled to be ready..."
for i in $(seq 1 30); do
if ! docker ps -q -f name=rippled-service | grep -q .; then
echo "Container exited unexpectedly"
docker logs rippled-service 2>&1 || true
exit 1
fi
STATUS=$(docker inspect --format='{{.State.Health.Status}}' rippled-service 2>/dev/null || echo "unknown")
echo "Attempt $i/30: $STATUS"
if [ "$STATUS" = "healthy" ]; then
exit 0
fi
sleep 2
done
echo "Timed out waiting for rippled"
docker logs rippled-service 2>&1 || true
exit 1

- uses: dtolnay/rust-toolchain@stable

Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed

## [[v1.2.0]]

### Changed

- Unified transaction metadata types: `TransactionMetadata` and related metadata structs now live in `xrpl::models::transactions::metadata`. The previous module path `xrpl::models::results::metadata` is retained as a deprecated re-export for backwards compatibility and will be removed in a future major release. Update imports to `xrpl::models::transactions::metadata::TransactionMetadata`.

## [[v1.1.0]]

### Added
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "xrpl-rust"
version = "1.1.0"
version = "1.2.0"
edition = "2021"
authors = [
"Tanveer Wahid <tan@wahid.email>",
Expand Down
6 changes: 3 additions & 3 deletions src/models/results/account_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ use serde_json::Value;
use crate::models::requests::Marker;
use crate::models::{XRPLModelException, XRPLModelResult};

use super::{
exceptions::XRPLResultException, metadata::TransactionMetadata, XRPLResponse, XRPLResult,
};
use crate::models::transactions::metadata::TransactionMetadata;

use super::{exceptions::XRPLResultException, XRPLResponse, XRPLResult};

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
#[serde(untagged)]
Expand Down
223 changes: 0 additions & 223 deletions src/models/results/metadata.rs

This file was deleted.

16 changes: 15 additions & 1 deletion src/models/results/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
/// Deprecated: re-export for backwards compatibility.
///
/// `TransactionMetadata` and related metadata types were moved to
/// [`crate::models::transactions::metadata`]. This shim keeps pre-1.2.0
/// imports such as `xrpl::models::results::metadata::TransactionMetadata`
/// working, but new code should import directly from
/// `crate::models::transactions::metadata` instead.
#[deprecated(
since = "1.2.0",
note = "TransactionMetadata moved to models::transactions::metadata; update your imports"
)]
pub mod metadata {
pub use crate::models::transactions::metadata::*;
}

pub mod account_channels;
pub mod account_currencies;
pub mod account_info;
Expand All @@ -20,7 +35,6 @@ pub mod ledger_current;
pub mod ledger_data;
pub mod ledger_entry;
pub mod manifest;
pub mod metadata;
pub mod nft_buy_offers;
pub mod nft_info;
pub mod nft_offer;
Expand Down
7 changes: 4 additions & 3 deletions src/models/results/nftoken.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
use alloc::borrow::Cow;
use alloc::{borrow::Cow, vec::Vec};
use core::convert::TryFrom;

use serde::{Deserialize, Serialize};

use super::{metadata::TransactionMetadata, tx::TxVersionMap};
use super::tx::TxVersionMap;
use crate::models::transactions::metadata::TransactionMetadata;
use crate::models::{XRPLModelException, XRPLModelResult};

/// Result type for NFTokenMint transaction
Expand All @@ -30,7 +31,7 @@ pub struct NFTokenCreateOfferResult<'a> {
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub struct NFTokenCancelOfferResult<'a> {
/// The NFTokenIDs of all tokens affected by the cancellation
pub nftoken_ids: Cow<'a, [Cow<'a, str>]>,
pub nftoken_ids: Vec<Cow<'a, str>>,
/// The complete transaction metadata
#[serde(flatten)]
pub meta: TransactionMetadata<'a>,
Expand Down
2 changes: 1 addition & 1 deletion src/models/results/transaction_entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use alloc::borrow::Cow;

use serde::{Deserialize, Serialize};

use super::metadata::TransactionMetadata;
use crate::models::transactions::metadata::TransactionMetadata;

/// Response format for the transaction_entry method.
///
Expand Down
4 changes: 3 additions & 1 deletion src/models/results/tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ use crate::models::{
XRPLModelException, XRPLModelResult,
};

use super::{metadata::TransactionMetadata, XRPLResponse, XRPLResult};
use crate::models::transactions::metadata::TransactionMetadata;

use super::{XRPLResponse, XRPLResult};

#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
#[serde(untagged)]
Expand Down
Loading
Loading