hassio-addons / addon-motioneye

motionEye - Home Assistant Community Add-ons

Home Page:https://addons.community

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Update Motioneye Addon

Ryu945 opened this issue · comments

commented

Problem/Motivation

I can't use sftp on an external sftp server because MotionEye is very out of date. The version of the addons python is 2.7 while the current version is 3.5 to give you an idea how out of date this is.

Expected behavior

For motioneye to be able to upload files to an sftp server

Actual behavior

It errors out with these logs
error: (48, '')
/bin/sh: lsb_release: not found
ERROR: failed to upload file "/share/motioneye/Camera1/2023-01-27/18-35-13.jpg" with service sftp: (48, '')
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/motioneye/uploadservices.py", line 1103, in upload_media_file
service.upload_file(target_dir, filename, camera_name)
File "/usr/lib/python2.7/site-packages/motioneye/uploadservices.py", line 103, in upload_file
self.upload_data(rel_filename, mime_type, data, ctime, camera_name)
File "/usr/lib/python2.7/site-packages/motioneye/uploadservices.py", line 989, in upload_data
conn = self._get_conn(filename)
File "/usr/lib/python2.7/site-packages/motioneye/uploadservices.py", line 1033, in _get_conn
self._conn.setopt(self._conn.SSH_AUTH_TYPES, auth_types[auth_type])

Steps to reproduce

  1. Set motioneye to upload to a sftp server
  2. Try trigger it so motioneye takes a picture or video

Proposed changes

Update it with the new Motioneye project. A different maintainer took over the project and is updating it in a different repository: https://github.com/motioneye-project/motioneyeos

Cool, but motionEye doesn't support Python 3 yet 🤷‍♂️

While there has been work in a new org with new maintainer, the job isn't completed and nothing has been released up until now.

commented

Cool, but motionEye doesn't support Python 3 yet man_shrugging

While there has been work in a new org with new maintainer, the job isn't completed and nothing has been released up until now.

Can Motion Eye at least be kept up to date on the most recent version that relies on Python 2.x in the mean time?

It runs the latest version? I am missing something?

commented

It runs the latest version? I am missing something?

The last update on https://github.com/motioneye-project for motioneyeos was on 4/20/22 and for motioneye was on 12/23/22 . The last update for this addon was on 3/15/22 . I didn't look to see what that change was but it implies that something has changed. Also, there are problems with the addon that the current version of motioneye/motioneyeos does not have. For example, you can use external sftp servers fine on the other two but not the HA addon. It could be an out of date issue or it could be some other issue causing this.

The last release is:

image

Which this add-on runs:

../frenck

commented

If it is not an out of data issue then there must be a bug in the HA addon or a system it interacts with itself since external SFTP doesn't work in the addon but it does work with the original motioneye/motioneyeos .

This is not motioneyeos...

based on the provided logs, I don't know where to go. motionEye is heavily outdated, the OS running on this add-on as well (as upgrading can't be done any further due to losing access to Python 2).

I'm probably going to deprecate and remove the add-on anytime soon, if the motionEye project doesn't move forward.

../Frenck

commented

I'm probably going to deprecate and remove the add-on anytime soon, if the motionEye project doesn't move forward.

That would be a bad idea since that is the only addon that lets you connect a USB camera to HomeAssistant. I talked with the people over at that motioneye/motioneyeos project. They said they in the process of a long overhaul to move to python 3. It seems best to wait for that overhaul to finish if it is not possible to patch the current version of the Motioneye addon. It still works as a camera that saves pictures and videos at least. Thankyou for your time.

That would be a bad idea since that is the only addon that lets you connect a USB camera to HomeAssistant.

The waiting ends at some point 🤷

They said they in the process of a long overhaul to move to python 3.

I know they are, however, it has been that way for years now. The activity has pretty much stalled (even under the new project team), which is visible by the commit/change speed on the repository. Besides dependency bumps, almost nothing happens (with a rare commit 2-3 months ago).

I do monitor upstream closely.

It still works as a camera that saves pictures and videos at least.

There are alternatives available, wich one could consider. At this point, I would not recommend on starting with motionEye.

../Frenck