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

bug fix virtual compliance report #4303

Merged
merged 2 commits into from
Feb 29, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 6 additions & 1 deletion pyaedt/generic/compliance.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import os.path
from pathlib import Path
import time

from pyaedt.generic.design_types import get_pyaedt_app
Expand Down Expand Up @@ -298,6 +299,10 @@ def project_file(self):
def project_file(self, val):
self._project_file = val

@property
def project_name(self):
return Path(self.project_file).stem

@property
def use_portrait(self):
return self._use_portrait
Expand Down Expand Up @@ -886,7 +891,7 @@ def create_compliance_report(self, file_name="compliance_test.pdf", close_projec
report.add_toc()
output = report.save_pdf(self._output_folder, file_name=file_name)
if close_project:
self._desktop_class.odesktop.CloseProject(self._project_file)
self._desktop_class.odesktop.CloseProject(self.project_name)
if output:
self._desktop_class.logger.info(f"Report has been saved in {output}")
return output