Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workaround for pop-up disfunction when trying lplogin(FYI) #57

Open
juniuspan opened this issue Aug 3, 2019 · 1 comment
Open

Workaround for pop-up disfunction when trying lplogin(FYI) #57

juniuspan opened this issue Aug 3, 2019 · 1 comment

Comments

@juniuspan
Copy link

Hi, everyone!

Here is my problem.
When trying lplogin, the password input window doesn't pop-up, debugging info shows:

[18:04:31.473] Logging Started...
[18:04:38.895] LastPass CLI[Keyword] Processing complete
[18:04:38.897] LastPass CLI[Keyword] Passing output '' to Run Script
[18:04:40.579] ERROR: LastPass CLI[Run Script] 2465:2767: execution error: Error: Unable to retrieve password from askpass (no reply) (1)

After confirming that lpass functions normally in terminal, I checked the configuration of the extension on the graphic console, finally found out the error with the path of "passwordInput.osascript". Simply modify the following codes in the script labelled with "/usr/bin/osascript" can solve the problem.

Before:
set osascript to (system attribute "alfred_preferences") & "/workflows/" & (system attribute "alfred_workflow_uid") & "/passwordInput.osascript"
After:
set osascript to <your personal absolute path of "passwordInput.osascript">

Since I'm not a programmer, I don't understand why the original codes disfunction. I doubt if this can be attributed to the personalized preference folder path of Alfred. This is just a workaround solves my problem, better if it could be of some reference to people who come across this problem.

Regards,
Jun

@dominikb
Copy link

I've had a similar issue but with a different cause.

As juniuspan, I first verified, that the login was possible using the lpass cli tool.

Whenever I tried to login I recieved the following error:

[17:38:43.727] LastPass CLI[Keyword] Processing complete
[17:38:43.727] LastPass CLI[Keyword] Passing output '' to Run Script
[17:38:43.907] ERROR: LastPass CLI[Run Script] 2845:2846: syntax error: Expected end of line but found “"”. (-2741)

I changed the last paragraph of the script from:

if ("{query}" = "scriptlocationnotset") then
tell application "Alfred 3" to search "lp "
end if

to

if ("{query}" = "scriptlocationnotset") then
tell application "Alfred" to search "lp "
end if

and the login suddenly worked correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants