Skip to content

Resetting evaluation interpreter variable whose value is an invalid list #570

Description

@xdelaruelle

In case a variable is pre-set within modulefile or modulerc evaluation interpreter and the value of this variable is an invalid list:

$ cat /etc/environment-modules/siteconfig.tcl
set modulefile_extra_vars [list myvar {"foo"; "bar"}]

If such variable is changed by a modulefile or a modulerc evaluated:

$ cat /path/to/modulefiles/foo/1
#%Module
set myvar value

An error occurs when resetting this interpreter variable between several evaluation:

$ module load foo/1 bar/1
ERROR: list element in quotes followed by ";" instead of space
      while executing
  "llength $dumpVars($var)"
      (procedure "resetInterpState" line 52)
      invoked from within 
  "resetInterpState $itrp $fresh g_modrcVars g_modrcArrayVars g_modrcUntrackVars g_modrcProcs g_modrcAliases g_modrcAliasesPassArg g_modrcAliasesTraces g..."
      (procedure "execute-modulerc" line 80)
      invoked from within
  "execute-modulerc $dir/$elt $elt $elt"
      (procedure "getModules" line 101)
      invoked from within 
  "getModules $dir $mod 0 [list rc_defs_included resolve]"
      (procedure "getPathToModule" line 49)
      invoked from within
  "getPathToModule $mod $modulepath_list $notfounderr"
      (procedure "cmdModuleLoad" line 30)
      invoked from within
  "cmdModuleLoad load 1 $tryload $loadany $tag_list {} {*}$args"
      (procedure "cmdModuleIntLoad" line 17)
      invoked from within
  "$cmdprocname {*}$cmdopts {*}$parsed_args"
      (procedure "module" line 186)
      invoked from within
  "{*}$execcmdlist"
  Please report this issue at https://github.com/envmodules/modules/issues

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions