neuron.listProposals is used to query for proposals, but when I enter the request parameter to use Unknown, no proposals are returned.
This is the first time I’ve used an official dev kit and I’m not too familiar with the corresponding types, but what exactly does Unknown mean? Shouldn’t it mean select all?
When I changed ProposalRewardStatus.Unknown =>ProposalRewardStatus.AcceptVotes ProposalStatus.Unknown => ProposalStatus.Open,
I finally got 2 proposals and it was consistent with what I found on the official NNS website.
I just don’t quite understand what Unknown actually stands for
Most probably we indeed did not rename “Unknown” to “Unspecified” in the js lib, correct. As I said we do not use this value anyway in NNS dapp.
We, the gix team at DFINITY, are maintaining the ic-js libraries and are using those in NNS dapp.
e.g. last commit was provided by me and merged last week.
Thanks for the reply, so is this an error?
Speaking from my actual experience of using Unknown without returning any results, it’s likely that there is some error with this type.
Ok, I see what you mean, but why is it that no object is returned when I set the value to ProposalRewardStatus.Unknown, when it should be set to 0 it should return all of them!
I don’t think that’s how it works. By requesting Unspecified / Unknown you request those proposals that are set as Unspecified / Unknown . So it returns none because there aren’t such types.