-
Notifications
You must be signed in to change notification settings - Fork 3
Description
I have an UUID field in the models which is generated by postgres UUID extension. Is there any mechanism to skip adding the value for this field in the json file? Error I am facing -
File "/Users/kshitij/enable/workspace/security/data/seed1.py", line 18, in
seeder.load_entities_from_json_string(json_string=data, commit=True, separate_by_class=True)
File "/Users/kshitij/enable/workspace/security/.venv/lib/python3.11/site-packages/sqlalchemyseeder/resolving_seeder.py", line 160, in load_entities_from_json_string
return self.load_entities_from_data_dict(data, separate_by_class, flush_on_create, commit)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kshitij/enable/workspace/security/.venv/lib/python3.11/site-packages/sqlalchemyseeder/resolving_seeder.py", line 203, in load_entities_from_data_dict
generated_entities = resolver.generate_entities(seed_data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kshitij/enable/workspace/security/.venv/lib/python3.11/site-packages/sqlalchemyseeder/resolving_seeder.py", line 238, in generate_entities
return self._resolve_builders(entity_builders)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kshitij/enable/workspace/security/.venv/lib/python3.11/site-packages/sqlalchemyseeder/resolving_seeder.py", line 260, in _resolve_builders
entity = resolved_builder.build()
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kshitij/enable/workspace/security/.venv/lib/python3.11/site-packages/sqlalchemyseeder/resolving_seeder.py", line 308, in build
return self.target_cls(**self.data_dict)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: init() missing 1 required positional argument: 'id'