0

I'm running a python script that exports xml from a database, converts the record to PDF, then attempts to upload both the xml and pdf files to a github repository. The export and pdf conversion work fine, but the process then hangs and outputs the following error message:

Traceback (most recent call last):
File "asExportIncremental.py", line 394, in <module>
main()
File "asExportIncremental.py", line 320, in main
gitPush()
File "asExportIncremental.py", line 308, in gitPush
repo.push()
File "C:\Python27\lib\site-packages\gittle\gittle.py", line 343, in push
return self.push_to(origin_uri, branch_name, progress)
File "C:\Python27\lib\site-packages\gittle\gittle.py", line 338, in push_to
progress=progress
File "C:\Python27\lib\site-packages\dulwich\client.py", line 440, in send_pack
proto, unused_can_read = self._connect('receive-pack', path)
File "C:\Python27\lib\site-packages\dulwich\client.py", line 893, in _connect
port=self.port, username=self.username)
File "C:\Python27\lib\site-packages\dulwich\client.py", line 758, in run_command
stdout=subprocess.PIPE)
File "C:\Python27\lib\subprocess.py", line 390, in __init__
errread, errwrite)
File "C:\Python27\lib\subprocess.py", line 640, in _execute_child
startupinfo)
WindowsError: [Error 2] The system cannot find the file specified

My problem is that I'm not exactly sure where the script is failing. To which file is "WindowsError: [Error 2] The system cannot find the file specified" referring? How do I fix it? Thanks!

2
  • Probably gittle is a git wrapper, and it tries to call it, but it's unable to find it? Commented Jan 16, 2018 at 17:28
  • Use print statements in your script to print out paths of files/scripts you are using in your code to debug the issue. Commented Jan 16, 2018 at 18:26

1 Answer 1

1

The script calls gittle (high-level python git library) which executes dulwich (low-level python git wrapper) which runs ssh and fails. It seems ssh.exe is not in your PATH.

Sign up to request clarification or add additional context in comments.

1 Comment

This was it! Thank you!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.