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
fix Lmod spider output in generated modules #1583
Conversation
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2606/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2607/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2608/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
@@ -244,7 +244,7 @@ def get_description(self, conflict=True): | |||
'name': self.app.name, | |||
'version': self.app.version, | |||
'description': description, | |||
'whatis_lines': '\n'.join(["module-whatis {%s}" % line for line in whatis]), | |||
'whatis_lines': '\n'.join(["module-whatis { Description: %s}" % line for line in whatis]), |
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.
why the whitespace before Description
?
Great catch @pescobar ! lgtm |
retest this please |
@wpoely86 I was discussing this with @geimer by email (he changed this code) and this fix is not the right one whatis section now can have different lines like this:
with this patch if you add multiple whatis lines each of them would have a We need to look for a better solution. I am really interested in getting proper spider output for next easybuild release |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2643/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
@pescobar yeah, I was just looking into the source of spider to see how it works. We should definitely chance this. Do you have time to do this properly? |
we must fist agree about which is a proper solution. It's not clear to me. I also asked @boegel but I think he doesn't have a clear opinion about this neither. |
Okay, we should generate a whatis section like: module-whatis "Name: Globus-4.0"
module-whatis "Version: CTSSV 4"
module-whatis "Category: grid"
module-whatis "URL: http://software.teragrid.org/install.htm"
module-whatis "Description: Defines the TeraGrid Globus 4.0 User Environment" We already know the name, version, url and description. For category we can use the moduleclass (maybe optional?)
We should merge the contents of it with the default generate one (meaning, append&overwrite). |
@wpoely86: We should give users the freedom to customize the contents of To me, the culprit is that Lmod relies on a specific formatting of @rtmclay: Any thoughts on this? |
@geimer First, does What you suggest it as site customizing of everything? I don't think we can do that? I think we should do the following:
And it Tmod has issues with multiple lines, we can make sure that description is always the last one. Or just add a config option to merge all However, that the users gets to see when the run |
I agree with @wpoely86 that we can probably do a better job by default. But if a @pescobar: I think what you're after is just adding |
@rtmclay, it is normal that spider doesn't show all
And
The URL field is not shown? |
We've hit also this issue. I understand we may want to provide more customization but we shouldn't do it if this breaks backwards compatibility. |
From the looks of it, this now restores the previous behaviour of having So, looks good to me, let's see if Jenkins agrees... @geimer: your thoughts? |
@@ -210,7 +210,7 @@ def get_description(self, conflict=True): | |||
""" | |||
Generate a description. | |||
""" | |||
description = "%s - Homepage: %s" % (self.app.cfg['description'], self.app.cfg['homepage']) | |||
description = "Description: %s - Homepage: %s" % (self.app.cfg['description'], self.app.cfg['homepage']) | |||
|
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.
Why not introduce the 'Description: ' prefix only for the whatis
text (i.e., 3 lines below)? For the module help
output it should be pretty clear that this is a description...
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.
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2747/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
@boegel: I still believe that the real issue is outside of EasyBuild. But I doubt that there will be a different short-term solution -- and maybe not even a long-term one... |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2748/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2749/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2750/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
"module-whatis {foo}", | ||
"module-whatis {bar}", | ||
"module-whatis {Description: foo}", | ||
"module-whatis {Description: bar}", |
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.
the Description:
part is not there is whatis
is specified, so change this back to what it was
EasyBuild framework unit test suite FAILed. See https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2751/console for more details. Please fix the reported issues by pushing additional commits to the branch corresponding with this pull request; contact @boegel if you're not sure what to do. |
EasyBuild framework unit test suite PASSed (see https://jenkins1.ugent.be/job/easybuild-framework-pr-builder/2752/console for more details). This pull request is now ready for review/testing. Please try and find someone who can tackle this; contact @boegel if you're not sure what to do. |
Looks good to go to me... Any last words @geimer? |
@boegel: Looks OK. It's amazing that 6 modified lines required 10 commits ;-) |
Going in, thanks for tackling this @pescobar! |
fix Lmod spider output in generated modules
No description provided.