You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ tabview "test#file.CSV"
Traceback (most recent call last):
File "/home/matthew/Documents/TSE/Internships/IEA/Workload/aws-batch/nemweb-batch/csv2parquet/venv/bin/tabview", line 108, in <module>
view(data, enc=args.encoding, start_pos=start_pos,
File "/home/matthew/Documents/TSE/Internships/IEA/Workload/aws-batch/nemweb-batch/csv2parquet/venv/lib/python3.12/site-packages/tabview/tabview.py", line 1301, in view
with open(parsed_path, 'rb') as fd:
^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'test'
Same result with using single quotes or no quotes to escape the file name.
Cause
urlparse will delete the # component, because for http URLs that makes sense. For local files, # doesn't mean anything different to other characters.
Since files are openned with open(parsed_path, 'rb'), it seems like tabview doesn't support reading remote files over http. So what's the point of the urlparse usage?
Solution
Delete the parse_path function. Just keep the filename data string as is.
The text was updated successfully, but these errors were encountered:
Steps to reproduce
Create a file with a hash in the name.
Try to read it with another tool:
Now try with tabview (1.4.4)
Same result with using single quotes or no quotes to escape the file name.
Cause
urlparse
will delete the#
component, because for http URLs that makes sense. For local files,#
doesn't mean anything different to other characters.Since files are openned with
open(parsed_path, 'rb')
, it seems liketabview
doesn't support reading remote files over http. So what's the point of theurlparse
usage?Solution
Delete the
parse_path
function. Just keep the filenamedata
string as is.The text was updated successfully, but these errors were encountered: