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

Bugs inside the DTag transferring process #296

Closed
RiccardoM opened this issue Oct 14, 2020 · 3 comments · Fixed by #304
Closed

Bugs inside the DTag transferring process #296

RiccardoM opened this issue Oct 14, 2020 · 3 comments · Fixed by #304
Assignees
Labels
kind/bug Something isn't working x/profiles Module that allows to create and manage decentralized social profiles
Milestone

Comments

@RiccardoM
Copy link
Contributor

Bug description

During the completion of the Desmos Primer Phase 6 challenge that required them to perform a DTag transferring, the Discord user MikeSnowman75 told me they ran into a strange behavior that did not allow him to exchange the DTag properly.

Steps to reproduce

Reporting his words, here is what he did with an additional analyses from me.

He tried to transfer the dtag first in these 2 transactions:

  1. First
  2. Second

As we can already see, there are two problems here:

  1. The first transaction has an empty dtag_to_trade.
    This might say that the sending profile did not exist, or it didn't have the DTag set. This is a bug I've already reported inside MsgRequestDTagTransfer allows for empty DTag transfering #292.

  2. The second message fails with error profile of desmos1k7q92w7ku72ycutz6xqrx67v92yycff3emz88s doesn't exist.
    This should not have happened. If a user wants a DTag of another user without having created a profile first, then a new profile for the receiving user should be created and the DTag transferring should continue properly.

After this, he tried with other two transactions:

  1. First

  2. Second

From them, we can see that:

  1. The first transaction was successful.
  2. The second transaction failed with error the owner's DTag is different from the one to be exchanged.
    Apparently, something here messed up because this one should not have failed here.

Also, they said that they tried performing another transaction. As you can see, this failed with error:

the transfer request from desmos1rpurg200edtv6rgvfjuf7j6s8mghnsljkzvurg to desmos1k7q92w7ku72ycutz6xqrx67v92yycff3emz88s has already been made

To be honest, I don't think this error should ever verify. If an Alice -> Bob transfer was made successfully, then once it concluded it should be removed allowing Alice to send Bob another DTag if she wants. I've reported this bug inside #295.

Expected behavior

The first transferring should have completed properly, as well as the second one.

@RiccardoM RiccardoM added kind/bug Something isn't working x/profiles Module that allows to create and manage decentralized social profiles labels Oct 14, 2020
@RiccardoM RiccardoM added this to the v0.13.0 milestone Oct 15, 2020
@leobragaz
Copy link
Contributor

I think I've understood why this txs error occurred.
Since in v0.12.3 we have the empty DTag transfer bug, when we make a request to an address without a profile, the system saves the request with an empty dTag into the store. Later, that address create a profile with a dTag which will be different from the empty one and if he accept the transfer request the error will show up.

@RiccardoM
Copy link
Contributor Author

@bragaz So, this should be fixed with #303 as well?

@leobragaz
Copy link
Contributor

@RiccardoM I will add some more integration tests to a new PR that should solve this and #295

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working x/profiles Module that allows to create and manage decentralized social profiles
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants