labjack/labjack-ljm-python

LJM repo/package

Closed this issue · 15 comments

Is it possible for the labjack team to create an official repo here for the LJM library as well ? https://labjack.com/support/software/examples/ljm/python

Also publish to pypi. Would make it far easier to manage as dependency

We have not currently released LJM as open source and are hesitant to do so. However, would it fit your needs if we distributed LJM via package managers? Pypi is a Python package manager, so we would probably distribute via language-agnostic package managers. What OSes or distributions of Linux are you using?

We are running this on each of Mac, Linux and Windows. Currently we are just creating a repo and importing the .zip file with the library in there. Would be far easier to pip install it, just like the other Labjack libary

FWIW I think closed-source is a poor choice for a company that makes its money from selling the hardware. The basic idea IMHO is to make it as easy and flexible as possible for people to use that hardware.

But, yes, making wheels available for Python users to install easily is an essential basic step (that still hasn't been taken as far as I can see).

Given the popularity of Python (http://pypl.github.io/PYPL.html) I would really expect to see LabJack looking after this community better. For instance, after I suggested providing wheels (Sept 2016, #GH-93) it took until Jan 2019 for the first wheel to appear. I hope it doesn't take a similar 2 years, this time, to agree that allowing pip install labjack is a good idea. Which platforms should you support? All of Win32, Win64, Mac, and Linux! You can build widely-compatible linux wheels using the manylinux project and all the others are even easier (given that you alredy know how to write a setup.py file). You can/should also automate building using one of many CI tools so that it's easy to release a new version after a bug-fix (so we don't wait 2 years in between releases).

I don't know though. I think, for me, it might be too late. After years of recommending that PsychoPy users use LabJack for their interfaces, I'm starting to think it's time for our users to go elsewhere. :-(

Regarding getting Python LJM on PyPI for pip and getting its source on GitHub, we can look into that soon. Soon as in weeks and not years. The source is currently available on the Python LJM page on our site, in the download. Initial PyPI release will be just the Python modules and not driver binaries. We are considering the driver release options for Python.

As for LabJackPython and wheels you mentioned, it was in the beta repo. in 2016 and 2019 was the next official LabJackPython release. In the future we will have better turn around times between important updates in the repo, and official releases. Delaying for Python 3 testing is no longer an excuse.

Thanks Dave. Sorry for the rant. I know this isn't your fault. If there's anything I can do to help convince management to make Python support more of a priority then let me know! :-)

We have not currently released LJM as open source and are hesitant to do so.

I must be missing something. Python ljm package is available on the website as a zip file, all in source ? With setup.py in it and everything.

Direct link: https://labjack.com/sites/default/files/software/Python_LJM_2018_10_19.zip

What's wrong with putting a copy of this on Github directly ? Like i said, we already do that internally anyway and just copy the zip file up to Github, so that it can be pip installed.

The next version of the Python LJM package, v1.20, will be on GitHub and PyPi. The current plan is to use the distribution name labjack-ljm (pip install labjack-ljm) instead of LJMPython. Namespace/package and API will remain the same.

The Python LJM repo. is on GitHub now:

https://github.com/labjack/labjack-ljm-python

In the upcoming days there will be an official v1.20 release which will be on PyPi. The README has pip installation instructions which are not valid until the first PyPi release.

@kaidokert, the source code for the Python wrapper (for which source code is now available here: https://github.com/labjack/labjack-ljm-python as @davelopez01 just mentioned) is separate from the actual LJM library, which is written in C++ and for which the source code is not publicly available.

labjack-ljm version 1.20 is now available on PyPi.

Thanks @davelopez01. I'll include/recommend with PsychoPy. This is just for T4, T7, right? Not supporting U3 etc?

Also, am I right in thinking the dylibs aren't packaged so users need to install drivers from somewhere else first?

Now that there is a labjack-ljm-python repository on GitHub, I suggest closing this issue (or transferring it) and having LJM Python discussions there. This issue tracker is for LabJackPython, which is a different software package.

@peircej, yes, LJM is for T-series only (T4, T7). Also, yes, you are correct that the LabJackM library files (.dylib/.so/.dll) aren't packaged. We're thinking about ways to programmatically install that, though.

@mnaberez, good point. The transfer seems to have worked.

To be explicit, the current place to get the LJM library files is here:

https://labjack.com/support/software/installers/ljm