conda-incubator / conda-store

Data science environments, for collaboration. ✨
https://conda.store
BSD 3-Clause "New" or "Revised" License
149 stars 50 forks source link

[BUG] - conda-store-server --version does not work #977

Closed soapy1 closed 4 days ago

soapy1 commented 1 week ago

Describe the bug

Running the command conda-store-server --version prints 0.0.

Expected behavior

conda-store-server --version should output the version number of the package. For example

$ conda-store-server --version
2024.11.1

How to Reproduce the problem?

To reproduce, follow the steps

$ conda create -n test-env conda python
...

$ conda activate test-env

$ pip install conda-store-server
...

$ conda-store-server --version
0.0
trallard commented 1 week ago

This is expected to a certain point as conda-store-server does not have a CLI per se but uses traitlets to parse and set app configurations from the command line or a config file. We could technically add a --version flag, as we do for --standalone, but I don't think this is needed.

soapy1 commented 1 week ago

Ahh, I see makes sense that it's a traitlets thing. I took a little peak at the traitlets code and it looks like it does provide the --version flag already, and it's populated by the version property on the Application class.

So, should be fixed by https://github.com/conda-incubator/conda-store/pull/981