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

Interrupt could be nicer #5

Closed
Sjors opened this issue Dec 15, 2023 · 2 comments
Closed

Interrupt could be nicer #5

Sjors opened this issue Dec 15, 2023 · 2 comments

Comments

@Sjors
Copy link

Sjors commented Dec 15, 2023

I did a ctrl+c during the "Validating RPKI" phase. The output looks a bit noisy and it also didn't stop, at least not before I gave up waiting after two minutes and ctrl + c again, which responded quickly.

$ ./run map -w 1702648800

--- Start Kartograf ---

Using rpki-client version 8.5.
Coordinated launch mode: Waiting until 1702648800 (2023-12-15 15:00:00 CET) to launch mapping process.
The epoch for this run is: 1702648800 (2023-12-15 14:00:00 UTC, local: 2023-12-15 15:00:00 CET)

--- Fetching RPKI ---

Downloading RPKI Data
...finished in 0:01:16.535906

--- Validating RPKI ---

Validating RPKI ROAs
^CTraceback (most recent call last):
  File "/home/sjors/dev/kartograf/./run", line 92, in <module>
    Kartograf.map(args)
  File "/home/sjors/dev/kartograf/kartograf/kartograf.py", line 68, in map
    validate_rpki_db(context)
  File "/home/sjors/dev/kartograf/kartograf/timed.py", line 10, in wrapper
    result = func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^
  File "/home/sjors/dev/kartograf/kartograf/rpki/fetch.py", line 38, in validate_rpki_db
    with ThreadPoolExecutor() as executor:
  File "/home/sjors/.pyenv/versions/3.11.7/lib/python3.11/concurrent/futures/_base.py", line 647, in __exit__
    self.shutdown(wait=True)
  File "/home/sjors/.pyenv/versions/3.11.7/lib/python3.11/concurrent/futures/thread.py", line 235, in shutdown
    t.join()
  File "/home/sjors/.pyenv/versions/3.11.7/lib/python3.11/threading.py", line 1119, in join
    self._wait_for_tstate_lock()
  File "/home/sjors/.pyenv/versions/3.11.7/lib/python3.11/threading.py", line 1139, in _wait_for_tstate_lock
    if lock.acquire(block, timeout):
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
KeyboardInterrupt
@Sjors
Copy link
Author

Sjors commented Dec 15, 2023

If the user does a ctrl + c, you could optionally ask if they want to delete the relevant out directory.

@fjahr
Copy link
Collaborator

fjahr commented Dec 18, 2023

Hey @Sjors , thanks a lot for that note, I am moving this over to the kartograf repository where I have opened a thread for future todos, so we can coordinate priorities: asmap/kartograf#11 Also happy to hear your thoughts on the other todos mentioned there, if you have anything to add :)

@fjahr fjahr closed this as completed Dec 18, 2023
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

2 participants