Carles Sentis
|
ee48c1c8ac
Enhance documentation and project structure - Added a comprehensive documentation index for quick navigation and updated project structure details to reflect new data storage and enhanced stop loss management features. Improved clarity in module responsibilities and included new integration notes for unified position tracking.
|
4 gün önce |
Carles Sentis
|
5321ab723d
Enhance stop loss cancellation logic in MarketMonitor - Implemented edge case handling to wait for potential fills before cancelling stop losses. Added checks for recent fills to prevent unnecessary cancellations, improving order management accuracy. Enhanced logging for better traceability of order statuses and actions taken.
|
4 gün önce |
Carles Sentis
|
c31e47261d
Refactor order status update logic in TradingEngine and TradingStats - Updated the method for updating order statuses to include a new parameter for setting the exchange order ID directly. Improved logging to provide clearer feedback on order updates, enhancing overall traceability and debugging capabilities.
|
4 gün önce |
Carles Sentis
|
6e7803b227
Refactor stop loss retrieval logic in InfoCommands - Enhanced the method for identifying pending stop losses by first retrieving all pending trigger orders and then filtering them based on type and parent order reference ID. Improved logging for better debugging and clarity in matching stop losses to their respective orders.
|
4 gün önce |
Carles Sentis
|
14ae0d889a
Enhance stop loss order logic in TradingEngine - Implemented smart stop loss functionality to determine order type (market or limit) based on current market price relative to stop price. Improved logging for order placement and error handling, ensuring clarity in execution status and enhancing overall stop loss management.
|
4 gün önce |
Carles Sentis
|
a4cee8b091
Refactor stop loss retrieval in InfoCommands - Updated the method for fetching pending stop losses to streamline the logic and improve readability. The new implementation directly filters pending stop losses by parent order reference ID, enhancing clarity in the code and maintaining consistent user notifications regarding stop loss statuses.
|
4 gün önce |
Carles Sentis
|
c76ba56746
Refactor price formatting in InfoCommands and TradingCommands - Integrated the PriceFormatter for consistent price display across order and trade notifications. Updated relevant sections to utilize the formatter, enhancing clarity in user messages regarding order details and trade confirmations.
|
4 gün önce |
Carles Sentis
|
cf7ab53c06
Implement price formatting utilities and integrate into trading commands - Added a new PriceFormatter class for handling price formatting with exchange-specific precision. Updated InfoCommands and TradingCommands to utilize the new formatter for displaying prices, enhancing clarity and consistency in user notifications. Initialized the formatter in TradingEngine to ensure proper integration across the application.
|
4 gün önce |
Carles Sentis
|
3849a02442
Enhance stop loss management in MarketMonitor - Updated orphaned stop loss cleanup logic to consider parent order statuses, improving accuracy in identifying and cancelling orphaned stop losses. Enhanced logging to provide clearer reasons for cancellations and updated documentation for the cleanup method to reflect new behavior.
|
4 gün önce |
Carles Sentis
|
2da0a71b51
Refactor MarketMonitor to enhance external trade processing - Updated the method for checking external trades to utilize the TradingEngine's recent fills retrieval. Improved timestamp handling and state management by loading the last processed trade time from the database. Enhanced logging for better debugging and added a safety net for activating pending stop losses based on recent fills, ensuring robust trade management.
|
4 gün önce |
Carles Sentis
|
d0ffa6537a
Refactor trading command notifications to accommodate new response format - Updated long, short, and exit order success notifications to extract and display order details from the new response structure. Enhanced backward compatibility by creating mock order objects for notifications, ensuring consistent user feedback and improved clarity in order status messages.
|
4 gün önce |
Carles Sentis
|
1e20e93542
Improve gitignore rules for data directory to ensure all data files are ignored
|
4 gün önce |
Carles Sentis
|
f9395fb099
Remove data files from git tracking - should be ignored
|
4 gün önce |
Carles Sentis
|
c6d9f2f62a
Add initial price alarms JSON and trading stats SQLite file - Created a new JSON file for price alarms to manage alarm states and added a SQLite database for trading statistics, enhancing data persistence and management. Updated trading commands to reflect changes in order cancellation notifications, including detailed summaries of cancelled orders.
|
4 gün önce |
Carles Sentis
|
938e56a535
Refactor reset_data.sh and trading_bot.py for SQLite integration - Updated reset_data.sh to remove legacy JSON files and handle SQLite database cleanup. Modified trading_bot.py to check for SQLite database existence instead of JSON files, enhancing statistics persistence reporting. Adjusted management_commands.py to reflect the new SQLite file structure for trading stats. Improved trading_stats.py to rename order_id to exchange_fill_id and added linked_order_table_id for better data management.
|
4 gün önce |
Carles Sentis
|
5ae857d2d6
Enhance order management and stop loss functionality - Updated InfoCommands to display pending stop losses linked to orders, improving user visibility. Refactored TradingCommands to ensure accurate stop loss notifications and confirmations. Transitioned MarketMonitor to utilize SQLite for state management, replacing file-based persistence, and added comprehensive logging for order status updates. Improved TradingEngine to handle order placements and cancellations more robustly, including linked stop loss management, ensuring better tracking and execution of trades.
|
4 gün önce |
Carles Sentis
|
2218d5a8b5
Enhance error handling and logging in HyperliquidClient and TradingEngine - Implemented a method to extract specific error messages from exceptions in HyperliquidClient, improving clarity in error logging. Updated TradingEngine to handle order placement responses more robustly, ensuring detailed error messages are logged and returned for better debugging and user feedback.
|
4 gün önce |
Carles Sentis
|
4e09f49d4e
Fix logging format in TradingStats - Updated the logging statement to ensure proper formatting of the average entry price, improving clarity in position enhancement messages.
|
4 gün önce |
Carles Sentis
|
7c5d17afb9
Refactor TradingStats to use SQLite for data management - Transitioned from JSON file storage to an SQLite database for improved data integrity and performance. Enhanced methods for recording trades, balances, and adjustments, ensuring robust handling of transactions. Updated statistics calculations to leverage database queries, streamlining data retrieval and improving overall efficiency.
|
4 gün önce |
Carles Sentis
|
a10e7c34aa
Implement state management for MarketMonitor - Added functionality to load and save the market monitor's state to a JSON file, ensuring persistence of the last processed trade time. Enhanced timestamp handling for incoming trades to support various formats and ensure UTC consistency. Improved logging for state loading and saving processes to aid in debugging and monitoring.
|
4 gün önce |
Carles Sentis
|
bb8b71a7ef
Refactor order execution logic in TradingEngine - Updated the execute_long_order and execute_short_order methods to improve handling of limit and market orders. Enhanced error handling for price validation and order placement, ensuring robustness against invalid inputs and improving logging for better traceability of order processing.
|
4 gün önce |
Carles Sentis
|
484514e0f9
Update days active calculation in TradingStats - Replaced the calculation of active days with a direct reference to the 'days_active' field in the basic data structure, improving code clarity and maintainability.
|
4 gün önce |
Carles Sentis
|
cd95517fcf
Refactor price data handling in InfoCommands - Updated the retrieval of market data prices to handle None values gracefully, ensuring robust float conversion. This improves the reliability of price calculations and enhances overall data integrity in the bot's operations.
|
4 gün önce |
Carles Sentis
|
4e2eb90b5b
Update callback data for inline keyboard buttons in InfoCommands and TradingCommands - Changed callback data to include leading slashes for consistency across command handling. Enhanced error logging and command execution feedback to improve user interaction and clarity during bot operations.
|
4 gün önce |
Carles Sentis
|
264b0a9f51
Update startup message formatting in Telegram bot - Changed escape sequences to newline characters for improved readability in the bot's startup message. This enhances the clarity of the information presented to users upon initialization.
|
4 gün önce |
Carles Sentis
|
73ca59941e
Refactor TradingCommands to integrate InfoCommands and ManagementCommands - Updated the TradingCommands class to accept additional command handlers, enhancing command execution and user interaction. Improved button callback handling for better command processing and user feedback during interactions.
|
4 gün önce |
Carles Sentis
|
994d8f035a
Refactor TradingCommands and management command handling - Simplified the TradingCommands initialization by removing unnecessary parameters. Enhanced the custom keyboard feature to dynamically generate button layouts based on configuration, improving user interaction and feedback during command execution.
|
4 gün önce |
Carles Sentis
|
1e0cf4d47d
Refactor TradingCommands initialization and enhance command handling - Updated the TradingCommands class to accept instances of InfoCommands and ManagementCommands, along with the bot instance itself, for improved command execution. Enhanced button callback handling to streamline command processing and provide user feedback during interactions.
|
4 gün önce |
Carles Sentis
|
a9a57e6ea4
Enhance Telegram bot's polling and shutdown processes - Improved the bot's updater management by ensuring it starts and stops correctly, with detailed logging for better traceability. Updated exception handling during shutdown to provide clearer feedback on interruptions. Refined the application shutdown sequence to ensure all components are properly stopped, contributing to a more reliable and user-friendly experience.
|
4 gün önce |
Carles Sentis
|
d95d69202f
Add TELEGRAM_DROP_PENDING_UPDATES configuration option - Introduced a new environment variable to control the handling of pending updates in the Telegram bot, enhancing flexibility in bot configuration.
|
4 gün önce |