Just your nice, local snek, as well as your friendly neighborhood Pythonista. Been programming in Python since late 2017 :D
You can find me either chilling around in the Pygame Discord, programming, or playing some games.
A higher-level extension of the socket module, with simpler and more efficient usages
Home Page: https://hisock.readthedocs.io
License: MIT License
Describe the bug
After replaying a tic tac toe match, the server breaks with a BrokenPipeError
. This is currently being under investigation; it is speculated to be caused by the client disconnection handling.
To Reproduce
Replay a tictactoe match (the first time, it works well)
NOTE: This bug seems to be present only while the opponents are both using the terminal client
Describe the bug
There is no type cast support for neither old_name
nor new_name
Expected behavior
There should be type cast support for old_name
and new_name
, as well as some other related commands
What is needing to be done currently?
Currently, all files have different PEP8 conventions, because they've all been decided on my mood and how I was feeling to "obey PEP8" that day. So, with Black, the formatting would be much more regular, which is what we want.
Why aren't you doing it right now? >:(
I'm pretty lazy, plus I'm studying electronics rn.
Describe the bug
I honestly have no clue what it is (even when going on SO), hisock just throws that exception for long running client-server connections.
To Reproduce
I don't know, start a connection and then sleep for 8 hours?
Expected behavior
Obviously, no exception
What is needing to be done currently?
... Releasing version 1.1. Was gonna be 1.0.1, but with the addition of a couple funcs, I think it's worthy to be a minor version rather than a micro version.
Why aren't you doing it right now? >:(
I'm pretty lazy.
What is needing to be done currently?
Well, since I added dict-sending support for HiSockServer...
Why aren't you doing it right now? >:(
Duh.
What it says
Is your feature request related to a problem? Please describe.
Like, he currently as the time of writing has 7 issues open. Be clear on one thing, smh
Describe the solution you'd like
That he be removed from the hisock development "team"
Describe alternatives you've considered
An alternative is for him to leave Alabama
Why do you want to add this feature?
shi de
๐๐ฝ
I should also probably add better docs too
Is your feature request related to a problem? Please describe.
I mean, I regularly add type hints to the hisock functions, classes, etc. However, sometimes, they're not that detailed (E.g a dict
without specifying keys and values).
Describe the solution you'd like
Add better type hints, duh. (dict
-> dict[str, int]
)
Describe alternatives you've considered
Comments go brr
Why do you want to add this feature?
To improve "readability". This might be debated, since some people think type hints are good while others think not. The main point is to improve the user's experience with hisock, particularly the user's IDE.
Additional context
Haha avaxar I'm opening another issue
Is your feature request related to a problem? Please describe.
When I saw sheepy use hisock, he used his implementation of the leave
reserved function, because he sent some extra data. So, I realized that the functions would be useless to people who want to have their custom data sent on a particular reserved function event.
Describe the solution you'd like
So, I plan to add this method so that users can specify the data they want to send whenever a reserved function is triggered. The usage would probably be like server.set_reserved_function_config('leave', ['clt_info', 'my_data', 'more_data'])
What is needing to be done currently?
Currently, there is no universal standard for code formatting in hisock (it's just me feeling it). With black, it can be less different, and more readable overall.
Why aren't you doing it right now? >:(
I'm pretty lazy.
Is your feature request related to a problem? Please describe.
Sometimes, async programming could be better than a multithreaded solution. So, I'm planning to add an AsyncHiSockServer
and AsyncHiSockClient
class, as well as the functions to create an instance of them, soon.
Describe alternatives you've considered
Well, we already have multithreaded servers and clients, but I think it'd be the icing on the cake to have hisock be asynchronous.
Additional context
Stackoverflow async socket
Currently, groups only have the advantage of sending messages to a group of clients, and identifying them easily. However, this issue expands on groups, adding such things as a message cache.
Describe the bug
IMPORT ERRORS IN HISOCK DUE TO EXAMPLES - I AM WORKING ON IT
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Smartphone (please complete the following information):
Additional context
Add any other context about the problem here.
A keepalive signal would be pulsed every minute from the server to every client. The client has 30 seconds to respond, or else they will be declared dead and be disconnected from the server. This ensures that no already dead client would be left in the server for too long.
I actually already started working on this, so it will just take ~10 or so hours for it to finally be added to hisock.
Is your feature request related to a problem? Please describe.
We are running out of IPv4 addresses in the world. Pretty soon, we would have to transition to a different protocol.
Describe the solution you'd like
If hisock supports IPv6, then we would in a way help prepare for the future.
Describe alternatives you've considered
No other alternatives.
No way hisock activity after a year
Describe the bug
I don't know if we ever tested the keepalive functionality, but while I was working on a hisock VoIP app, I accidently didn't start my client, and the server emitted a ValueError
. More info is on discord.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
No error
Additional context
Looks like while the keepalive's disconnecting the client, the server also sees that it's closed and disconnects it too. Goofy race condition
Describe the feature
Sometimes, it may be useful to know previous messages of what the client has received. So, I propose to add some sort of "cache" that appends each message (and header) to a dictionary. Using a method, users can then get previous messages.
Additional context
I got this idea after struggling with a MemoryError
for sockets, when the header did not send out, and instead, the first 16 bytes of the data was set as the header. The data just so happened to be a large prime number for cryptography, so... the huge 16 digit number caused a MemoryError
Yeah I'm gonna work on it
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.