See also: learnweb/moodle-tool_lifecycle#255
local_envbar can't save envbar settings when tool_lifecycle is installed and local_envbar defines more than one (two?) environments.
When envbars are saved, the POST contains parameter "id" with array values. tool_lifecycle expects "id" to be PARAM_TEXT, which then crashes.
Yes, tool_lifecycle should probaby change what it does...
But you could be so nice as to change your parameter name from "id" to "envids" or something like it, avoiding the clash from your side.