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

[bug] Ratings aren't used and the data is wrong #305

Open
kenbot opened this issue Jul 19, 2024 · 3 comments
Open

[bug] Ratings aren't used and the data is wrong #305

kenbot opened this issue Jul 19, 2024 · 3 comments

Comments

@kenbot
Copy link
Contributor

kenbot commented Jul 19, 2024

The Rating field in GameFile is typed as double?, but the database field in SQLite is INTEGER. In my tests, the "double" is getting saved to the "INTEGER" column, possibly as a string, thanks to SQLite's loosey-goosey column types, but comes back cast as an Int, thanks to the software layer.

As far as I can tell none of this is used by the real code: when I download a WAD from idgames that has a listed rating, the rating column is still NULL.

Not a biggie, but I'm planning to just ignore the Rating field in the tests.

@nstlaurent
Copy link
Owner

The rating is only displayed from idgames but not saved locally. It was intended to be the users rating which can only be integer numbers 1 - 5 and why it is defined as an integer in the sqlite database.

@kenbot
Copy link
Contributor Author

kenbot commented Jul 19, 2024

Ahhh right, the one with the helmets. Should the data type in GameFile be int? then?

@nstlaurent
Copy link
Owner

It was made a double because the interface is used to bind to the grid it's a decimal when fetching from idgames.

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