MCPcopy
hub / github.com/django/django / process

Method process

django/utils/text.py:179–182  ·  view source on GitHub ↗
(self, data)

Source from the content-addressed store, hash-verified

177
178class TruncateWordsHTMLParser(TruncateHTMLParser):
179 def process(self, data):
180 data = re.split(r"(?<=\S)\s+(?=\S)", data)
181 output = escape(" ".join(data[: self.remaining]))
182 return data, output
183
184
185class Truncator(SimpleLazyObject):

Callers

nothing calls this directly

Calls 3

escapeFunction · 0.90
splitMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected