Skip to content

Commit 1baabc8

Browse files
committed
jupyter-tramp-server-from-file-name: Fix password authenticator
fixes #480
1 parent 2f14f2e commit 1baabc8

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

jupyter-rest-api.el

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -532,8 +532,9 @@ slot of CLIENT and restore the AUTH slot on failure."
532532
&optional passwd)
533533
"Authenticate CLIENT by asking for a password.
534534
If PASSWD is provided it must be a function that takes zero
535-
arguments. It will be called before each authentication attempt.
536-
If CLIENT could not be authenticated raise an error."
535+
arguments and returns a password, it defaults to a call to
536+
`read-passwd'. It will be called before each authentication
537+
attempt. If CLIENT could not be authenticated raise an error."
537538
(or (functionp passwd)
538539
(setq passwd (lambda () (read-passwd (format "Password [%s]: "
539540
(oref client url))))))

jupyter-tramp.el

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -312,10 +312,9 @@ fails."
312312
(jupyter-api-authenticate client
313313
'password
314314
(let ((remote (file-remote-p filename)))
315-
(lambda (try)
315+
(lambda ()
316316
(jupyter-tramp-read-passwd
317-
filename (unless (zerop try)
318-
(format "Password for %s " remote))))))))))))))
317+
filename (format "Password [%s]: " remote)))))))))))))
319318

320319
;;; Getting information about file models
321320

0 commit comments

Comments
 (0)