-
Notifications
You must be signed in to change notification settings - Fork 94
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
Remove cylc.profiling package and cylc-profile-battery #3006
Conversation
First executed
And after the change it works too after removing my
Then I did the following test.
The experiment is executed successfully, and the
|
Added a couple To remove these Travis-CI passed in my fork, but I had to kick it three times. Will kick it here too during the day if required 👍 |
@kinow - I haven't looked at your code yet, but for use with installed versions (not git clones) we should probably assume our recommended side-by-side installation structure (e.g. |
Or (sorry - not thinking!) are we expecting use of |
I think this is a requirement for |
When users install So users will now be required to clone the repository somewhere, in order to use this tool. Not sure if the best approach, but at least this way |
Makes sense; let's see what @oliver-sanders thinks. |
Yes. The purpose of the |
I can imagine that site admins who install Cylc in critical production environments might want to check that performance has not degraded with the next release (possibly with a local suite). We don't have to support that, of course (and maybe we shouldn't) ... but I imagine it would be even easier to compare to installed releases than two git versions checked out on the fly. |
If we don't want to support that, can we have |
Maybe we could promote it to a top level project? Site admins could then manage where to install that, how to use, etc. |
I quite like that idea. |
Ditto! Though we would need to be slightly careful not to break it. The |
So what about this plan of action?
|
And I really liked the code of the profile battery. But if you think it could be improved, then I really want to see the new design and play with it! I suspect having it in its own repository will make it actually easier to re-write it. |
@kinow 's plan of action looks good to me. I'll defer to @oliver-sanders as the code owner though. (And perhaps @oliver-sanders can also check that his UK colleagues don't object). |
Possible alternative:
We've already deleted |
Oh, that would be even easier! If others are OK with that too, I will update (or close an raise a new one) the pull request. Cheers! |
@kinow please go ahead. |
7667d90
to
eb7ab88
Compare
Pull request update to now remove the cylc.profiling package, the cylc-profile-battery, and update documentation. All tests passing, and my ol' suite number five ran without issues locally. Ready for review again. Cheers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Now rather easy to review!)
This is now in conflict now that the typos branch is merged. |
…and update documentation
eb7ab88
to
a3395e9
Compare
Thanks @matthewrmshin ! I avoided touching Conflict undone! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the profiling suites should stay with the profile battery. In fact I think all the dev suites are performance examples so we could probably move them all?
Oh, I had no idea. Just pushed another commit that removes |
I just spotted there are some |
|
Just wondering about the logic of moving profiling to a new repository vs leaving the test battery in the main repository. I guess that makes sense because the test battery is to check that the current source version passes all tests, but the profiler compares two arbitrary cylc versions - i.e. it is not inherently tied to the current source version. |
In principle the test battery could also be used in a release, after installation, to check that everything works. Any other developer-specific files - these days just a few files under |
Good point @hjoliver , I hadn't considered the test-battery. I think it makes sense to move the profile-battery as it can be maintained as a separate project, with its own release cycle, bugs/issues/pull requests/features. And the profile-battery should not change if we change Cylc's internal API. So there is a more clear separation between Cylc and profile-battery. It could be possible that it would still work for Cylc 9 or Cylc 10, maybe with some minor adjustments. But the test-battery relies in some parts on API in Cylc that is not exposed to public. Some tests verify - as far as I could tell - if parsing is working, task pool state, messages, etc. So this one is much more tangled with Cylc. Changing features in Cylc require changing test-battery some times. But not the profile-battery I think (maybe create a new experiment?). |
Yes, that's right. So we're doing the right thing - profiler out, test battery in. |
Done in 8f2b749! 🎉 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well this is a nice easy review. Excellent code style, every line added is beautiful.
For #2991 (once this one gets merged, will test and close #2991 if no other command failed in my Anaconda environment).
The
cylc-profile-battery
command tries to locate the directory ofcylc
script, and locate the base Cylc installation directory. Then it fails if that directory is not a Git repository (i.e. does not have a.git
folder).This causes issues when running the tests with Cylc being installed via
pip
under a virtual environment in Anaconda.In #2997 we changed the way the Cylc version is located, so that there is no more need to have a git directory. And now in this pull request we are using that approach instead of using thegit
command line.And instead of trying to locate the Cylc directory, the script will default to the old behaviour of assuming.
is a Cylc installation of.git
, but also accept an optional parameter that defines where is the Cylc directory we would like to use in the experiments.As per discussion (see comments below) this PR removes the
cylc.profiling
package, thecylc-profile'-battery
and updates the documentation.