params = {} if params is None else params.copy() has solved the problem.
I have provided just a toy example here. Execute method actually takes dict[str, List]. List contains objects. Each object has two properties, so I have a logic that analyzes these properties and returns None or List as a dict[k] value. Now when I have dict prepared with proper key/values pairs, I am proceeding to execution of the jinjasql query. What I have to ensure is that I will get dic[str, List] (I could go further and ensure that list contains only object of certain class, by the way, how to do that?). Than I must ensure that I am working on local copy of parameters. Anyway, copy that Dieter Maurer suggested works as it should. Thanks. -- https://mail.python.org/mailman/listinfo/python-list