Ghostfolio: Fixing Performance Comparison Chart Bug

by Alex Johnson 52 views

Experiencing issues with Ghostfolio's performance comparison feature? You're not alone! This article dives into a specific bug report where users are unable to compare their portfolio against benchmarks like Bitcoin, resulting in an empty chart. We'll dissect the problem, explore potential causes based on the provided logs, and offer insights into how to troubleshoot and resolve this frustrating issue. Whether you're a seasoned Ghostfolio user or just starting out, understanding and addressing bugs like this is crucial for maintaining an accurate and reliable portfolio tracking experience.

Bug Description: No Comparison Graph

The core issue revolves around the performance comparison feature within Ghostfolio. Users attempt to compare their portfolio's performance against a benchmark asset, such as Bitcoin (BTC). While the chart appears to reload, the expected second graph representing the benchmark never materializes. This leaves users with an incomplete view of their portfolio's relative performance.

Steps to Reproduce

The bug can be reproduced by following these steps:

  1. Navigate to the performance section of Ghostfolio.
  2. Attempt to add a comparison, for example, comparing the portfolio against Bitcoin (BTC).
  3. Observe the chart reloading. The comparison graph, which should display Bitcoin's performance alongside the portfolio's, does not appear. The video provided here visually demonstrates this issue.

Expected Behavior

The expected behavior is that upon selecting a benchmark for comparison, the chart should display a second graph representing the performance of the chosen benchmark asset (e.g., Bitcoin). This allows users to visually assess how their portfolio's performance stacks up against the selected benchmark over time. The comparison graph is essential for understanding relative performance and making informed investment decisions.

Log Analysis

The provided logs offer valuable clues into the underlying cause of the bug. Here's a breakdown of the key error messages and their potential implications:

  • ERROR [ExchangeRateDataService] No exchange rate has been found for nullEUR: This error suggests a problem with retrieving exchange rate data. The nullEUR likely indicates that a currency code is not being properly passed or recognized, leading to a failure in fetching the necessary exchange rate. This could be related to how Ghostfolio handles currency conversions when comparing against assets denominated in different currencies.
  • ERROR [ExchangeRateDataService] No exchange rate has been found for USDEUR at 2025-11-16: This error explicitly states that the exchange rate between USD and EUR could not be found for a specific date. This further reinforces the issue with exchange rate data retrieval. Historical exchange rates are crucial for accurate performance comparisons, especially when dealing with assets traded in different currencies.
  • ERROR [BenchmarkService] No historical market data has been found for BTCUSD (YAHOO) at 2023-12-13: This error points to a problem with retrieving historical market data for Bitcoin (BTC) from Yahoo Finance. This suggests that Ghostfolio is unable to fetch the necessary price data for Bitcoin to generate the comparison graph. Issues with data providers or incorrect ticker symbols could be the root cause.

These log messages collectively indicate that the bug is likely related to issues with retrieving both exchange rate data and historical market data for the chosen benchmark asset. Without this data, Ghostfolio is unable to generate the comparison graph, resulting in the observed behavior.

Environment Details

Understanding the environment in which the bug occurs is crucial for troubleshooting. Here's a summary of the environment details:

  • Ghostfolio Version: 2.217.1
  • Hosting: Self-hosted
  • Experimental Features: Enabled
  • Browser: Brave 1.84.139
  • Operating System: Linux

Potential Causes and Solutions

Based on the log analysis and environment details, here are some potential causes and corresponding solutions for the Ghostfolio performance comparison bug:

  1. Exchange Rate Data Issues: The nullEUR and USDEUR exchange rate errors suggest a problem with currency handling. Ensure that your Ghostfolio instance is properly configured with the correct currency settings. Verify that the currencies used in your portfolio and the benchmark asset are correctly recognized and supported by Ghostfolio.

    • Solution: Check the currency settings in Ghostfolio and ensure they are correctly configured. You may need to manually update or configure the exchange rate data source if it's not automatically updating.
  2. Historical Market Data Retrieval: The BTCUSD error indicates a problem with fetching historical Bitcoin data from Yahoo Finance. This could be due to temporary issues with the Yahoo Finance API, incorrect ticker symbols, or limitations in the data available through the API.

    • Solution: Verify that the ticker symbol for Bitcoin (BTCUSD) is correct. Try using a different data source for Bitcoin data if available in Ghostfolio settings. Check if there are any known issues with the Yahoo Finance API. Consider using an alternative data provider if the issue persists.
  3. Experimental Features: Since experimental features are enabled, there's a possibility that the bug is related to one of these features. Experimental features are often under development and may contain bugs or compatibility issues.

    • Solution: Try disabling experimental features to see if it resolves the issue. If the bug disappears after disabling experimental features, then one of those features is likely the cause.
  4. Self-Hosting Configuration: Self-hosting Ghostfolio requires proper configuration of the server environment. Ensure that all dependencies are correctly installed and that the server has access to the necessary external resources (e.g., internet access for fetching data).

    • Solution: Double-check your server configuration to ensure that all dependencies are correctly installed and that there are no network connectivity issues preventing Ghostfolio from accessing external data sources.
  5. Browser Compatibility: While less likely, browser compatibility issues can sometimes cause unexpected behavior. Although Brave is generally a compatible browser, it's worth testing in another browser to rule out any browser-specific issues.

    • Solution: Try reproducing the bug in a different browser (e.g., Chrome, Firefox) to rule out any browser-specific issues.

Troubleshooting Steps

Here's a step-by-step guide to troubleshooting the Ghostfolio performance comparison bug:

  1. Check Currency Settings: Verify that your Ghostfolio instance is configured with the correct currency settings and that all currencies used in your portfolio and benchmark assets are properly recognized.
  2. Verify Ticker Symbols: Ensure that the ticker symbols for the benchmark assets (e.g., BTCUSD for Bitcoin) are correct.
  3. Test with Different Data Sources: If possible, try using a different data source for historical market data to see if it resolves the issue.
  4. Disable Experimental Features: Temporarily disable experimental features to see if one of them is causing the bug.
  5. Check Server Configuration: If you're self-hosting Ghostfolio, double-check your server configuration to ensure that all dependencies are correctly installed and that there are no network connectivity issues.
  6. Test in a Different Browser: Try reproducing the bug in a different browser to rule out any browser-specific issues.
  7. Consult Ghostfolio Community: If you've tried all of the above steps and the bug persists, consult the Ghostfolio community for assistance. Provide detailed information about your environment, the steps you've taken to reproduce the bug, and any relevant log messages.

Reporting the Bug

If you're unable to resolve the bug yourself, it's important to report it to the Ghostfolio developers. When reporting the bug, be sure to include the following information:

  • A clear and concise description of the bug
  • Steps to reproduce the bug
  • Expected behavior
  • Actual behavior
  • Environment details (Ghostfolio version, hosting, browser, operating system)
  • Relevant log messages
  • Screenshots or videos demonstrating the bug

Providing detailed information will help the developers quickly identify and fix the bug.

Conclusion

The Ghostfolio performance comparison bug can be a frustrating issue, but by understanding the potential causes and following the troubleshooting steps outlined in this article, you can increase your chances of resolving it. Remember to check your currency settings, verify ticker symbols, test with different data sources, disable experimental features, check your server configuration, and test in a different browser. If all else fails, don't hesitate to consult the Ghostfolio community or report the bug to the developers. By working together, we can help make Ghostfolio an even better portfolio tracking tool.

For more information on troubleshooting software issues, visit the official documentation.