We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
CTRL+C doesn't terminate sessions on Windows. I tested on both Linux and Windows and confirmed only Windows was affected.
CTRL+C to terminate the session on Windows.
CTRL+C doesn't terminate session on Windows. I
On windows, with the following template:
specificationVersion: jobtemplate-2023-09 name: Python script steps: - name: Run script: actions: onRun: command: python args: ['{{Task.File.sleep}}'] embeddedFiles: - name: sleep type: TEXT filename: sleep.py data: | import time for i in range(10): print(f"Waiting {i}", flush=True) time.sleep(1) print("Exiting script.")
Run
openjd run template.yaml --step Run and then send CTRL+C.
openjd run template.yaml --step Run
CTRL+C
The program will fail to exit and only once the session is over you will see that it did attempt to cancel the session. Here are some logs:
(venvtemp) C:\tmp\venvtemp>openjd run template.yaml --step Run Wed Sep 11 15:39:15 2024 Wed Sep 11 15:39:15 2024 ============================================== Wed Sep 11 15:39:15 2024 --------- Running Task Wed Sep 11 15:39:15 2024 ============================================== Wed Sep 11 15:39:15 2024 ---------------------------------------------- Wed Sep 11 15:39:15 2024 Phase: Setup Wed Sep 11 15:39:15 2024 ---------------------------------------------- Wed Sep 11 15:39:15 2024 Writing embedded files for Task to disk. Wed Sep 11 15:39:15 2024 Mapping: Task.File.sleep -> C:\ProgramData\Amazon\OpenJD\sample_session4n3p_urq\embedded_files2uo2tdd_\sleep.py Wed Sep 11 15:39:15 2024 Wrote: sleep -> C:\ProgramData\Amazon\OpenJD\sample_session4n3p_urq\embedded_files2uo2tdd_\sleep.py Wed Sep 11 15:39:15 2024 ---------------------------------------------- Wed Sep 11 15:39:15 2024 Phase: Running action Wed Sep 11 15:39:15 2024 ---------------------------------------------- Wed Sep 11 15:39:15 2024 Running command powershell.exe -NonInteractive -File C:\ProgramData\Amazon\OpenJD\sample_session4n3p_urq\tmpz2wddzli.ps1 Wed Sep 11 15:39:15 2024 Command started as pid: 24984 Wed Sep 11 15:39:15 2024 Output: Wed Sep 11 15:39:17 2024 Waiting 0 Wed Sep 11 15:39:18 2024 Waiting 1 Wed Sep 11 15:39:19 2024 Waiting 2 Wed Sep 11 15:39:20 2024 Waiting 3 Wed Sep 11 15:39:21 2024 Waiting 4 Wed Sep 11 15:39:22 2024 Waiting 5 Wed Sep 11 15:39:23 2024 Waiting 6 Wed Sep 11 15:39:24 2024 Waiting 7 Wed Sep 11 15:39:25 2024 Waiting 8 Wed Sep 11 15:39:26 2024 Waiting 9 Wed Sep 11 15:39:27 2024 Exiting script. Wed Sep 11 15:39:27 2024 Interruption signal recieved. Wed Sep 11 15:39:27 2024 Open Job Description CLI: Cancelling the session... Wed Sep 11 15:39:27 2024 Open Job Description CLI: Session terminated by user while running action: 'Run Step 'Run' with Task parameters '{}''. Wed Sep 11 15:39:27 2024 Open Job Description CLI: ERROR executing action: 'Run Step 'Run' with Task parameters '{}'' (see Task logs for details) Wed Sep 11 15:39:27 2024 Open Job Description CLI: Local Session ended! Now cleaning up Session resources. --- Results of local session --- Session ended with errors; see Task logs for details Job: Python script Step: Run Duration: 11.469836800009944 seconds Tasks run: 1
At minimum:
python3 --version
pip show openjd-cli
0.4.0
0.4.4
I also tried changing the version of openjd-sessions down to 0.5.0 and the behavior was the same, so I don't believe this is recently introduced.
0.5.0
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug
CTRL+C doesn't terminate sessions on Windows. I tested on both Linux and Windows and confirmed only Windows was affected.
Expected Behaviour
CTRL+C to terminate the session on Windows.
Current Behaviour
CTRL+C doesn't terminate session on Windows. I
Reproduction Steps
On windows, with the following template:
Run
openjd run template.yaml --step Run
and then sendCTRL+C
.The program will fail to exit and only once the session is over you will see that it did attempt to cancel the session. Here are some logs:
Environment
At minimum:
python3 --version
: Python 3.9.13pip show openjd-cli
): Tested with0.4.0
and0.4.4
.I also tried changing the version of openjd-sessions down to
0.5.0
and the behavior was the same, so I don't believe this is recently introduced.The text was updated successfully, but these errors were encountered: