mirror of
https://github.com/beetbox/beets.git
synced 2025-12-25 10:05:13 +01:00
"profile" command in BPD for memory debugging
This commit is contained in:
parent
2768e71c21
commit
072680e894
1 changed files with 6 additions and 0 deletions
|
|
@ -550,6 +550,12 @@ class BaseServer(object):
|
|||
index = self._id_to_index(track_id)
|
||||
return self.cmd_seek(conn, index, pos)
|
||||
|
||||
def cmd_profile(self, conn):
|
||||
"""Memory profiling for debugging."""
|
||||
from guppy import hpy
|
||||
heap = hpy().heap()
|
||||
print heap
|
||||
|
||||
class Connection(object):
|
||||
"""A connection between a client and the server. Handles input and
|
||||
output from and to the client.
|
||||
|
|
|
|||
Loading…
Reference in a new issue