Skip to content

issue with csv.reader #1

Open
Open
@aadm

Description

@aadm

Thanks for the script and the thorough writeup on your blog. I wanted to use it to go back to Keepass after having tried Enpass for a while but it didn't work for me. This was the error:

Traceback (most recent call last):
  File "enpass-to-keepass.py", line 84, in <module>
    main(parser.parse_args())
  File "enpass-to-keepass.py", line 33, in main
    for row in reader:
_csv.Error: line contains NULL byte

I did a little digging on stackexchange and fixed the issue by by replacing this line (#29):

reader = csv.reader(args.input_file)

with this:

reader = csv.reader((line.replace('\0','') for line in args.input_file), delimiter=",")

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions