'Python Can't decode byte : Invalid start byte

So im building this socket application, and it works just fine on my computer. But when i start server socket on another laptop, it just crashes with a invalid start byte error: How do i proper encode the program to work with all laptops

This is the error i get on : Other laptops.

My laptop.

I have tried to change the encoding, but im just not quite sure where i have to change it.

Class Listener:   '
 def __init__(self):
        self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
        self.server_address = (socket.gethostbyname(socket.gethostname()), 10000)
        self.sock.bind(self.server_address)
        print(f"LISTENER : {str(self.server_address[0])} port {str(self.server_address[1])}")




    def listen(self):
        self.sock.listen(1)
        while True:
            print("Connection Open")
            print("     Waiting for connections")
            self.connection, self.client_address = self.sock.accept()
            try:
                print(f"Connection from {str(self.client_address)}")
                while True:
                    data = self.connection.recv(1024)
                    if data:
                        message = str(data)
                        if not "print" in message.lower(): #This just checks if the client wants to print system infomation from the server
                            Validate(message)#this checks for a command the server have to do
                        else:
                            self.connection.sendall(pickle.dumps(self.computerinfomation))
                    else:
                        self.listen()
            except Exception as e:
                print(e)

I want it to work on other laptops as well, and i just cant see why it wont.



Solution 1:[1]

Not going to lie. I just changed the encoding = utf-16.

Example:

df = pd.read_csv(C:/folders path/untitled.csv, encoding = "utf-16")

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 ouflak