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

[Bug]: Error: write EPIPE #14

Closed
rkynaston opened this issue Apr 22, 2022 · 7 comments
Closed

[Bug]: Error: write EPIPE #14

rkynaston opened this issue Apr 22, 2022 · 7 comments
Assignees
Labels
bug Something isn't working fixed in beta / next release this is a resolved issue which is fixed in current beta and will be fixed in next release

Comments

@rkynaston
Copy link

What happened?

Checking my home bridge Logs and seem to be getting a number of Error: write EPIPE exceptions through.

Currently have 3 cameras and 1 doorbell.

Device Type

Station (Supported)

Plugin Version

beta (Best Effort)

HomeBridge Version

v1.4.x (Supported)

NodeJS Version

v16 (Supported)

Operating System

Raspbian 10+ (Supported)

Relevant log output

[21/04/2022, 22:00:46] [homebridge-eufy-security] ErrorCode EPIPE
[21/04/2022, 22:00:46] [homebridge-eufy-security] Error: write EPIPE
    at afterWriteDispatched (node:internal/stream_base_commons:160:15)
    at writeGeneric (node:internal/stream_base_commons:151:3)
    at Socket._writeGeneric (node:net:795:11)
    at Socket._write (node:net:807:8)
    at writeOrBuffer (node:internal/streams/writable:389:12)
    at _write (node:internal/streams/writable:330:10)
    at Socket.Writable.write (node:internal/streams/writable:334:10)
    at Readable.ondata (node:internal/streams/readable:754:22)
    at Readable.emit (node:events:520:28)
    at addChunk (node:internal/streams/readable:315:12) {
  errno: -32,
  code: 'EPIPE',
  syscall: 'write'
}
@rkynaston rkynaston added the bug Something isn't working label Apr 22, 2022
@github-actions
Copy link

Did you check this Common Issues pages ?

@rkynaston
Copy link
Author

Did you check this Common Issues pages ?

Yep. Issue not listed.

@lenoxys
Copy link
Contributor

lenoxys commented Apr 22, 2022

Hello,

Error is not referencing plugin code. Can you enable debug mode and push log when EPIPE exception occur?

@aklausing
Copy link

Hi,
I experience this failure with beta.9 sometimes with Doorbell (T8210) and most of the times with a Floodlight Cam (T8424). It happens when starting a stream manually in home app. Screenshot fetch stream seams to work without issues.

This seems to be related to ffmpeg .. I will attach logs as soon as I enabled debug and can generate a little more output.

@thieren
Copy link
Contributor

thieren commented May 28, 2022

Hi,

this error seems to be some type of race condition in the code.
If a stream was started (for me it happened also with snapshots sometimes) the streams are piped into the ffmpeg process.
Eventually the stream is stopped and the ffmpeg process shuts down. However sometimes the eufy-security-client still sends a video package into the process. ffmpeg might already be exited but the input stream is still open. In the code you can see, that the input stream is closed just shortly after the process is exited.
If that happens the error occurs due to that the package cannot be written into the process.

I don't see what there could be done at the moment but also this error doesn't seem to have any effect apart of the log output.

@thieren
Copy link
Contributor

thieren commented Aug 1, 2022

This error should be fixed with 2.1.0-beta.14

@thieren thieren added the fixed in beta / next release this is a resolved issue which is fixed in current beta and will be fixed in next release label Aug 1, 2022
@thieren thieren self-assigned this Aug 1, 2022
@thieren thieren mentioned this issue Sep 3, 2022
@thieren
Copy link
Contributor

thieren commented Sep 6, 2022

Is fixed with release of 2.1.0

@thieren thieren closed this as completed Sep 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed in beta / next release this is a resolved issue which is fixed in current beta and will be fixed in next release
Development

No branches or pull requests

4 participants