This will check if pycarddav is run by tty or not.

Therefor one can run pycarddav using a pipe as password source with passwd disabled in ~/.config/pycard/pycard.conf.
Like $pass show /path/to/pass | pycarddav