datasette-publish-vercel
datasette-publish-vercel copied to clipboard
Query page .csv and .json links are not correctly URL-encoded on Vercel under unknown specific conditions
Confirmed: https://thesession.vercel.app/thesession?sql=select+*+from+tunes+where+name+like+%22%25wise+maid%25%22%0D%0A is a page where the URL correctly encoded
%
as%25
- but then in the HTML on that page that links to the CSV and JSON versions we get this:<p class="export-links">This data as <a href="/thesession.json?sql=select * from tunes where name like "%wise maid%"">json</a>, <a href="/thesession.csv?sql=select * from tunes where name like "%wise maid%"&_size=max">CSV</a> </p>
Those CSV and JSON links are incorrect.
Originally posted by @simonw in https://github.com/simonw/datasette-publish-vercel/issues/48#issuecomment-900497579