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

[Backend Bug Report] Insert fails on pokemon table because username column length is too short #32

Closed
cloud9team opened this issue Feb 6, 2020 · 5 comments · Fixed by #33
Labels
backend Related to the backend bug Something isn't working

Comments

@cloud9team
Copy link

Describe the bug
The column definition for username on rdmdb.pokemon is set to varchar(15). It is varchar(32) on every other table that has username. This allows you to import usernames longer than the max limit for rdmdb.pokemon. The insert fails silently when a username longer than varchar(15) is attempted to be inserted.

To Reproduce
Steps to reproduce the behavior:

  1. Import an account with a username longer than varchar(15) and less than varchar(32)
  2. Login to account.
  3. Watch it fail.
  4. `docker logs realdevicemap --timestamps | grep "too long for"`` should pull up the error.
    Expected behavior
    Expected behavior: make me a warm meal after work, tell me you love me..wrong website.
    Matching column definitions across all tables in a database would be a great place to start.

Screenshots
N/A

System

  • Running in docker: [yes]
  • Docker Engine Version: [N/A]
  • Host OS: [N/A]
  • RDM Version [highTable3000]

Additional context
If no "shiny stats" there would be no problem. 98% of the issues I see across almost every user trace back to rdm trying to be a one stop shop. In trying to do everything great, it kinda is starting to nothing well. My 2 cents and a nickel.

@cloud9team cloud9team added backend Related to the backend bug Something isn't working labels Feb 6, 2020
@123FLO321
Copy link
Collaborator

I don't get how this is related to "shiny stats".
This is simply a wrong db structure that can be fixed easily.

@123FLO321
Copy link
Collaborator

So you're basically saying that if we didn't continue developing RDM there would have been no bug.
Which is correct but is that the point of an project like that?

@whitewillem
Copy link
Contributor

whitewillem commented Feb 6, 2020

Since its a issue/pr now anyway... i would like to ask you to reconsider if having username in pokemon table is a smart thing. Its getting abused a lot. (Read: you can catch and sell shiny with this setup)

@ttanguay
Copy link
Contributor

ttanguay commented Feb 6, 2020

The intent of username in Pokémon table was for shadowban detection. So weigh cost of losing that capability vs whitewillem concerns.

@cloud9team
Copy link
Author

Running these changes locally from the moment this bug was found. Have not had an issue now that this column matches the length of allowed imports. This should be merged asap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Related to the backend bug Something isn't working
Development

Successfully merging a pull request may close this issue.

4 participants