Ignore:
Timestamp:
06/16/10 13:56:29 (11 years ago)
Author:
sc
Message:

client:

  • Switched to JSON from Pickle for message encodings
  • Fixed but with command line client not respecting custom server host/port settings

configuration.ini:

  • thinkgear server settings added

configuration.py

  • thinkgear server settings added

server:

  • Switched to JSON from Pickle for message encodings

client_thinkgear:

File:
1 edited

Legend:

Unmodified
Added
Removed
  • remote_control/puzzlebox_brainstorms_client.py

    r31 r48  
    99# For more information please refer to http://www.gnu.org/copyleft/gpl.html 
    1010# 
    11 # Last Update: 2010.02.03 
     11# Last Update: 2010.06.16 
    1212# 
    1313##################################################################### 
    1414 
    1515import os, sys 
    16 import cPickle as pickle 
     16#import cPickle as pickle 
     17import simplejson as json 
    1718 
    1819from twisted.internet import reactor, protocol, defer 
     
    8485        def connectionMade(self): 
    8586                 
    86                 data = pickle.dumps(self.factory.command) 
     87                #data = pickle.dumps(self.factory.command) 
     88                data = json.dumps(self.factory.command) 
    8789                self.transport.write(data) 
    8890                 
     
    118120                 
    119121                try: 
    120                         reply = pickle.loads(self.data_chunk) 
     122                        #reply = pickle.loads(self.data_chunk) 
     123                        reply = json.loads(self.data_chunk) 
    121124                except Exception, e: 
    122125                        if self.DEBUG: 
     
    218221                 
    219222                self.command_parameters = command_parameters 
    220                 self.server_host = SERVER_HOST 
    221                 self.server_port = SERVER_PORT 
     223                self.server_host = server_host 
     224                self.server_port = server_port 
    222225                self.max_connection_attempts = MAX_CONNECTION_ATTEMPTS 
    223226         
Note: See TracChangeset for help on using the changeset viewer.