Skip to content

Commit 317bec0

Browse files
emilruehrandomn4me
authored andcommitted
Ensure textwrap gets passed integer preventing TypeError in certain terminal widths
1 parent 939e6ba commit 317bec0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dictcc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def parse_single_tag(tag):
3434
all_dfn = ", ".join([dfn_tag.text for dfn_tag in tag.find_all('dfn')])
3535
str_tag = ' '.join([str_tag, '(' + all_dfn + ')'])
3636

37-
return '\n '.join(textwrap.wrap(str_tag, (int(columns) - 8) / 2))
37+
return '\n '.join(textwrap.wrap(str_tag, (int(columns) - 8) // 2))
3838

3939
def parse_response(html):
4040
soup = BeautifulSoup(html, 'html.parser')

0 commit comments

Comments
 (0)