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

fix: Handle case where Deadline Cloud Submitter is opened from unsaved scene #26

Merged
merged 1 commit into from
Sep 21, 2023

Conversation

jlangmann-aws
Copy link
Contributor

What was the problem/requirement? (What/Why)

Opening up the Deadline Cloud Submitter from a blank script presented the following error:

Exception caught:
Traceback (most recent call last):
  File "/home/rocky/git/deadline-cloud/src/deadline/client/ui/__init__.py", line 38, in gui_error_handler
    yield
  File "/home/rocky/git/deadline-cloud-for-nuke/src/deadline/nuke_submitter/deadline_submitter_for_nuke.py", line 36, in show_nuke_render_submitter_noargs
    return show_nuke_render_submitter(mainwin)
  File "/home/rocky/git/deadline-cloud-for-nuke/src/deadline/nuke_submitter/deadline_submitter_for_nuke.py", line 188, in show_nuke_render_submitter
    render_settings.load_sticky_settings(get_nuke_script_file())
  File "/home/rocky/git/deadline-cloud-for-nuke/src/deadline/nuke_submitter/data_classes.py", line 38, in load_sticky_settings
    sticky_settings_filename = Path(scene_filename).with_suffix(
  File "/opt/nuke/Nuke14.0v5/lib/python3.9/pathlib.py", line 903, in with_suffix
    raise ValueError("%r has an empty name" % (self,))
ValueError: PosixPath('.') has an empty name

What was the solution? (How)

If the script name is empty, present the user with an error.

What is the impact of this change?

Handle the case where user opens the deadline cloud submitter from an unsaved script.

How was this change tested?

Yes

Did you run the "Job Bundle Output Tests"? If not, why not? If so, paste the test results here.


Timestamp: 2023-09-20T22:37:07.916822+00:00
Running job bundle output test: /home/rocky/git/deadline-cloud-for-nuke/job_bundle_output_tests/multi-load-save

multi-load-save
Test succeeded

Timestamp: 2023-09-20T22:37:08.247677+00:00
Running job bundle output test: /home/rocky/git/deadline-cloud-for-nuke/job_bundle_output_tests/noise-saver

noise-saver
Test succeeded

Timestamp: 2023-09-20T22:37:08.443511+00:00
Running job bundle output test: /home/rocky/git/deadline-cloud-for-nuke/job_bundle_output_tests/cwd-path

cwd-path
Test succeeded

Timestamp: 2023-09-20T22:37:08.650688+00:00
Running job bundle output test: /home/rocky/git/deadline-cloud-for-nuke/job_bundle_output_tests/ocio

ocio
Test succeeded

All tests passed, ran 4 total.
Timestamp: 2023-09-20T22:37:11.037997+00:00

Was this change documented?

No, bug fix.

Is this a breaking change?

No

@jlangmann-aws jlangmann-aws requested a review from a team as a code owner September 20, 2023 23:20
…unsaved scene

Signed-off-by: Julie Langmann <69699954+jlangmann-aws@users.noreply.github.com>
@mwiebe mwiebe merged commit f660fdf into mainline Sep 21, 2023
6 checks passed
@mwiebe mwiebe deleted the jlangm_unsavedScene branch September 21, 2023 00:17
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

Successfully merging this pull request may close these issues.

3 participants