I've got an exception when I reopen a database and write inside it:
Traceback (most recent call last):
File "app.py", line 11, in <module>
t.insert({'xuid': uuid.uuid4().hex, 'name': ''})
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 103, in insert
row = self._sync_columns(row, ensure, types=types)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 376, in _sync_columns
name = self._get_column_name(name)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 83, in _get_column_name
return self._column_keys.get(key, name)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 64, in _column_keys
if key in self._columns:
TypeError: argument of type 'NoneType' is not iterable
$ docker build -t test .
Successfully tagged test:latest
$ sudo rm -rf db
$ docker run -v $(pwd)/db:/db -it test
$ docker run -v $(pwd)/db:/db -it test
Traceback (most recent call last):
File "app.py", line 11, in <module>
t.insert({'xuid': uuid.uuid4().hex, 'name': ''})
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 103, in insert
row = self._sync_columns(row, ensure, types=types)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 376, in _sync_columns
name = self._get_column_name(name)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 83, in _get_column_name
return self._column_keys.get(key, name)
File "/usr/local/lib/python3.8/site-packages/dataset/table.py", line 64, in _column_keys
if key in self._columns:
TypeError: argument of type 'NoneType' is not iterable
This is a regression of version 1.2.1. It works with version 1.2.0
Hi,
I've got an exception when I reopen a database and write inside it:
The example code is here: https://github.com/Frankkkkk/dataset-exception-example
And you can raise the exception like so:
This is a regression of version 1.2.1. It works with version 1.2.0
I'll try to make a patch if I've got time.
Cheers