You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While trying to restore with --srcTable "*" I ran into
INFO:root:Starting restore for .gitkeep to .gitkeep..Exception in thread Thread-4 (do_restore):Traceback (most recent call last): File "/usr/local/lib/python3.12/threading.py", line 1073, in _bootstrap_inner self.run() File "/usr/local/lib/python3.12/threading.py", line 1010, in run self._target(*self._args, **self._kwargs) File "/usr/local/bin/dynamodump", line 866, in do_restore open(dump_data_path + os.sep + source_table + os.sep + SCHEMA_FILE)NotADirectoryError: [Errno 20] Not a directory: '/dump/.gitkeep/schema.json'
It would be nice if only directories were considered when looping over the matching content in the dump path.
IIUC, a simple
ifos.is_dir(dir_name):
continue
after line 379 in dynamodump.py should do the trick.
In my case I want to add an empty "scratch" directory to git, hence the .gitkeep file, but I can image that people want to put a README.md or similar in the dump path for documentation purposes.
The text was updated successfully, but these errors were encountered:
Anyway, after testing a bit at the Python REPL, I cooked up something that should work. My Python skills are next to non-existent so I didn't even try to add a test to the code.
While trying to restore with
--srcTable "*"
I ran intoIt would be nice if only directories were considered when looping over the matching content in the dump path.
IIUC, a simple
after line 379 in
dynamodump.py
should do the trick.In my case I want to add an empty "scratch" directory to
git
, hence the.gitkeep
file, but I can image that people want to put aREADME.md
or similar in the dump path for documentation purposes.The text was updated successfully, but these errors were encountered: