Skip to content

Commit a3f0f81

Browse files
committed
Fix ExtensionEasyBlock.make_module_extra
1 parent 5f71430 commit a3f0f81

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

easybuild/framework/extensioneasyblock.py

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -214,10 +214,18 @@ def sanity_check_step(self, exts_filter=None, custom_paths=None, custom_commands
214214

215215
return (sanity_check_ok, '; '.join(self.sanity_check_fail_msgs))
216216

217-
def make_module_extra(self, extra=None):
217+
def make_module_extra(self, *args, **kwargs):
218218
"""Add custom entries to module."""
219219

220-
txt = EasyBlock.make_module_extra(self)
220+
# The signature used to be make_module_extra(self, extra) which was wrong but supported
221+
extra = kwargs.pop('extra', None)
222+
if extra is None and len(args) == 1:
223+
extra = args[0]
224+
args = ()
225+
if extra is not None:
226+
self.log.deprecated("Passing the parameter 'extra' to make_module_extra should be "
227+
"replaced by concatenating the result", '6.0')
228+
txt = super().make_module_extra(*args, **kwargs)
221229
if extra is not None:
222230
txt += extra
223231
return txt

0 commit comments

Comments
 (0)