-
Notifications
You must be signed in to change notification settings - Fork 14
Description
closes: #76, #27, #75, cylc/cylc-flow#4158
Open proposal to discuss the packaging-end-game for Cylc 8.
Doesn't really need a full-blown proposal-document, there isn't any fine print to haggle over.
cylc => cylc-flow
Early in the Cylc 8 project we renamed cylc => cylc-flow, some of the motivation:
- We were considering having a stripped-down cylc-flow package which just had client/message functionality for use on job hosts.
- We wanted the
cylcnamespace for the meta-package. - We considered separating the library and application layers of Cylc.
- Cylc Flow sounded cool.
In retrospect this might not have been the best idea:
- The client/message only package never materialised.
- All of the
cylc-*projects havecylc-flowas a dependency makingcylc-flowthe "core" component.- Note: The
cylccommand is provided bycylc-flowothercylcprojects register their subcommands via entry points.
- Note: The
- Separating the library and application would be a lot of work for no gain (especially given the previous point).
- We are less convinced by the role of the meta package than we were.
The meta-package
The intention of the meta package was to provide a one-click install for a fully-functional Cylc stack.
# i.e. this:
$ conda install cylc
# does the same as this:
$ conda install cylc-flow cylc-uiserver cylc-rose metomi-roseAdvantages:
-
The versions of each component get "pinned" in the meta-package ensuring environment consistency.
- However, we don't actually need a meta-package to enforce this consistency (1).
- For example
cylc-rosehas bothmetomi-roseandcylc-flowas dependencies. - This means that if you install
cylc-roseyour package manager (pip, conda) will ensure the two are compatible.
-
Ease of installation.
- Seemed like a good idea at the time, however, environments may have lots of variables.
- What bits of the system do they want installed in which places?
- What if they want to set the version of Python? Wouldn't we want to fix that in the meta-package?
- What if they want (or don't want) optional Cylc dependencies (e.g. Pandas used for cylc-report-timings)?
- What if they want to install the UI Server with the optional "hub" dependency.
- What if they want to install the Hub without the "configurable-http-proxy".
- Handling the matrix of "Cylc packages", "Cylc package installation options", "Cylc package dependency installation options" gets really, really messy.
Disadvantages:
-
We can't "deselect" packages to install (with conda, pypi is different).
- With Conda you can have multiple outputs, however, these aren't like optional-dependencies in PyPi.
- They are more like top-level projects. E.G. both cPython and PyPy produce the
pythonoutput. - So at the moment if you
conda install cylcyou get the whole lot whether you wanted it or not. - To get around this we would need special
metaoutputs e.g.cylc-meta-flow,cylc-meta-uiserver, etc.
-
Differing versions between
cylcandcylc-flow.- We would expect the meta-package version to start out as the cylc-flow version?
- If we want to make a maintenance release for
cylc-uiserverwe would need to bump the meta-package maintenance version? - So the meta-package and cylc-flow versions can mismatch.
- Unless we mandate that there is a cylc-flow maintenance version for each meta maintenance release?
- Otherwise
cylc versionshows the version ofcylc-flownot the meta package which is confusing if you installed via the meta package. - Where does the meta-package version get shown?
And so the meta-package has begun to look like a [complex] solution in need of a problem.
We would probably be better off adding a few example Conda recipes in cylc-doc and letting users decide how they want to install the stack.
The Future
Consistency
Currently all Cylc projects have a dependency on Cylc Flow.
We can give this dependency a very narrow version range (version "pinning") in order to ensure consistency between the different components.
Terminology:
<major>.<minor>.<maintenance>
Packages
There should be one-- and preferably only one --obvious way to do it.
If the meta-package serves little function we should probably cut our losses and get rid of it.
Doing so would leave us with three problems:
- The
cylcConda package.- Currently provides
cylc-flow,cylc-rose,cylc-uiserver,metomi-rose.
- Currently provides
- The
cylcPyPi package.- Currently provides cylc-flow 8.0a0 and nothing else.
- The slightly-confusing
cylc-flowproject name.- Just seems a bit odd considering that it is the core component of the system.
Options:
- We could delete the
cylcpackages (makes us vulnerable to typo-squatting) - We could make them dead-end packages (i.e. if you try to install them you get an error telling you not to install them).
- I think you can do this on PyPi.
- I have asked the conda-forge people, so far they have said that typosquatting protection comes from the review process...
- ... This is fair, however, would this happen in practice?
- We could retire the
cylc-flowpackages and use these instead.
Related: Should we claim the namespace
cycl(and possiblyclyc?) since it is such a common typo on pypi/conda-forge.
I think:
- If we were to rename
cylc-flowback tocylc(lots of work, no gain) then (3). - Otherwise (2)
Proposal
Ok, enough background, the actual proposal is quite simple:
-
Consistency
Make Cylc projects depend on minor releases of
cylc-flow.Examples:
cylc-uiserver==1.1.0might depend oncylc-flow=8.0.*NOTcylc-flow>=8.0.0.cylc-rose==1.1.1might depend oncylc-flow>=8.0.1,<8.1NOTcylc-flow>=8.0.0.
This means all [core] Cylc packages would have to be released for every minor release of
cylc-flow.I think this is probably the sort of direction we were heading in anyway. We could potentially relax this later on (to the major version) if interfaces settle down.
-
Namespace
Go for option (2), we don't need a special meta-package, try to make the existing
cylcpackages "dead-ends". -
WIP
Close:
Thoughts @cylc/core?