Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FileNotFoundError: [Errno 2] No such file or directory: 'mysqldump': 'mysqldump' #27

Open
azin634 opened this issue Jan 23, 2020 · 0 comments

Comments

@azin634
Copy link
Contributor

azin634 commented Jan 23, 2020

Using OSX

Empty dict is being passed into the env args for subprocess.Popen. This causes the command to not be able to find mysqldump. env is being initialized as empty dict here

(venv) edwin$ database-sanitizer mysql://root@localhost/test
Traceback (most recent call last):
  File "/Users/edwin/code/test/venv/bin/database-sanitizer", line 11, in <module>
    sys.exit(main())
  File "/Users/edwin/code/test/venv/lib/python3.6/site-packages/database_sanitizer/__main__.py", line 60, in main
    config=config,
  File "/Users/edwin/code/test/venv/lib/python3.6/site-packages/database_sanitizer/dump/__init__.py", line 46, in run
    for line in db_module.sanitize(url=parsed_url, config=config):
  File "/Users/edwin/code/test/venv/lib/python3.6/site-packages/database_sanitizer/dump/mysql.py", line 68, in sanitize
    stdout=subprocess.PIPE,
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/subprocess.py", line 729, in __init__
    restore_signals, start_new_session)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/subprocess.py", line 1364, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'mysqldump': 'mysqldump'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant