Skip to content

Commit

Permalink
Merge branch 'main' into feat/omniverse
Browse files Browse the repository at this point in the history
  • Loading branch information
mariostieriansys authored Mar 13, 2024
2 parents e0d51c8 + 8322958 commit d3ff72b
Show file tree
Hide file tree
Showing 2 changed files with 311 additions and 295 deletions.
10 changes: 9 additions & 1 deletion src/ansys/pyensight/core/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,14 @@ class methods, but if the EnSight session is already running, an instance can be
>>> from ansys.pyensight.core import LocalLauncher
>>> session = LocalLauncher().start()
>>> # Launch an instance of EnSight, then create a second connection to the instance
>>> from ansys.pyensight.core import LocalLauncher, Session
>>> launched_session = LocalLauncher().start()
>>> # Get a string that can be used to create a second connection
>>> session_string = str(launched_session)
>>> # Create a second connection to the same EnSight instance
>>> connected_session = eval(session_string)
"""

def __init__(
Expand Down Expand Up @@ -257,7 +265,7 @@ def __repr__(self):
session_dir = self.launcher.session_directory
s = f"Session(host='{self.hostname}', secret_key='{self.secret_key}', "
s += f"sos={self.sos}, rest_api={self.rest_api}, "
s += f"html_hostname={self.html_hostname}, html_port={self.html_port}, "
s += f"html_hostname='{self.html_hostname}', html_port={self.html_port}, "
s += f"grpc_port={self._grpc_port}, "
s += f"ws_port={self.ws_port}, session_directory=r'{session_dir}')"
return s
Expand Down
Loading

0 comments on commit d3ff72b

Please sign in to comment.