-
Notifications
You must be signed in to change notification settings - Fork 191
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 the nested list bug that makes email not be delivered #3081
base: dev
Are you sure you want to change the base?
Conversation
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 don't know what the specific intention was with this code so I can't provide a proper review, however I don't think this fix will be accepted in the current state: some pipelines can produce multiple MultiQC files, so I don't think sending the 'first one' is the right behaviour here.
I think it would make more sense that if multiqc_report.toList().size > 1
then zip up all the multiQC files and send that instead... or some similar strategy.
Unfortuntately I have a pressing deadline so I am unable to explore this futher... but maybe someone from @nf-core/infrastructure or @nf-core/maintainers could tackle this?
@jfy133 Its intention is to fix the failure of mailing function. The
In addition, I agree with that the best way is to zip up all the multiQC reports together and send that instead. But current code in the template workflow only uses the first one. |
Sorry @HaidYi , by the intention I meant the original code not your fix (which I understand the logic!) :) |
@jfy133 Okay, I understand what you mean. But could you test that if the original code in the |
Currently not myself as I'm currently part time and have other deadlines. But maybe someone from @nf-core/infrastructure or @nf-core/maintainers could check this for you? |
Sure, that sounds good to me. |
I saw on slack that @mirpedrol was investigating 👍 |
@mirpedrol did you make any progress? Or do we need to wait for Phil? |
No, sorry. I couldn't find anyone able to test email sending |
I guess we will need @ewels when he's back... I've not used the email system for a long time now either... |
I no longer have access to the system that I used when developing it (which had the email services set up). @mashehu does though (UPPMAX). Maybe @MatthiasZepper might be interested as well? |
What exactly would you want to test here? And wouldn't Mailcatcher suffice to test that functionality? It is also available as a separate Docker container. |
Fix the bug of nested list for generating the reports. Before calling the function
PIPELINE_COMPLETION
inmain.nf
, thepipeline.nf
emit themultiqc_report
as a list (see below):tools/nf_core/pipeline-template/workflows/pipeline.nf
Lines 89 to 91 in 930ece5
But in the
utils_nfcore_pipeline_pipeline
, theworkflow.onComplete
function, the report is double listed:tools/nf_core/pipeline-template/subworkflows/local/utils_nfcore_pipeline_pipeline/main.nf
Line 137 in 930ece5
This nested list make the
groovy.text.GStringTemplateEngine
cannot correctly render the HTML to send the email (The resulting HTML string is empty):tools/nf_core/pipeline-template/subworkflows/nf-core/utils_nfcore_pipeline/main.nf
Lines 343 to 344 in 930ece5
So, here remove one
toList()
call to make email back to work. I also test this change and find the email function back to work well after this change.PR checklist
CHANGELOG.md
is updateddocs
is updated