Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Got a stock symbol with an unsupported format #62

Closed
amalcev opened this issue Feb 8, 2022 · 4 comments
Closed

Got a stock symbol with an unsupported format #62

amalcev opened this issue Feb 8, 2022 · 4 comments

Comments

@amalcev
Copy link

amalcev commented Feb 8, 2022

Error while executing command:
investments tax-statement ib 2021 statement.dc0

Error:
Got a stock symbol with an unsupported format: "U.UN"

Error while reading "/home/ubuntu/Brokerage/Interactive Brokers/Statements": Error while reading "/home/ubuntu/Brokerage/Interactive Brokers/Statements/2021_Trade_Confirmation.csv": Failed to parse ("U0000000", "XXXXXX", "", "CAD", "STK", "U.UN", "SPROTT PHYSICAL URANIUM TRUS", "503299503", "CA85210A1049", "ISIN", "", "CA85210A1049", "TSE", "", "", "", "", "", "1", "", "", "", "", "ExchTrade", "4060338060", "2058458591", "0000d8c0.6138944c.01.01", "004d0452.00022e64.6136ee12.0001", "", "", "", "0", "", "", "2021-09-07 20:52:42", "2021-09-08 09:30:00", "2021-09-08", "2021-09-10", "2021-09-08", "TSE", "BUY", "10", "14.8", "148", "-148", "-0.755", "-0.755", "0", "0", "0", "0", "0", "CAD", "0", "O", "LMT", "EXECUTION", "", "N", "", "0", "", "", "", "", "0.0", "0.0 ()") record: Got a stock symbol with an unsupported format: "U.UN".

@KonishchevDmitry
Copy link
Owner

Hi, could you please look into your Activity statement: how this stock is displayed there in Trades, Dividends, Open Positions and Financial Instrument Information sections? Is it U.UN everywhere or for example just U (or something else) somewhere?

Is there any other errors? From what you've provided I see:

  1. It looks like you use *.dc0 file, but *.dc1 is expected for 2021 year
  2. CAD currency is not supported for *.dcX file generation yet, but just investments tax-statement ib 2021 should work.

What do you see if you temporary replace this symbol with something else (sed -i 's/U\.UN/UUN/g' *.csv)? Does investments tax-statement ib 2021 work after it or there are any other errors?

@amalcev
Copy link
Author

amalcev commented Feb 9, 2022

Hi,

It was a mistake with *.dc0, I use now *.dc1. Thank you.

"U.UN" is a correct ticker (SPROTT PHYSICAL URANIUM TRUS), it is everywhere in the reports.
I have "U" as well but it relates to another stock (UNITY SOFTWARE INC).

If I replace "U.UN" by "UUN" there is no such error anymore. Thank you.

However I got another one related to parsing "Custom activity statement" file:
Error while reading "/home/ubuntu/Brokerage/Interactive Brokers/Statements/2021-UXXXXXXX_20210103_20211231.csv" broker statement: Failed to parse ("Open Positions", "Data", "Summary", "Warrants", "USD", "CRHC WS", "-", "50", "1", "1.9636", "98.18", "0.8", "40", "-58.18", "") record: Got an unexpected "Asset Category" field value: "Stocks".

I guess it's because warrants not supported at the moment as well as options (#48)

@KonishchevDmitry
Copy link
Owner

OK, thanks. I'll support dots in symbol names (I've asked how it's displayed in other places because sometimes it varies almost unpredictably - #40).

But yes, I'm not going to support options in the near time. If it was an occasional trade, you may try to delete any information about it from the statement (or change it too look like a stock trade), but if you really use these instruments and the only thing you need is a tax statement, I may recommend you to look at https://github.com/titov-vv/jal/ - it has no portfolio rebalancing and some other features investments provides, but definitely has more deep support of various complex cases.

@KonishchevDmitry
Copy link
Owner

Fixed in v4.3.4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants