-
Notifications
You must be signed in to change notification settings - Fork 101
Open
Description
Greetings,
I'm trying to add an entry with an empty password like that:
entry = kp.add_entry(group, "test", "test", password=None)But I'm getting this error:
.venv/lib/python3.13/site-packages/pykeepass/pykeepass.py:695: in add_entry
entry = Entry(
.venv/lib/python3.13/site-packages/pykeepass/entry.py:45: in __init__
E.String(E.Key('Password'), E.Value(password, Protected="True"))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> ???
E TypeError: bad argument type: NoneType(None)
src/lxml/builder.py:219: TypeErrorThe documentation say that the password argument can be None:
https://libkeepass.github.io/pykeepass/pykeepass.html#PyKeePass.add_entry
I know that I should use an empty string, but I have to admit that passing None would simplify my code a bit.
Metadata
Metadata
Assignees
Labels
No labels