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

Write test log for deployment failures #3596

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

adityagesh
Copy link
Collaborator

At present, test logs are not generated for deployment failures. This change creates case log for deployment failure with the failure reason.

@adityagesh adityagesh force-pushed the aditya/log_deployment_failures branch from 37abcb8 to a4635e1 Compare January 9, 2025 07:13
At present, test logs are not generated for deployment failures.
This change creates case log for deployment failure with the failure
reason.
@adityagesh adityagesh force-pushed the aditya/log_deployment_failures branch from a4635e1 to a5dada8 Compare January 9, 2025 07:14
self._log.info(
f"'{environment.name}' attached to test case "
f"'{result.runtime_data.metadata.full_name}({result.id_})': "
f"{exception}"
)
result.save_nodes_serial_console_logs()
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@squirrelsc , this doesn't work as environment.nodes is empty list

Shall I make _save_console_log_and_check_panic as a public method of Platform and then invoke platform.save_console_log(path=result.log_path)

def _save_console_log_and_check_panic(

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

_attach_failed_environment_to_result is too late to attach log. What I mean is to attach log when this method is called in deploy/prepare methods. It can attach to the environment log, not the node log. env should be created already, and it includes all node logs.

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.

2 participants