From 08bbb2533677296ab0af0573f6d5ed59f9117c52 Mon Sep 17 00:00:00 2001 From: Gabriel Studer <gabriel.studer@stud.unibas.ch> Date: Tue, 25 Jun 2013 14:23:58 +0200 Subject: [PATCH] Make sure to initialize a NEW list of col_names at table initialization This avoids funny artefacts on tab_old if you create a new table tab_new in the following way and try to add new columns there: tab_new = Table(tab_old.col_names, tab_new.col_types) --- modules/base/pymod/table.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/base/pymod/table.py b/modules/base/pymod/table.py index 8198b4041..c4031d010 100644 --- a/modules/base/pymod/table.py +++ b/modules/base/pymod/table.py @@ -219,7 +219,7 @@ class Table(object): def __init__(self, col_names=None, col_types=None, **kwargs): - self.col_names=col_names + self.col_names=list(col_names) self.comment='' self.name='' -- GitLab