-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cylc Tutorial Suite #40
Comments
I'd be +1 for "Cylc Tutorial", and +0 for "Cylc Flow". I think we used to have some commands in cylc-flow to load examples before (?), so it wouldn't be a surprise to users to have that command in "Cylc Flow". But I think with I agree on the too many repos, but there is a good think about it, that Cylc Flow (the core of Cylc?) is not affected by bugs/changes in commands such as |
Sadly it also means that the sub-repos are not affected by fixes / changes in the Cylc Flow repo e.g. #3191 which would require changes to:
|
Hmmm, the right answer is not clear to me at this stage 🤔 |
Considerations:
Packaging Approaches:
@cylc/core I don't think there is a right answer here, just a whole bunch of wrong ones. For context: I think the desire was to put the built does up on NPM as a bunch of static resources (as there is no real use case for |
If the tutorial did not contain any commands (to copy resources to the user's space) then separate repo OR cylc-doc (probably the latter?) would be the obvious right answer, because we could just publish the tutorial online - right? So why not dispense with the command-to-extract-tutorial-suites bit (as we did for |
For now sounds like the simplest solution. And we could revisit it later. |
I also think Hilary's suggestion above is the way to go. For context, I suspect an core reason for Oliver wanting to keep the copying command in some form for is the internal training we hold, where it provides an effectively instant way for trainees to get the tutorial suites on their homespace where they can edit them for the practicals, & we can be sure they they are there in the exact form as provided, i.e. there has not been say a copy-n-paste error or that the wrong suite has been copied, or the established directory structure is not quite right, etc. Saves on debugging cases to investigate in the practical sessions if a trainee sees something that isn't in line with the expected result. But with Hilary's suggestion (or otherwise), if we still wanted a direct command-line method for the training, rather than a download, we could always copy & these to a local location before the training (validating that they work or checking the diffs from known working versions), & then reference & write down on the board commands for which the trainees can directly copy from (e.g. |
I don't think dispensing of the tutorial command would be easy, for instance look at the way it is used in this tutorial, users perceptibly run the command to cherry-pick resources for their application: However, registering a new Cylc command is pretty trivial right? |
Not great having an internet dependency e.g. for tutorials delivered at conferences etc. |
😱 No Internet connection!? |
Even @MartinRyan's friendly host institution was willing to give us some wicked dial-up-modem equiv-tech 🐎 https://www.youtube.com/watch?v=gsNaR6FRuO0 |
@oliver-sanders - you make a good point, if it would be painful to amend the tutorial for online access. On the other hand, its not just about removing commands. There's also nowhere (or nowhere appropriate) to put significant amounts of non-Python resources in a Python package. We removed the old Cylc example suites (and more) in part because |
However we do still install minimal resources ( |
Or just assume that any IT training facilities in the 2020s will have good Internet connection? |
Good luck with that! |
OK, we've got something of a consensus, here's my proposal.
|
We removed a few subcommands like So IMO this could live in cylc-doc, or available in another external repo and be available only if the user installed it - requires finishing cylc/cylc-flow#3413 This would allow users to install it only if they want to have the command (probably you don't need/want the tutorial files in a production/high-security/etc environment), and if they accept to also have the +1 to all other points |
Wouldn't be the tutorial files, only the command to retrieve them (some extra logic for |
I've been thinking about this a bit.
It would be quite simple to modify the
My take on options:
In the latter case there are a set of possible implementations:
If we choose any of the separate locations there is nothing to stop using using GH actions to test that repo in cylc-doc |
I don't like this proliferation of repos but my proposal is:
Putting it in Cylc flow is my other front-runner option. |
I've had a bit more of a think about this and realise that want to write out fuller proposals for each option:
|
Proposal 2 (cylc-flow/github-actions-copy/github-actions-edit-setup.cfg)
Possible refinements
For
Against
|
Proposal 3
For
Against
|
This decision seems to have gotten crazy complicated 🤯 Here's my opinion: Tutorial code and tutorial text and file copy command[+] should be in a separate cylc-tutorials repository
So, I think a separate repository is the right thing to do. We just have to deal with a few consequences of that.
[+] file copy command - is that really so important? Users could just download a tutorial project realease tarball, unpack it, and use or copy the source directories therein. Or in a training context, the teacher can download it in advance, and tell users where to copy the local files from, or provide a command to allow selective copying if that's really needed. |
(I would say putting tutorial workflow defs in cylc-flow's etc/ is somewhat tempting, but not if we have to put all the tutorial text there too ... and its super important for the tutorial text to match the tutorial code - those two thing really have to live together ... and if so, we've got the same problem with user guide integration as for a seperate cylc-tutorials repo). |
Note to self: The Datapoint API keys should also be fished out of Rose. |
I'm happy to attempt to implement @hjoliver 's suggestion, but I'd quite like @oliver-sanders and to have a quick look: To my mind it answers a lot of questions. |
@hjoliver If we make cylc-tutorials a new repo, what do we do about the requirement to install Possible solutions:
I think that I prefer the latter. |
Looks to me like the simplest option by far is:
No reason not to, we would only be copying the tutorials into cylc-flow from another location anyway. From the cons above:
So no road blocks there. The only real issue being that the tutorial would become an optional dependency of cylc-flow (unless we say stuff it, lets make it compulsory) meaning that we would need to issue reminders to install the tutorial dependencies.
|
If tutorial workflows have software dependencies then users should have to use conda or pip. In principle, tutorial workflows could do things that have absolutely nothing to do with the cylc-flow codebase, so I don't think tutorial-specific dependencies should be rammed into cylc-flow. Having to use pip or conda to install tutorials is no big deal.
|
I fail to see how that's simpler than having a separate tutorial repository.
I gave some good reasons not to, above, which you haven't countered.
Why would we need to copy the tutorials into cylc-flow? |
How else are we going to distribute the tutorials. Are we going to create yet another pypi & conda-forge project for the tutorials. That's a lot of extra work for a project which will have exactly the same release cycle as cylc-flow. Any good reason not to bundle these static files with cylc-flow as we do for rose (and used to do for old Cylc).
If we have a separate repo we have the additional overhead of the new repo, combined with the overhead of deploying that repo, whether via git submodules, pypi/conda-forge or GH actions this is an additional process we have to establish and maintain. But in the end the practical end result is no different than if we just use the mechanism we already have.
The tutorial workflow files do not apply to uiserver / ui so are cylc-flow specific. I think we have split this project into too many repos as it is, this causes us some needless pain. The current trend is for monorepos. Personally, I think the docs should really live in cylc-flow. They are released in lock-step with cylc-flow & carry the cylc-flow version, they are the cylc-flow docs with a couple of documented plugins.
Yep, so make them optional dependencies?
So they shouldn't go in a new repo then! |
We don't need to distribute them, we just need to publish them and tell users where to get them. As an example, there are official git tutorials, but they don't get installed with the git application (and it would be perverse if they did!).
Ah, really? https://cylc.github.io/cylc-doc/8.0b3/html/tutorial/runtime/introduction.html#the-cylc-gui
I didn't say the tutorial workflow defs should be a in new repo all by themselves. I suggested the tutorial docs and the tutorial workflow defs (and tests to check that they run correctly) should be in the same repo together, because:
Options for "in the same repo together" are:
|
Yes, really, the tutorial suite is purely cylc-flow, the tutorial docs cover multiple components.
In which case Git is "perverse", my version has 16 tutorials pre-installed:
|
Hang on, from the start of this discussion I've been talking about "the tutorials" - not just the workflow definitions.
God damn it, you got me there. 🤯 |
Na, just the workflows. |
Hehe, I know you're talking about just the workflow defs, but I wasn't sure if you realized I was talking about the workflow defs and the tutorials that use them. |
Ideally the two would be together in the same repo, however, it's not that big a deal if we split them. There are no right options here, just a list of compromises, this one isn't much inconvenience. |
Decision: Put the workflows in Cylc-Flow. |
Follow-on from #38.
Find a new home for the Cylc Tutorial suite.
There are some issues to be migrated to wherever the Cylc Tutorial lands:
The Cylc Tutorial makes use of the
rose tutorial
command which is basically just a glorifiedrsync
which copies resources from$ROSE_HOME/etc/tutorial
to$HOME/cylc-run
for the user to work on.The tutorial suite contains:
We will need to replace the
rose tutorial
command. The question is where to put it. Options:extra_requires
)The text was updated successfully, but these errors were encountered: