I have a pandas dataframe that I want to display as a table in an html template. It works for the most part, but some of the strings in the dataframe are being truncated. I am using to_html() to convert my pandas dataframe to an html friendly table and tried using the col_space argument but it didn't seem to have any affect.
The python code:
options = dbi.getDBTables() #returns a list of the names of available tables
table_headers = []
for table_name in options:
table_name = str(table_name)
df = dbi.selectDF("SELECT * FROM %s LIMIT 1" % table_name) #gets the actual dataframe for each table name
header = df.columns.values
header = "<br>".join(header)
table_headers.append(header)
header_dict = dict(zip(options,table_headers))
table_options = pandas.DataFrame(header_dict,index=[0])
table_options = table_options.to_html(classes=["table table-hover"],index=False,escape=False,col_space=400) #changing the col_space does nothing.
search_dict = {'table_names':table_options}
The html code:
<div class="table-responsive">
{{ table_names | safe }}
</div>
Picture of table with truncation occurring:

How do you get pandas to stop truncating (shown as '...' in picture) content?
Much appreciated!