Skip to content

Releases: joaquinbejar/OptionStratLib

v0.10.1

19 Nov 21:36
e1f61ba

Choose a tag to compare

Full Changelog: v0.10.0...v0.10.1

v0.10.0

18 Nov 19:43
178e996

Choose a tag to compare

Release Notes - Version 0.10.0

🎉 Major Release: Complete Error Handling Refactor

Release Date: November 18, 2025

This is a major release featuring a complete refactoring of the error handling system, transitioning from manual error implementations to the thiserror crate for improved type safety, maintainability, and developer experience.


📋 Table of Contents


🔥 Breaking Changes

Error Type System Overhaul

All error types have been converted from manual implementations to thiserror-derived enums. This affects error handling throughout the library.

Before (v0.9.x):

// Manual error implementation
impl std::error::Error for MyError {}
impl Display for MyError { ... }

// String-based errors
fn my_function() -> Result<T, String> { ... }

// Boxed dynamic errors
fn my_function() -> Result<T, Box<dyn Error>> { ... }

After (v0.10.0):

// thiserror-derived errors
#[derive(Error, Debug)]
pub enum MyError {
    #[error("Description: {field}")]
    Variant { field: String },
}

// Strongly-typed errors
fn my_function() -> Result<T, MyError> { ... }

// Unified error type
fn my_function() -> Result<T, Error> { ... }

Affected Error Types (17 total)

All of the following error types now derive from thiserror:

  1. error::Error - Unified top-level error enum
  2. ChainError - Option chain operations
  3. CurveError - Volatility curve operations
  4. GraphError - Visualization and plotting
  5. GreeksError - Greeks calculations
  6. InterpolationError - Data interpolation
  7. OptionsError - Option pricing and validation
  8. PositionError - Position management
  9. ProbabilityError - Probability analysis
  10. StrategyError - Strategy operations
  11. SurfaceError - Volatility surface operations
  12. VolatilityError - Implied volatility calculations
  13. DecimalError - Decimal operations (Positive type)
  14. OhlcvError - CSV data operations
  15. MetricsError - Performance metrics
  16. SimulationError - Monte Carlo simulations
  17. ExitPolicyError - Exit policy validation

Error Variant Changes

Many error variants have been renamed or restructured for consistency:

// Example: PositionError
// Before: Multiple separate error types
// After: Unified with clear variants
pub enum PositionError {
    #[error("Strategy error: {0}")]
    StrategyError(StrategyErrorKind),
    
    #[error("Validation error: {0}")]
    ValidationError(PositionValidationErrorKind),
    
    #[error("Limit error: {0}")]
    LimitError(PositionLimitErrorKind),
}

Removed Types

  • Box<dyn Error> - Replaced with strongly-typed error enums
  • Result<T, String> - Replaced with Result<T, Error> or specific error types
  • Manual Error trait implementations - All replaced with #[derive(Error)]

✨ New Features

1. Unified Error Type

A new top-level Error enum that encompasses all library errors:

use optionstratlib::error::Error;

fn main() -> Result<(), Error> {
    // All library operations can return this unified error type
    let strategy = create_strategy()?;
    let analysis = strategy.analyze()?;
    Ok(())
}

2. Enhanced Prelude Module

The prelude module now exports all commonly used types, traits, and errors:

use optionstratlib::prelude::*;

// Now includes:
// - All core types (Positive, ExpirationDate, etc.)
// - All strategy types
// - All error types
// - Tracing macros (trace!, debug!, info!, warn!, error!)
// - Common traits

3. Automatic Error Conversions

All error types implement From traits for seamless conversion:

// Automatic conversion from specific errors to unified Error type
fn my_function() -> Result<(), Error> {
    let option = create_option()?;  // OptionsError -> Error
    let greeks = calculate_greeks()?;  // GreeksError -> Error
    Ok(())
}

4. Transparent Error Wrapping

Errors from external crates are transparently wrapped:

#[derive(Error, Debug)]
pub enum MyError {
    #[error(transparent)]
    Io(#[from] std::io::Error),
    
    #[error(transparent)]
    Csv(#[from] csv::Error),
}

🚀 Improvements

Code Quality

  1. Reduced Boilerplate

    • Eliminated ~2,000 lines of manual error implementation code
    • Automatic Display, Debug, and Error trait implementations
    • Cleaner, more maintainable error definitions
  2. Type Safety

    • Replaced string-based errors with strongly-typed enums
    • Compile-time error checking
    • Better IDE support and autocomplete
  3. Consistency

    • Uniform error message formatting across the library
    • Consistent error variant naming conventions
    • Standardized error construction patterns

Error Messages

All error messages have been standardized and improved:

// Clear, descriptive error messages
#[error("Invalid strike price {strike}: {reason}")]
InvalidStrike { strike: Positive, reason: String },

#[error("Maximum positions reached: {current}/{maximum}")]
MaxPositionsReached { current: usize, maximum: usize },

#[error("Break-even calculation failed: {0}")]
CalculationError(BreakEvenErrorKind),

Performance

  • Zero-cost abstractions: thiserror generates optimal code
  • No runtime overhead: All error handling is compile-time
  • Reduced allocations: More efficient error propagation

🐛 Bug Fixes

Error Handling Fixes

  1. Fixed error message formatting inconsistencies

    • Standardized prefixes across all error types
    • Corrected debug format representations
    • Fixed error variant expectations in tests
  2. Fixed error conversion issues

    • Proper From implementations for all error types
    • Correct transparent error wrapping
    • Fixed circular dependency issues
  3. Fixed test assertions

    • Updated 50 test assertions to match new error formats
    • Fixed error variant expectations
    • Corrected panic message expectations

Example Fixes

  1. Updated 97 example files

    • Fixed imports to use new error types
    • Updated main function signatures to return Result<(), Error>
    • Added proper error handling
  2. Fixed doctest compilation

    • Corrected import paths in documentation examples
    • Fixed type annotations
    • Updated example code to use new error types

📚 Documentation

New Documentation

  1. Comprehensive error documentation

    • Each error type has detailed documentation
    • Clear descriptions of error variants
    • Usage examples for error handling
  2. Migration guide (see below)

    • Step-by-step migration instructions
    • Before/after code examples
    • Common patterns and best practices
  3. Enhanced API documentation

    • Improved error documentation in all public APIs
    • Clear error return types
    • Examples of error handling

Updated Examples

All 97 example files have been updated to demonstrate:

  • Proper error handling with the new error types
  • Use of the unified Error type
  • Best practices for error propagation

✅ Testing

Test Coverage

  • 3,671 total tests passing (100% success rate)
    • 3,269 unit tests
    • 224 integration tests
    • 178 doctests

Tests Fixed

  • 50 tests updated to work with new error system
    • 37 unit tests in error modules
    • 11 integration tests
    • 2 doctests

Test Improvements

  1. Better error assertions

    • Tests now check error variants instead of string messages
    • More robust and maintainable tests
    • Less brittle to error message changes
  2. Comprehensive error coverage

    • All error types have dedicated test modules
    • Error conversion tests
    • Error display format tests

🔄 Migration Guide

Step 1: Update Error Imports

Before:

use optionstratlib::error::position::PositionError;
use optionstratlib::error::strategies::StrategyError;

After:

use optionstratlib::prelude::*;
// or
use optionstratlib::error::{Error, PositionError, StrategyError};

Step 2: Update Function Signatures

Before:

fn my_function() -> Result<MyType, String> {
    Err("Something went wrong".to_string())
}

fn another_function() -> Result<MyType, Box<dyn std::error::Error>> {
    // ...
}

After:

fn my_function() -> Result<MyType, Error> {
    Err(Error::Position(PositionError::validation_error(
        "field",
        "Something went wrong"
    )))
}

fn another_function() -> Result<MyType, PositionError> {
    // ...
}

Step 3: Update Error Construction

Before:

// String errors
return Err(format!("Invalid value: {}", value));

// Manual error construction
return Err(Box::new(MyError::new("message")));

After:

// Use error constructors
return Err(PositionError::validation_error("field", "Invalid value"));

// Or use error variants directly
return Err(PositionError::ValidationError(
    PositionValidationErrorKind::InvalidSize {
        size: value,
        reason: "Must be positive".to_string(),
    }
));

Step 4: Update Error Handling

Before:

match result {
    Ok(value) => value,
    Err(e) => {
        println!("Error: {}", e);
        return Err(e.to_string());
    }
}

After:

match result {
    Ok(value) => value,
    Err(e) => {
...
Read more

v0.9.2

10 Nov 12:16
3df9dad

Choose a tag to compare

Bump version to v0.9.2. Update edition to 2024 in `Cargo.toml`.

v0.9.1

10 Nov 12:01
5dab3a2

Choose a tag to compare

Bump version to v0.9.2. Update documentation, metadata, and library v…

v0.9.0

09 Nov 05:45
d41c770

Choose a tag to compare

OptionStratLib v0.9.0 Release Notes

Major Release: Advanced Simulation Framework

We're excited to announce OptionStratLib v0.9.0, a major update that introduces a comprehensive simulation and backtesting framework for option trading strategies. This release adds powerful tools for strategy evaluation, performance analysis, and risk assessment through Monte Carlo simulations.


New Features

1. Simulate Trait for Strategy Testing

Introduced a new Simulate trait that enables systematic testing of option strategies using random walk simulations:

  • Trait Implementation: All major strategies (ShortPut, ShortCall, LongPut, LongCall) now implement the Simulate trait
  • Monte Carlo Integration: Seamless integration with the existing Monte Carlo simulation framework
  • Comprehensive Metrics: Tracks P&L, holding periods, exit reasons, and risk metrics
  • Progress Tracking: Built-in progress bars for real-time simulation feedback
pub trait Simulate<X, Y> {
    fn simulate(
        &self,
        sim: &Simulator<X, Y>,
        exit: ExitPolicy,
    ) -> Result<SimulationStats, Box<dyn Error>>;
}

2. Exit Policy System

New flexible exit policy framework for defining strategy exit conditions:

  • Profit/Loss Thresholds: ProfitPercent, LossPercent, ProfitAmount, LossAmount
  • Time-Based Rules: TimeSteps, Expiration
  • Composite Logic: And, Or for combining multiple conditions
  • Comprehensive Testing: 100% test coverage with edge case handling

Example:

let exit_policy = ExitPolicy::Or(vec![
    ExitPolicy::ProfitPercent(dec!(0.5)),  // 50% profit
    ExitPolicy::LossPercent(dec!(1.0)),    // 100% loss
    ExitPolicy::Expiration,                // Or expiration
]);

3. Enhanced SimulationStats

Complete refactor of simulation statistics with rich reporting capabilities:

  • Aggregate Metrics: Win rate, average P&L, median P&L, standard deviation
  • Distribution Analysis: Max profit, max loss, P&L percentiles
  • Exit Analysis: Distribution of exit reasons and holding periods
  • Colored Output: Red/green color coding for losses/profits, blue headers
  • Individual Results: Detailed per-simulation breakdown

4. Progress Bar Integration

Built-in progress tracking for long-running simulations:

  • Real-time Feedback: Visual progress bars with ETA
  • Automatic Integration: Progress bars embedded in Simulate trait
  • Clean Output: Spinner animations and elapsed time tracking
  • Dependency Added: indicatif crate for progress visualization

5. Volatility Utilities

New volatility helper functions for simulation timeframes:

  • volatility_for_dt: De-annualize volatility for specific time intervals
  • Flexible Timeframes: Support for minutes, hours, days, weeks, months, years
  • Accurate Calculations: Proper scaling for different time periods

6. OpenAPI Integration

Enhanced API documentation support:

  • ToSchema Derivation: Added across key structs for OpenAPI/Swagger
  • Better Documentation: Improved API discoverability and integration
  • utoipa Support: Full compatibility with utoipa framework

New Examples

Strategy Simulation Examples

  1. short_put_strategy_simulation.rs

    • Complete Short Put strategy evaluation
    • 1000 simulations with random walks
    • Detailed P&L analysis and exit reason distribution
    • PNG visualization output
  2. long_call_strategy_simulation.rs

    • Long Call strategy performance testing
    • Custom volatility modeling with mean reversion
    • Comprehensive statistics and visualizations
  3. exit_policy_example.rs

    • Demonstrates all exit policy types
    • Shows composite logic (And/Or)
    • Educational resource for policy configuration
  4. strategy_simulator.rs

    • Generic strategy simulator framework
    • Extensible for custom strategies
    • Position tracking and P&L evaluation
  5. position_simulator.rs

    • Position-level simulation capabilities
    • Multi-leg strategy support
    • Risk metrics calculation

🔧 Improvements

Strategy Enhancements

  • Expiration Handling: Improved expiration logic for all strategies
  • P&L Calculation: More accurate realized/unrealized P&L tracking
  • Premium Tracking: Min/max/average premium monitoring during simulations
  • Exit Detection: Precise exit condition triggering

Testing Coverage

  • +500 New Tests: Comprehensive test coverage for new features
  • Edge Case Handling: Tests for None values, empty data, boundary conditions
  • Strategy Tests: Full coverage of Simulate trait implementations
  • Exit Policy Tests: All policy types and combinations tested

Code Quality

  • Formatted Code: Consistent formatting across all modules
  • Documentation: Enhanced inline documentation and examples
  • Error Handling: Improved error messages and Result types
  • Type Safety: Stronger type guarantees with Rust's type system

Statistics

Files Changed:    33 files
Lines Added:      +4,844
Lines Removed:    -144
Net Change:       +4,700 lines
New Tests:        +500 tests
Total Tests:      3,270 tests (all passing)

Breaking Changes

SimulationStats Refactor

The simulation framework now returns SimulationStats instead of Vec<PnL>:

Before (v0.8.x):

fn simulate(&self, sim: &Simulator) -> Vec<PnL>

After (v0.9.0):

fn simulate(&self, sim: &Simulator, exit: ExitPolicy) -> Result<SimulationStats, Box<dyn Error>>

Migration Guide:

  • Update trait implementations to return SimulationStats
  • Add ExitPolicy parameter to simulation calls
  • Use stats.results to access individual SimulationResult objects
  • Access aggregate metrics via stats.average_pnl, stats.win_rate, etc.

Dependencies

New Dependencies

  • indicatif (0.17): Progress bars and spinners
  • Enhanced workspace dependency management

Updated Dependencies

All dependencies remain compatible with Rust 2024 edition.


Bug Fixes

  • Fixed P&L calculation edge cases with None values
  • Improved expiration date handling in simulations
  • Corrected average holding period calculation
  • Fixed max profit/loss tracking logic

Documentation

  • Updated README with v0.9.0 features
  • Added comprehensive inline documentation
  • New example programs with detailed comments
  • Enhanced API documentation for OpenAPI

Use Cases

This release enables:

  1. Strategy Backtesting: Test strategies against historical-like price movements
  2. Risk Assessment: Understand worst-case scenarios and drawdowns
  3. Performance Analysis: Compare strategies with statistical rigor
  4. Parameter Optimization: Find optimal strike prices, exit conditions
  5. Educational Tools: Learn option strategy behavior through simulation

Installation

[dependencies]
optionstratlib = "0.9.0"

Or update your existing installation:

cargo update optionstratlib

Support


Full Changelog: v0.8.0...v0.9.0


Released: November 9, 2025
License: MIT

v0.8.2

06 Nov 17:45
341379a

Choose a tag to compare

v0.8.2 - Bug Fix Release

Fixed

  • Critical bug in build_chain function: The chain_size parameter in OptionChainBuildParams was not being used to control the actual number of strikes generated. The function had a hardcoded limit of 200 strikes instead of respecting the user-specified chain_size. Now the chain correctly generates exactly chain_size strikes above and below the ATM strike (total: 2 * chain_size + 1).
    • Fixed loop logic in src/chains/chain.rs to properly check against chain_size parameter
    • Updated all affected tests to reflect correct behavior
    • Updated RND calculation tests with correct expected values for properly-sized chains

Impact

This fix ensures that option chains are generated with the exact size requested by users, which is critical for:

  • Accurate risk-neutral density (RND) calculations
  • Proper memory usage and performance
  • Predictable behavior in production systems
  • Correct strike range coverage for analysis

Thanks to @bayareacoder for reporting this issue.


v0.8.1

26 Oct 11:49
3062d42

Choose a tag to compare

Release Notes: Version 0.8.1 – OpenAPI Integration & PnL Simulation Upgrades

Summary

This release focuses on first-class OpenAPI documentation via utoipa::ToSchema, a new modular PnL and portfolio management layer, and quality-of-life improvements across CI/CD. It also adds an interactive Monte Carlo simulation HTML visualization to make portfolio outcomes easier to explore.


What's New

  • OpenAPI via utoipa::ToSchema: Multiple structs and enums now derive ToSchema for automatic and consistent OpenAPI schema generation.
  • New balance Module: Introduces Balance, MarginInfo, and Portfolio with methods to manage option positions, compute PnL, and track portfolio metrics.
  • PnL Comparison: diff_position_pnl enables side‑by‑side comparison of PnL outcomes between positions.
  • Underlying Asset Typing: New UnderlyingAssetType enum with fmt::Display for cleaner, human‑readable output.
  • Interactive Visualization: Added Monte Carlo Simulation HTML for interactive exploration of simulation runs and distributions.

Enhancements

  • Refined API Models
    • Replaced nested tuples with a dedicated struct for clarity and stronger typing.
    • Refactored DeltaAdjustment::SameSize for readability and maintainability.
  • Validation & Safety
    • Added explicit error checks and validation for position attributes in PnL calculations.
  • Serialization Improvements
    • OptionData now uses #[serde(skip_serializing_if = "Option::is_none")] (replacing #[serde(skip)]) so optional fields are omitted only when None, improving JSON accuracy and OpenAPI compatibility.
  • CI/CD Robustness
    • Rust workflows now include retry mechanisms, network diagnostics, and fallback installation steps.
    • Code coverage workflow hardened with error handling and resiliency settings.

Bug Fixes

  • Focus of this release is feature additions and hardening; no user‑reported functional bugs were targeted.
  • CI reliability fixes reduce intermittent failures in coverage and Rust toolchain setup.

Breaking Changes

  • None expected. APIs remain source‑compatible.
  • Behavior note: JSON output for OptionData now omits only None optionals. If any downstream consumers relied on explicitly present null fields or on fields being universally skipped, review payload handling.

Documentation Updates

  • Version bumped to v0.8.1 throughout the docs.
  • OpenAPI integration notes and examples updated for utoipa usage.
  • Added references to the Monte Carlo Simulation HTML visualization for interpretation guidance.

Migration Notes

  • OpenAPI Generation
    • Ensure your OpenAPI build step includes utoipa features and picks up ToSchema derives.
    • Regenerate schemas to reflect the refined structures (e.g., dedicated structs replacing nested tuples).
  • Serialization Behavior
    • If clients expect optional keys to always appear, update them to tolerate omitted fields when values are None.
  • Build & CI
    • Run a fresh toolchain sync (rustup update) and cargo update to align with the workflow changes.
    • If you pin CI actions, adopt the new retry/fallback steps or ensure equivalent robustness.
  • Validation
    • Review any custom PnL logic for stricter position attribute checks to avoid early‑fail errors introduced by new validations.

Release Links

v0.8.0

22 Sep 11:39
d8688b8

Choose a tag to compare

Release Notes: Version 0.8.0 - Portfolio Management, PnL Enhancements, and OpenAPI Integration

Summary

Version 0.8.0 introduces major improvements to the library’s portfolio management and profit & loss (PnL) capabilities. This release adds a new balance module, improves error handling in PnL calculations, and integrates OpenAPI schema generation via utoipa::ToSchema. These updates make the library more robust, user-friendly, and ready for broader API documentation and visualization.


What's New

  • Balance & Portfolio Management

    • New balance module with:
      • Balance for account tracking.
      • MarginInfo for margin requirement handling.
      • Portfolio for managing option positions and portfolio-level calculations.
    • Methods for managing positions, calculating values, and performing portfolio operations.
    • Comprehensive unit tests for validation.
  • PnL Calculation

    • Added diff_position_pnl method to compare positions and calculate PnL.
    • Expanded validation and error handling for mismatched position attributes.
  • Underlying Asset Support

    • Introduced UnderlyingAssetType enum with fmt::Display for improved formatting and usability.
  • OpenAPI Schema Integration

    • Added utoipa::ToSchema implementations across multiple structs and enums for automatic OpenAPI documentation.
    • Refactored DeltaAdjustment::SameSize for better readability.
    • Replaced nested tuple types with dedicated structs for improved clarity.

Enhancements

  • Strengthened validation logic to ensure safer PnL computations.
  • Improved serde serialization for updated structs and enums.
  • Increased test coverage for portfolio operations and error scenarios.
  • More maintainable codebase with clearer struct definitions.

Bug Fixes

  • Corrected inconsistencies in PnL calculations for mismatched positions.
  • Fixed serialization/deserialization issues caused by refactored tuple structures.

Breaking Changes

  • Struct Refactoring: Nested tuple types have been replaced by dedicated structs.
    ⚠️ This may affect serialization/deserialization in existing codebases.

Documentation Updates

  • Updated version references to v0.8.0.
  • Added OpenAPI schema integration documentation via utoipa::ToSchema.
  • Expanded unit test documentation to cover new modules (balance, portfolio management).

Migration Notes

  • Update your dependency to version v0.8.0.
  • Review any usage of tuple-based structures and migrate to the new named structs.
  • Ensure your OpenAPI tooling is compatible with utoipa schema generation.

Release Links

v0.7.3

19 Sep 06:07
7628104

Choose a tag to compare

Release Notes: Version v0.7.3 – Probability Refactor, Structured Logging, and Visualization Upgrades

Summary

This release tightens the core probability engine by reading parameters directly from option properties, standardizes logging with tracing::info!, and upgrades profit/loss charting for key strategies. We’ve also cleaned up unused modules, reorganized visualization tests, and improved error handling and documentation. The result is clearer code, more accurate analytics, and easier debugging.


What's New

  • Probability via Option Properties
    Probability calculations now pull expiration, risk-free rate, and underlying price directly from each option, improving correctness and reducing duplication.
  • Visualization Upgrades
    Refreshed profit/loss charts for:
    • Iron Condor
    • Long Butterfly
    • Short Butterfly
  • Strategy Metrics & Params
    Strategies and simulations updated to incorporate the new probability metrics and parameters.

Enhancements

  • Structured Logging
    Replaced all println! usages with tracing::info! across the codebase and tests for consistent, structured logs.
  • Long Butterfly Loss Handling
    Improved handling of unbounded loss ranges in LongButterflySpread, with clearer docs and a debug test for real-world validation.
  • Curves & Utilities
    • Simplified diff mappings in the curves module.
    • Refined show docstring and median calculation logic.
  • Tooling & CI
    Added --workspace to cargo clippy in the Makefile for consistent linting across all packages.

Bug Fixes

  • Error Conversion
    Corrected From<Box<dyn Error>> implementation in InterpolationError (fixed type syntax).
  • Visualization Tests
    Stabilized visualization test layout and names to reduce ambiguity and improve discoverability.

Breaking Changes

No API-breaking changes detected.
Note: If you relied on println! output in scripts or log parsing, switch to a tracing subscriber to capture logs (see Migration Notes).


Documentation Updates

  • Clarified probability calculations and how option properties are consumed.
  • Expanded documentation for butterfly strategies (including unbounded loss ranges).
  • Reorganized visualization test documentation under tests/unit/visualization for clearer navigation.

Migration Notes

1) Adopt tracing in your binaries/tests

If you previously scraped println! output, set up a tracing subscriber:

use tracing_subscriber::{fmt, EnvFilter};

fn main() {
    let filter = EnvFilter::try_from_default_env()
        .unwrap_or_else(|_| EnvFilter::new("info"));
    fmt().with_env_filter(filter).init();

    // your app...
}

Run with environment control as needed:

RUST_LOG=info cargo run
RUST_LOG=debug cargo test -p your_crate -- --nocapture

2) Linting

cargo clippy now runs with --workspace. If you have custom CI scripts, ensure they do not redundantly add this flag.

3) Visualization Tests

Visualization tests have moved to tests/unit/visualization. Update any local paths or scripts that refer to the old locations.

No additional configuration changes are required for the probability refactor; it is internal and backward-compatible.

v0.7.2

13 Sep 09:11
fa6f629

Choose a tag to compare

Release Notes: Version 0.7.2- Enhanced OptionChain Comparisons & Display

Summary

This beta release focuses on improving the comparability, formatting, and display capabilities of the OptionChain module. It introduces equality and ordering traits, refines visualization through standardized formatting, and adds user-facing features like colored terminal output and strike price highlighting. These updates streamline developer workflows and enhance the readability of outputs.


What's New

  • Equality & Ordering
    • Added PartialEq and Ord implementations for OptionChain to enable robust sorting and comparison.
    • Refactored PartialEq for ExpirationDate to support mixed variant comparisons with a get_days fallback.
  • User-Facing Enhancements
    • Introduced OptionChain.show() for colored terminal output.
    • Highlighted strike prices that are multiples of 25 in yellow for quick visual scanning.
    • Added is_multiple method in Positive for divisibility checks.

Enhancements

  • Formatting Improvements

    • Refactored fmt::Display for improved readability and alignment.
    • Adjusted symbol header spacing and switched table style to FORMAT_BOX_CHARS.
    • Shortened volume column label in OptionChain tables.
  • Standardization

    • Integrated pretty_simple_display, replacing custom display logic.
    • Introduced consistent formatting with DebugPretty and DisplaySimple across OptionChain and strategy structs.
  • Codebase Cleanup

    • Removed the display module, redundant macros, and unused visualization tests.
    • Cleaned up Bull Call Spread visualization script and unnecessary comments in plotly.rs.

Bug Fixes

  • Corrected inconsistencies in table formatting and spacing.
  • Standardized expiration date handling in tests to remove edge case mismatches.
  • Fixed redundant formatting assertions to align with the new display logic.

Documentation Updates

  • Updated internal comments and test descriptions for clarity.
  • Documented new methods (is_multiple, OptionChain.show()) with usage examples.

Migration Notes

  • Breaking Change: The custom display module and related macros/tests have been removed.
  • Projects relying on the old display API should migrate to pretty_simple_display and use DebugPretty / DisplaySimple instead.
  • No changes required for existing strategy logic or option chain analysis beyond display formatting.

Release Links