Callable.local_variables()

return the local variables for the function/modifier.

local_variables() β†’ LocalVariables

Returns a LocalVariables object for the local variables of the function/modifier.

Example

from glider import *
def query():
  functions = Functions().exec(100)

  local_vars = []
  for function in functions:
    for local_var in function.local_variables().list():
      # Return the try instructions for each function
      local_vars.append({"name": local_var.name})

  return local_vars

Output

"root":{1 item
"name":string"c"
},
"root":{1 item
"name":string"msgSender"
}
...

Last updated