input-output-hk / daedalus

The open source cryptocurrency wallet for ada, built to grow with the community
https://daedaluswallet.io/
Apache License 2.0
1.23k stars 295 forks source link

Display rewards history #2347

Open ghost opened 3 years ago

ghost commented 3 years ago

Ok guys we are now at 3.2 and the linux built in autoupdater still not working this is unacceptable. Always failed to download blah blah do it manually please fix this. Since we dealing with a critical financial software here the wallet itself should do the signature verification on each and every update.

Here are some future ideas:

-The number of ADA overall should be copy pastable -The number of staking rewards (at least the last 10 epochs) should be displayed in a table with the stake pool name so we can track the exact amount of rewards per epoch. Right now it is just an overall reward what you made.

nikolaglumac commented 3 years ago

Hi @feraldruid22, Thank you for the feedback!

Ok guys we are now at 3.2 and the linux built in autoupdater still not working this is unacceptable. Always failed to download blah blah do it manually please fix this. Since we dealing with a critical financial software here the wallet itself should do the signature verification on each and every update.

There is a known issue with the autoupdater which is currently being worked on. The issue affects users that are more than 1 version behind, while it works 100% on the N -> N+1 case (e.g. updating from 3.1.0 to 3.2.0 works flawlessly). If you regularly update Daedalus you won't even notice the issue. We are sorry for the inconvenience and we are doing our best to fix this issue ASAP.

-The number of ADA overall should be copy pastable

Can you please expand on this? Which value should be copy/pastable? I would like to understand which ADA values you find not to be copy/pastable as they should all be copy/pastable by default...

-The number of staking rewards (at least the last 10 epochs) should be displayed in a table with the stake pool name so we can track the exact amount of rewards per epoch. Right now it is just an overall reward what you made.

This is indeed a long-missing feature... Unfortunately, it is not something we (Daedalus team) can implement without it first being made available on the cardano-wallet (Adrestia team) component as Daedalus UI depends on the cardano-wallet API. We have the UI already built to support this and we will enable it as soon as we get the API to support it.

To learn more about Daedalus architecture, please refer to the following architecture overview: network-scheme-dark

nikolaglumac commented 3 years ago

@feraldruid22 please expand on this:

-The number of ADA overall should be copy pastable

...I am not sure I understand the issue.

JasinYip commented 3 years ago

Unfortunately cardano-wallet isn't able to implement this feature either (via https://github.com/input-output-hk/cardano-wallet/issues/2547#issuecomment-789562114).

So could we get this data via cardano explorer RESTful API when the explorer supports the feature?

nikolaglumac commented 3 years ago

That is indeed our plan @JasinYip! We will soon start working on it. Will keep you updated here in the thread! Thanks for the patience 🙏

HartS commented 3 years ago

I've only just been staking long enough to receive two rewards payouts, and I was pretty shocked to see the rewards received per epoch is not available. I live in Canada and my (very limited) understanding of our tax laws is that each rewards payout is a taxable event (so if I receive 1 ADA as a reward for staking, it would be treated as capital gains based on the value of that 1 ADA at the time I received the staking reward). Perhaps my understanding is incorrect (crypto and taxes still feels like the wild west). But I think this information is absolutely critical, whether or not it's required for tax compliance.

Danation commented 3 years ago

This is required for USA tax purposes as well. Every reward gained is considered regular income, so I would love to have the following: A history of each reward and associated timestamp as well as the approximate value in fiat (based on user's chosen fiat) at the time of reward. Then a simple export lets us sum up the fiat column and report it to our favorite folks at the IRS.

HartS commented 3 years ago

Really, more reporting around tax purposes would be really useful. Sending some ada could show approximate value at the time of the transaction, with a statement of the value difference from when that ADA was deposited (using first-in-first-out)

JasinYip commented 3 years ago

@HartS @Danation Currently we can use some blockchain explorer like adapools.org to see rewards every single epoch for our address. You can search your staking address (starts with stake) to see it, or you can check out the delegator list in the stake pool you staked and find out your address to see it as well.

This feature requeest issue is more like an user experience improvment.

HartS commented 3 years ago

I mean Daedalus is really just a user experience improvement as well. After all, we can generate our own wallet addresses, manage them, and send all the necessary transactions through https://github.com/input-output-hk/cardano-node/ right?

I only intended that to be half as snarky as it sounds. In reality, Daedalus (and other user-friendly wallets) omitting this functionality makes Cardano inaccessible to the majority of people who live in the jurisdiction of a sophisticated tax authority, or invites issues down the line. Daedalus makes it really easy to stake, and that's amazing! But if it makes it easy to stake and hard to comply with local tax regulations, people are going to get bitten by this, and policy-makers will look less favourably on Cardano as well.

JasinYip commented 3 years ago

@HartS Totally agree with you

nikolaglumac commented 3 years ago

@HartS Daedalus is not omitting this feature nor any other feature for that matter. This data is not available via cardano-wallet API, which is the single source of truth for us as Daedalus is a full-node wallet. We understand the importance of having this feature and the team is working on it. In order to get this information, one has to use explorer-like deployment (e.g. cardano-db-sync) which is not what cardano-node delivered as a part of Daedalus does. We are now working on a solution which will allow us to fetch the required data which we will then use to populate our already existing UI built for this very purpose. Thank you for the patience!

HartS commented 3 years ago

@nikolaglumac thank you for your work on Daedalus. I think you've misunderstood me. This is a feature which Daedalus currently does not support. Hence, it is omitted. Any unsupported feature is omitted. I wasn't implying that Daedalus was ignoring or had decided against the feature.

nikolaglumac commented 3 years ago

All good @HartS! We are on the same page. I want you to know that we are fully aware of the importance of this feature. The team will add it as soon as humanly possible. Thanks for the support and patience 🙏

LeoniePhiline commented 3 years ago

Emurgo's Yoroi wallet shows rewards per epoch. How did they implement it?

nikolaglumac commented 3 years ago

Yoroi is a light-wallet which consumes external centralized Api which runs connected to a cardano-node which is always online and thus it is able to provide all of the historical data. Daedalus is a full-node wallet and we can not get this data from the cardano-wallet Api. However, we have decided to fetch it from an external source and it is being implemented in the scope of the following task: https://github.com/input-output-hk/daedalus/pull/2572 We should have it released in one of the upcoming Daedalus releases. Thanks for the patience 🙏

JasinYip commented 3 years ago

That's a great news

LeoniePhiline commented 3 years ago

Fantastic! Thank you for your work!

HartS commented 3 years ago

Very exciting! Thank you @nikolaglumac . Does this mean a node has to be always-on in order to determine rewards payouts? Or is it just that the API for IPC between Daedalus and the cardano-node process is only sufficient to get balances, regular withdrawals/deposits, etc.

nikolaglumac commented 3 years ago

@HartS the data isn't getting collected and thus there is nothing to be served via the Api. In order to get that you would need to use cardano-db-sync service which is what Yoroi does. We have decided to combine it with what Daedalus gets from the cardano-wallet API to offer our users the best of both worlds 🚀

HartS commented 3 years ago

For anyone looking for a simple, clean way to get a per-epoch staking rewards breakdown while we wait for this feature to make it into Daedalus, a web tool that just launched makes this information really accessible; if you enter your staking key you'll get a great breakdown of rewards per epoch:

example with a random stake key chosen: https://www.cardanoworld.io/stake-key/stake1u9xdm6m88jadl8yuvlm5faea0mdkauf3myfcguh47e39zpgw9h5w4

LeoniePhiline commented 3 years ago

@HartS

Useless if the authors keep requiring to stake with their pool to get more than 5 items.

Not in the spirit of openness. This sheds really bad light on the casch pool. I’d never stake with them after seeing this business model.

I rather get my reports from adapools.org instead.

HartS commented 3 years ago

@LeoniePhiline I agree, an open source solution is ideal. But I don't believe the authors require you to stake with them... I see the full history of rewards and I don't stake with them.

edit: thanks for sharing adapools.org , which also does this. Though it also isn't open source (to my knowledge). I realize it was shared earlier, but I thought the interface on cardanoworld was cleaner, and it actually shows me some additional info.

LeoniePhiline commented 3 years ago

@HartS You see the history of rewards without fiat currency counter value. If you want that, you have to select a currency (EUR/USD) in the top center. You won’t get a useful CSV, but a useless PDF with a huge diagonal watermark and only five epochs’ rewards unless you stake with them.

Honestly I find that a little appalling.

edit: thanks for sharing adapools.org , which also does this. Though it also isn't open source (to my knowledge). I realize it was shared earlier, but I thought the interface on cardanoworld was cleaner, and it actually shows me some additional info.

Yes, adapools is also obnoxious with all the adds too, bottom, center, left and right. However, you get a full overview of rewards in your favorite many available fiat currencies:

A620353A-2643-4FEE-865F-9ECBA164761C

However, I haven’t checked if the fiat value at the end of each epoch is correct. Neither have I checked if they do USD to any other fiat conversions, possibly with today’s rate instead of the rate of the day of rewards payment.

So make sure to check if these tools work right. Unfortunately there’s no code to audit. The adapools people do respond to email, though, so we could ask.

PhilippeLeLong commented 3 years ago

Use pooltool.io – they have the same feature and you can easily export the data. Also I think no ads as far as I can tell.

PhilippeLeLong commented 3 years ago

@HartS

Does this mean a node has to be always-on in order to determine rewards payouts?

So the ledger does not track the transactions made to the rewards accounts and if no one permanently tracked the blockchain states you couldn't get this data? I guess that somehow was the purpose, otherwise we'd have millions of transactions around the epoch boundary.