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

Commit for issue#39 #83

Closed
wants to merge 1 commit into from
Closed

Commit for issue#39 #83

wants to merge 1 commit into from

Conversation

adhyay2000
Copy link

Added the server-side validation.
If a client is new joinee,he can create a new chatroom by sending NEW command
or validate by CHKUSR command. The chatroom are generated at a single point,hence
the disperancy coming in earlier case is resolved.

Added the server-side validation.
If a client is new joinee,he can create a new chatroom by sending NEW command
or validate by CHKUSR command. The chatroom are generated at a single point,hence
the disperancy coming in earlier case is resolved.
@adhyay2000
Copy link
Author

fix for issue #39.

@adhyay2000 adhyay2000 closed this Oct 22, 2020
@adhyay2000 adhyay2000 reopened this Oct 22, 2020
@gridhead gridhead self-requested a review October 23, 2020 02:09
Copy link
Owner

@gridhead gridhead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A lot of changes hail from #84. Please look at the suggestions I have provided there and work accordingly.

@@ -9,6 +9,7 @@

sess = PromptSession()
sepr = chr(969696)
websocket = None
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please avoid such cross-type object initialization as far as possible.

@@ -29,7 +30,7 @@ def decrjson(self, data):
return self.suit.decrypt(data.encode("utf8")).decode("utf8")


async def consumer_handler(cphrsuit, websocket, username, chatroom, servaddr):
async def consumer_handler(cphrsuit, username, chatroom, servaddr):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The websocket object must be passed here as a parameter.

@@ -46,7 +47,7 @@ async def consumer_handler(cphrsuit, websocket, username, chatroom, servaddr):
pass


async def producer_handler(cphrsuit, websocket, username, chatroom, servaddr):
async def producer_handler(cphrsuit, username, chatroom, servaddr):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The websocket object must be passed here as a parameter.

@gridhead gridhead self-requested a review October 23, 2020 02:15
@gridhead gridhead assigned gridhead and shivangswain and unassigned gridhead Oct 23, 2020
@adhyay2000
Copy link
Author

Hi, I have added my justification for using this way, there. Please look that and reply what I should do?

@adhyay2000 adhyay2000 closed this Oct 24, 2020
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

Successfully merging this pull request may close these issues.

3 participants