-
Notifications
You must be signed in to change notification settings - Fork 36
Refactoring of lib.fileio.auto_open function to work with subprocess (#266) #267
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
Conversation
removing the global definition of loggers to satisfy latest flake8 update
agalitsyna
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comments from 26 May 2025 Open2C meeting. @golobor @agalitsyna @Phlya
…ngs example tested and vis improved.
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
…ces updated, OSF download instead of obscure file name.
agalitsyna
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked backwards compatibility on (1) sample distiller-nf, (2) tests, (3) example notebooks.
Introduced the CommandFormatter interface, encapsulating file operations and validations.
Added standard CLI response outputs to enhance user interaction.
MODES_TO_FILES_PRESET: format keys with values as lists of possible operation modes (read, write, append).
COMMANDS: format and mode keys with values as dictionaries containing:
tool: the tool's presence is verified in the system.
command: a command formatted for substituting the number of available processors (nproc).
This structure streamlines adding new formats without altering existing code.
Added capabilities for handling binary files.
This feature is not currently utilized but provides flexibility for future enhancements.
Transitioned to using subprocess for file operations, improving compatibility and performance.
P.S. The function signatures and responses of auto_open remain unchanged, ensuring backward compatibility. However, the implementation using the CommandFormatter class offers a more convenient and versatile approach, enhancing code maintainability and scalability.