-
Notifications
You must be signed in to change notification settings - Fork 12
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
playactor login (registration) with PS5: Unhandled 'error' event #23
Comments
Wow, thanks for the very detailed issue report! Should be easy enough to handle but in the meantime a simple workaround is to do the setup on your Mac and copy the credentials file over to the device. Credentials are stored at |
Also, to provide a little more detail: it's waiting to open the URL until you hit enter; you see the error after you paste and hit enter because that's what triggers it to try (and fail) to open the URL. |
@dhleong, I apologize for being such a noob here, but could you provide a bit more detail regarding the workaround?
The device is my Raspberry Pi, which is not running an OS with a file (folder) system (that I know of)... just Homebridge (with Homebridge UI – via the web interface I am not sure how I would access or copy the credentials file over to the device. Would this all be done via Terminal? Also, when you say this "should be easy enough to handle," does that mean you should be able to update playactor so a workaround, in this scenario, won't be necessary? I'm just curious, in case I'm unable to figure out the workaround, lol. Thanks again for all your playactor work/effort, and for your help here! @aclerok, I am starting to think you ran into a similar issue and had to implement a workaround as well. Would you be able to provide more detail? Thanks! |
1. How do I do the setup on my Mac? What do I use, etc.?
Run `playactor login` from the terminal after installing it per the README
1. How do I copy the credentials file over to the *device*?
The *device* is my Raspberry Pi, which is *not* running an OS with a file
(folder) system (that I know of)... just *Homebridge* (with Homebridge UI
<https://github.com/oznu/homebridge-config-ui-x#readme> – via the *web
interface* homebridge.local/ – and *Homebridge Terminal*), which is
flashed to the SD card.
I am not sure how I would access or copy the credentials file over to the
*device*. Would this all be done via *Terminal*?
I don’t know anything about Homebridge or how that works, but I would
assume there’s some flavor of linux running under the hood. The normal way
to access a headless device like that would be to have a ssh server running
and you could do something like:
scp -r ~/.config/playactor <your-device>:~/.config/playactor
But again, I don’t know how Homebridge works. You may be able to do this
through its web interface, but I have no idea.
Also, when you say this "should be easy enough to handle," does that mean
you should be able to update playactor
<https://github.com/dhleong/playactor> so a workaround, in this scenario,
won't be necessary? I'm just curious, in case I'm unable to figure out the
workaround, lol.
I’ll be able to update playactor to handle your scenario! Basically just
need to be more careful around launching that URL and maybe make the
instructions clearer.
Thanks again for all your playactor <https://github.com/dhleong/playactor>
work/effort, and for your help here!
:)
|
What I found in my install was this: you are running the What @dhleong is mentioning above with copying your folder is essentially doing the same thing. In practice might be easier than my method, as there were multiple steps to get the homebridge user the correct permissions, etc. |
@dhleong, thanks!! I may wait for the update, though, as I'm still not sure I fully understand the workaround... and I'm not sure I want to try, especially knowing that an update/fix is imminent. @aclerok, thanks for the info! Though, I'm not sure I understand why your setup was/is running from a different user than the Homebridge service. How is your Homebridge setup? It sounds like you have an OS installed on your Raspberry Pi, and then you installed Homebridge within that OS? If so, does that mean you used VNC to remote into the OS installed on the Pi, and then manage Homebridge from there? For my setup, since I don't have an OS installed on my Pi (and thus don't have Homebridge installed within an OS), I have to manage Homebridge externally (from a different computer), via the web interface I'm wondering if my issue is "user" related, like yours was... or if my issue is different? Were you getting the same error as me? |
Yes, this is my scenario exactly. I'm not sure exactly how the web based console works in your setup. Essentially I consoled in to my Pi as User1 and the homebridge software was running as User2. Since I ran the |
@dhleong I installed the latest playactor update (0.2.2), but I'm still running into the same issue. The only difference is that now it only shows the URL (that it wants to auto-open) after I hit enter. I've tried hitting enter without pasting the "redirect," and I've tried pasting the "redirect" and then hitting enter. Both ways result in the same error as before (shown below). Why can't I just paste the "redirect" and hit enter? How is this supposed to work? It's unclear as I feel like I am following the instructions but can't get past this registration process and resulting error. The only thing I can think of is that, due to my setup, the auto-open URL thing is the hangup. Is it possible to remove the need to auto-open the URL and just let people click on the link, and then paste the "redirect" and hit enter? I use ps4-waker (with the same Homebridge setup) without any issues, so it must be possible. Attempt/errors
|
The auto-open is definitely the hang up. The library apparently does not
work the way I thought it did. Basically the error isn’t getting caught by
the library the way I expected it to, which is crashing the rest of the
process. Since I can’t repro, I just guessed based on an (incorrect)
assumption. Should still be easy enough to fix; I’ll take another look
either later today or tomorrow morning.
…On Apr 14, 2021 at 1:23:03 PM, LordZork ***@***.***> wrote:
@dhleong <https://github.com/dhleong> I installed the latest playactor
<https://github.com/dhleong/playactor> update (0.2.2
<https://github.com/dhleong/playactor/releases/tag/0.2.2>), but I'm still
running into the same issue. The only difference is that now it only shows
the URL (that it wants to auto-open) after I hit enter.
I've tried hitting enter without pasting the "redirect," and I've tried
pasting the "redirect" and then hitting enter. Both ways result in the same
error as before (shown below).
Why can't I just paste the "redirect" and hit enter? How is this supposed
to work? It's unclear as I feel like I am following the instructions but
can't get past this registration process and resulting error.
The only thing I can think of is that, due to my setup, the auto-open URL
thing is the hangup. Is it possible to remove the need to auto-open the URL
and just let people click on the link, and then paste the "redirect" and
hit enter?
I use ps4-waker <https://github.com/dhleong/ps4-waker> (with the same
Homebridge setup) without any issues, so it must be possible.
Attempt/errors
***@***.***:/var/lib/homebridge $ playactor login
In a moment, we will attempt to open a browser window for you to login to your PSN account.
When the page shows "redirect", copy the URL from your browser's address bar and paste it here.
Hit ENTER to continue
URL> events.js:292
throw er; // Unhandled 'error' event
^
Error: spawn xdg-open ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:269:19)
at onErrorNT (internal/child_process.js:465:16)
at processTicksAndRejections (internal/process/task_queues.js:80:21)
Emitted 'error' event on ChildProcess instance at:
at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
at onErrorNT (internal/child_process.js:465:16)
at processTicksAndRejections (internal/process/task_queues.js:80:21) {
errno: -2,
code: 'ENOENT',
syscall: 'spawn xdg-open',
path: 'xdg-open',
spawnargs: [
'<url>'
]
}
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#23 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGHIFQKVAE2YYZVMYWEATDTIXFPPANCNFSM422EUH2Q>
.
|
@dhleong sounds good, thanks again for all your work on this! |
Check out v0.2.3; hopefully this will catch that error more gracefully! |
@dhleong, perfect—that did the trick! Thanks!!! |
Hi, i have the playactor on a Synology NAS running in a docker. How can I fix this with the open browser problem? Thank You |
This is actually similar to what @dwffls most recently experienced/mentioned shortly before you closed #19.
I have not encountered the
removeAllListeners
error that was also mentioned, only the error below... which I have experienced with both playactor 0.2.0 and playactor 0.2.1.Notes:
USAGE/SETUP
Using Homebridge on a Raspberry Pi, flashed to an SD card – i.e., no OS on the Pi, other than Homebridge, which uses Raspbian GNU/Linux Buster (10).
Using node.js v14.16.1 and npm v7.9.0.
Using Homebridge UI (homebridge-config-ui-x v4.41.0) via the web interface
homebridge.local/
– via Google Chrome – from my Mac (macOS 10.15.7), to connect to/manage Homebridge and related plugins, and to run Homebridge Terminal installs, commands, etc. (which are all running on the Pi).ATTEMPTS/RESULTS
When I attempt
playactor login
in Homebridge Terminal (where playactor is operating), it returns:In a moment, we will attempt to open a browser window with the following URL:
<url>
Perform login there, then, when the page shows "redirect", copy the URL from your browser's address bar and paste it here.
Hit ENTER to continue
Based on my usage/setup (I'm guessing), the provided
<url>
doesn't auto-open. I have to click on the<url>
link, which then opens in a new browser window/tab on my Mac (OUTSIDE of where playactor is operating).After clicking on/opening the provided
<url>
and logging in, I copy/paste the "redirect" URL – into Homebridge Terminal (where playactor is operating) in thehomebridge.local/
browser window/tab – and then "Hit ENTER to continue".The result is the following error(s), which is what @dwffls most recently experienced/mentioned...
ERROR(S)
@dhleong, per your request from ps4-waker#150, I will continue any setup-specific discussions (i.e., using playactor with Homebridge) here: discussion #22.
@aclerok, would you view discussion #22 and – if possible – explain your playactor and Homebridge setup/steps, and any other related setup/steps, as well as the steps you used to resolve your login issue(s)? Thanks!
The text was updated successfully, but these errors were encountered: