~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to services/python-console

  • Committer: Matt Giuca
  • Date: 2010-07-23 06:27:02 UTC
  • mfrom: (1818.1.1 project-extensions)
  • Revision ID: matt.giuca@gmail.com-20100723062702-cknq5zzk1cwf8q2q
Merge from branch project-extensions (changes project_extension.deadline into project_extension.days in the database).
The branch isn't finished; I just want this DB change to be included before we release 1.0.2, in case the rest of the changes for this branch don't make it.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
# usage:
4
4
#   python-console <port> <magic> [<working-dir>]
5
5
 
 
6
import cjson
6
7
import codeop
7
8
import cPickle
8
9
import cStringIO
264
265
            self.globs = {'__name__': '__main__'}
265
266
            for g in params:
266
267
                try:
267
 
                    self.globs[g] = cPickle.loads(str(params[g]))
268
 
                except cPickle.UnpicklingError:
 
268
                    self.globs[g] = cPickle.loads(params[g])
 
269
                except:
269
270
                    pass
270
271
 
271
272
        # Return the current globals