Permalink
Browse files

cleanup

  • Loading branch information...
1 parent b0866cc commit 9c7cca2477439302867cdcb8368ac5609bcb3151 @tamentis committed Jan 27, 2012
Showing with 13 additions and 8 deletions.
  1. +1 −1 LICENSE.txt
  2. +2 −2 README.rst
  3. +7 −4 rpdb/__init__.py
  4. +3 −1 setup.py
View
@@ -1,4 +1,4 @@
-Copyright (c) 2010 Bertrand Janin <tamentis@neopulsar.org>
+Copyright (c) 2010,2012 Bertrand Janin <tamentis@neopulsar.org>
All rights reserved.
Redistribution and use in source and binary forms, with or without
View
@@ -12,7 +12,7 @@ But you can change that by simply instantiating Rpdb manually::
debugger = rpdb.Rpdb(12345)
debugger.set_trace()
-It is known to work on Jython 2.5, Python 2.5 and Python 3.1. It was written
+It is known to work on Jython 2.5, Python 2.5 to 3.1. It was written
originally for Jython since this is pretty much the only way to debug it when
running it on Tomcat.
@@ -42,7 +42,7 @@ Author(s)
---------
Bertrand Janin <tamentis@neopulsar.org> - http://tamentis.com/
-The idea comes from there:
+This is inspired by:
http://bugs.python.org/issue721464
http://snippets.dzone.com/posts/show/7248
View
@@ -1,13 +1,15 @@
"""Remote Python Debugger (pdb wrapper)."""
__author__ = "Bertrand Janin <tamentis@neopulsar.org>"
-__version__ = "0.1.1"
+__version__ = "0.1.2"
import pdb
import socket
import sys
+
class Rpdb(pdb.Pdb):
+
def __init__(self, port=4444):
"""Initialize the socket and initialize pdb."""
addr = socket.gethostname()
@@ -41,11 +43,12 @@ def do_continue(self, arg):
do_EOF = do_quit = do_exit = do_c = do_cont = do_continue
+
def set_trace():
"""Wrapper function to keep the same import x; x.set_trace() interface.
-
- We catch all the possible exceptions from pdb and cleanup before
-
+
+ We catch all the possible exceptions from pdb and cleanup.
+
"""
debugger = Rpdb()
try:
View
@@ -4,7 +4,7 @@
setup(
name="rpdb",
- version="0.1.1",
+ version="0.1.2",
description="Remote debugger based on pdb",
author="Bertrand Janin",
author_email="tamentis@neopulsar.org",
@@ -19,6 +19,8 @@
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
"Programming Language :: Python :: 2.5",
+ "Programming Language :: Python :: 2.6",
+ "Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
"Topic :: Software Development :: Debuggers",

0 comments on commit 9c7cca2

Please sign in to comment.