You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: Respect user-provided directory in Ansys Notebook (#4358)
This pull request updates the file download logic in the
`file_transfer_service.py` utility to improve how the local download
directory is handled. The changes ensure that if no local directory is
specified, the current working directory (`self.cwd`) is used by
default, and that files are always downloaded to the intended directory.
Improvements to file download handling:
* Changed the default value of the `local_directory` parameter in the
`download` method from `"."` to `None`, clarifying intent and allowing
explicit handling of the default directory.
* Updated the logic in the `download` method to set `download_directory`
to `self.cwd` if `local_directory` is not provided, ensuring consistent
download behavior.
* Modified file copy operations to use the resolved `download_directory`
instead of always using `self.cwd`, so files are placed in the correct
location as specified by the user.
---------
Co-authored-by: pyansys-ci-bot <[email protected]>
0 commit comments