-
Notifications
You must be signed in to change notification settings - Fork 50
2.8 ic packet extension no empty strings #144
2.8 ic packet extension no empty strings #144
Conversation
Ignore the changes in client manager. I forgot to revert |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That type enforcement file made me excited and I almost didn't finish the review
Better implementation Co-authored-by: oldmud0 <oldmud0@users.noreply.github.com>
…ling changes because why not. Fixed issue where blockdj didn't gettarget properly" This reverts commit 11ade13.
All of the previously addressed concerns should have been handled, feel free to take a look at them and provide additional feedback. |
…orneyOnline/tsuserver3 into in1tiate/testimony-recording
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah looks good. Still a lot of refactoring to be done. Just try not to go overboard with generics and typing so regular people can understand it.
I think one of my big hopes by even adding typing is to fix where the code will have a 0 as a string rather than an int. That alone can cause people to get confused IMO |
Oh that is such a fat Merge conflict |
And after a long challenge of merging. I am pleased with this and it is ready |
Did we want me to update more on this? I feel like I might've made this PR too big and I should've just changed the args to an object and left some of the logic still in the same spot |
No sorry I had just been waiting on CI. Looking back at it though, this is a fairly large refactoring PR, and some further testing would be nice. |
I wasn't pleased at all with how large I made this. I'll be making this a smaller PR so that the changes won't have to be so heavily tested |
Potential solution for #107 ?? I'm not sure. There's a whole lot going on in that method.
This is also somewhat of a refactor and may not be what you're looking for.
Adding all of the typing was absolutely killing me. I used the
@dataclass
decorator to try and slim down some of the difficulty in reading the massive type checking. Then I created separate dataclasses for each pre-existing packet type and had each of those inherit from one another so we can just use the 2.8 packet standard for everything. Using something I found on stack overflow, I'm able to use@enforce_typing
decorator on the@dataclass
decorator and it enforces the typing.I wouldn't say that this PR is ready to go yet, but I would like to get some guidance on whether or not this is addressing the issue. It seems like it type-checks for what you're looking for.
Any feedback is appreciated!