MCPcopy Index your code
hub / github.com/fabioz/PyDev.Debugger / generate_dont_trace_files

Function generate_dont_trace_files

build_tools/generate_code.py:108–224  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

106
107
108def generate_dont_trace_files():
109 template = """# Important: Autogenerated file.
110
111# fmt: off
112# DO NOT edit manually!
113# DO NOT edit manually!
114
115LIB_FILE = 1
116PYDEV_FILE = 2
117
118DONT_TRACE_DIRS = {
119%(pydev_dirs)s
120}
121
122LIB_FILES_IN_DONT_TRACE_DIRS = {
123%(pydev_lib_files_in_dont_trace_dirs)s
124}
125
126DONT_TRACE = {
127 # commonly used things from the stdlib that we don't want to trace
128 'Queue.py':LIB_FILE,
129 'queue.py':LIB_FILE,
130 'socket.py':LIB_FILE,
131 'weakref.py':LIB_FILE,
132 '_weakrefset.py':LIB_FILE,
133 'linecache.py':LIB_FILE,
134 'threading.py':LIB_FILE,
135 'dis.py':LIB_FILE,
136
137 # things from pydev that we don't want to trace
138%(pydev_files)s
139}
140
141# if we try to trace io.py it seems it can get halted (see http://bugs.python.org/issue4716)
142DONT_TRACE['io.py'] = LIB_FILE
143
144# Don't trace common encodings too
145DONT_TRACE['cp1252.py'] = LIB_FILE
146DONT_TRACE['utf_8.py'] = LIB_FILE
147DONT_TRACE['codecs.py'] = LIB_FILE
148
149# fmt: on
150"""
151
152 pydev_files = []
153 pydev_dirs = []
154 pydev_lib_files_in_dont_trace_dirs = []
155
156 exclude_dirs = [
157 ".git",
158 ".settings",
159 "build",
160 "build_tools",
161 "dist",
162 "pydevd.egg-info",
163 "pydevd_attach_to_process",
164 "pydev_sitecustomize",
165 "stubs",

Callers 4

build.pyFile · 0.90
mainFunction · 0.90
mainFunction · 0.90
generate_code.pyFile · 0.85

Calls 4

appendMethod · 0.45
removeMethod · 0.45
joinMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected