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
Use game_type instead of init_mode in game_launch message #685
Comments
Could I try to help on it? |
Yea sure! It should be pretty straight forward:
Some tips from past experience with new contributors:
|
I would like to help on this issue. I'll be leaning on Travis while I ensure I've worked out all the quirks with WSL & Docker for Desktop. |
Alright, no problem. I usually just amend and force push if I need to use the CI instead of local tests. But you can also add a bunch of commits and squash/rebase them later when you've worked everything out. Doesn't matter a whole lot since we "squash and merge" PR's anyways. |
@wrharding any progress on this? Do you need help getting everything set up? |
Hello! Yes I am still working on this. My setup has the ability to create the infrastructure needed to get the tests running, I'm just taking it rather slow to get familiar. I've made the code changes, but haven't got the stack + db up and running yet for testing. If you would like, I can just use the Travis output to fix any issues that might come about. That way the issue doesn't look stale. |
@Askaholic for whatever reason these two unit tests are expecting the data returned in a different order. All the data is there, but the test fails because they're expecting 'uid' before 'mod' (and now don't include the 'game_type' attribute): Would you prefer these be resolved in a separate PR or can I just bundle them all into one? |
Alright no worries, I just wasn't sure if you were still working on it (as you can maybe see, the last guy who worked on it got about halfway through and then disappeared :P). If you need some tips on setting up the db on windows let me know (you can also message me through the FAF discord). The order of attributes in a dictionary doesn't matter for equality. You just need to add the >>> {1: "foo", 2: "bar"} == {2: "bar", 1: "foo"}
True |
i've setup all the infrastructure to run and test the dev server. As far as i can see, game_type has already been put in. |
about 3): the mentioned initMode and Faction Enums dont use string either. I can work on that too |
oh i didnt noticed somone is still working on this. @wrharding are you still working on this ? |
I was working on it for hacktoberfest 2020 but never completed it. Feel free take it and complete the three things you outlined. |
* add a game_type field to the game_launch message * added missing game_type field in test * add game_type to launch_game message * fix typo * change GameType member types to string * use lower case * to_string is not used anymore for GameType * do not inherit from str * remove inheritage from str * remove unused import * remove unused import * remove unused import * add missing import * import formatting
Init mode can be inferred from the game type i.e. matchmaker -> auto lobby, otherwise -> normal lobby.
We should add a
game_type
field to thegame_launch
message just like how it is in thegame_info
message and add a comment stating thatinit_mode
is deprecated.server/server/games/game.py
Line 850 in ad7d663
server/server/lobbyconnection.py
Line 941 in ad7d663
The text was updated successfully, but these errors were encountered: