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

Don't show stacktrace when using Ctrl-C #39

Closed
fedekau opened this issue Jun 17, 2017 · 0 comments
Closed

Don't show stacktrace when using Ctrl-C #39

fedekau opened this issue Jun 17, 2017 · 0 comments

Comments

@fedekau
Copy link
Contributor

fedekau commented Jun 17, 2017

If you run whereami predict and before is has finished you press Ctrl+C to kill the execution you get a Python stacktrace.

$ whereami predict
^CTraceback (most recent call last):
  File "/Users/user/anaconda3/bin/whereami", line 11, in <module>
    sys.exit(main())
  File "/Users/user/anaconda3/lib/python3.5/site-packages/whereami/__main__.py", line 77, in main
    print(predict(args.input_path, args.model_path, args.device))
  File "/Users/user/anaconda3/lib/python3.5/site-packages/whereami/predict.py", line 17, in predict
    data_sample = sample(device) if input_path is None else get_external_sample(input_path)
  File "/Users/user/anaconda3/lib/python3.5/site-packages/whereami/get_data.py", line 15, in sample
    aps = wifi_scanner.get_access_points()
  File "/Users/user/anaconda3/lib/python3.5/site-packages/access_points/__init__.py", line 79, in get_access_points
    out = self.call_subprocess(self.cmd)
  File "/Users/user/anaconda3/lib/python3.5/site-packages/access_points/__init__.py", line 86, in call_subprocess
    (out, _) = proc.communicate()
  File "/Users/user/anaconda3/lib/python3.5/subprocess.py", line 1059, in communicate
    stdout = self.stdout.read()
KeyboardInterrupt```
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