kneufeld/consolemd

Support click 7

Closed this issue · 7 comments

It is possible to support click>=7?

Why? What features would that give the project?

The thing is, my Linux distribution doesn't package old versions of click anymore. It currently only has a package for 7. Thus, I'd have to write a separate package for the old version (or use a venv, but I'm using consolemd for a globally available package).
I get what you're saying: why update libraries that work perfectly fine? I think it would be smart though, because Python as a language is also evolving and it could be with some future version of Python, click (or other dependencies) doesn't work anymore. Also, with old libraries, there might be security concerns.

I'm very glad to hear you value consolemd enough to want it installed globally. 😊

However, I'd highly recommend always using virtual environments, the pain you're feeling right now is why. They're also easy enough to use even globally. The readme explains how to do this, just make a symlink from /usr/local/bin/consolemd to /path/to/venv/bin/consolemd. Installing in /opt shouldn't surprise a future sys admin.

But seriously, always use venvs. At some point you're guaranteed you'll come across a situation where where apps A and B need different versions of the same library. And different Linux distros will package different versions of a given python library, and some distros won't even package that particular python lib, etc. Distro python packages are more-or-less only there to support applications that the distro itself needs.

Having said all that I'm not opposed to upgrading click (or any library) but forever chasing the latest version of libraries for no tangible benefit is a never ending chase.

I'd be much more inclined to create an executable with pyinstaller so all this becomes a non-issue.

I've now got travis.ci building an executable with pyinstaller. The filename still needs some love but the following link works on linux:

https://github.com/kneufeld/consolemd/releases/download/v0.4.5/consolemd

chmod +x consolemd after download

binary filename now has architecture appended to it

curl -L -o consolemd https://github.com/kneufeld/consolemd/releases/download/v0.4.6/consolemd-linux-x86_64
chmod +x consolemd
./consolemd --version

@pmiddend please let me know if this solution is acceptable so this issue can be closed

Actually, there's another solution to the dependency hell problem: the nix package manager, a distribution/package manager I'm contributing to. Thanks for your input though, although it's not a solution for me.

consolemd now uses click v7