Every line of 'command exited with non-zero status 1' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your Python code is secure.
463 def WEXITSTATUS(status): 464 return 1
Secure your code as it's written. Use Snyk Code to scan source code in minutes – no build needed – and fix issues immediately. Enable Snyk Code
288 def test_code_exits(self): 289 self.make_file("exit.py", """\ 290 import sys 291 def f1(): 292 print("about to exit..") 293 sys.exit(17) 294 295 def f2(): 296 f1() 297 298 f2() 299 """) 300 301 # The important thing is for "coverage run" and "python" to have the 302 # same output. No traceback. 303 status, out = self.run_command_status("coverage run exit.py") 304 status2, out2 = self.run_command_status("python exit.py") 305 self.assertMultiLineEqual(out, out2) 306 self.assertMultiLineEqual(out, "about to exit..\n") 307 self.assertEqual(status, status2) 308 self.assertEqual(status, 17)
176 def exit_status(self): 177 return self._proc.exitStatus()
31 def status(self): 32 self._status
467 def WIFEXITED(status): 468 return 1
1152 def _handle_exitstatus(self, sts): 1153 if os.WIFSIGNALED(sts): 1154 self.returncode = -os.WTERMSIG(sts) 1155 elif os.WIFEXITED(sts): 1156 self.returncode = os.WEXITSTATUS(sts) 1157 else: 1158 # Should never happen 1159 raise RuntimeError("Unknown child exit status!")