Skip to content

The data reported with 'report summary' is inconsistent #319

Description

@sid-the-sloth

Describe the bug
Have a sample yaml config -- with mixed currencies, USD and CAD.

Specify that we want CAD in the yaml, and calculations:
currency: CAD

The computed results, total value, total cost are different in the ticker app than those reported when using the 'print summary' for the same group/portfolio.

To Reproduce
Steps to reproduce the behavior:

  1. create a sample test.yaml config file:
show-summary: true
show-tags: true
show-fundamentals: true
show-separator: true
show-holdings: true
interval: 15
currency: CAD
currency-summary-only: true
sort: alpha
groups:
  - name: Test-Portfolio
    watchlist:
      - AAPL
      - HGY.TO
    holdings:
      - symbol: AAPL
        quantity: 100
        unit_cost: 150.00
      - symbol: HGY.TO
        quantity: 1000
        unit_cost: 12.00
  1. run the ticker app with:
    ticker --config test.yaml
    see computed "total" numbers:
  • value: 40995.59
  • cost: 32501.55
  1. run the 'print summary' with:
    ticker --config test.yaml print summary | jq '.'
    see how the values now differ from above:
  • "total_value": "33554.50"
  • "total_cost": "27000.00"

Expected behavior
One would expect that with the same input we obtain same results after using either way of running 'ticker'.

Ideally, one would like to have the calculations as they are done in the full ticker app, in this case in: currency: CAD.

Numbers should be the same.

Screenshots
N/A

Environment (please complete the following information):

  • OS: Linux
  • Terminal: XFCE Terminal
  • ticker Version: 5.0.5

Additional context
N/A

Metadata

Metadata

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions