-
Notifications
You must be signed in to change notification settings - Fork 318
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
[Helper] Deprecate findOrCreateAValidPath and introduce clearer functions #5264
Conversation
[ci-build][with-all-tests] |
9d74c86
to
a834564
Compare
/// @param pathToFile The path to the file. The function ensures that the directory containing this file exists. | ||
/// | ||
/// @note The function assumes that a path to a file is given. | ||
static void ensureFolderForFileExists(const std::string& pathToFile); |
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.
why just not, "createFolder" and if folder already exists, it does nothing?
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.
this is what ensureFolderForFileExists
does, but recursively
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.
yes, I was just speaking about the name of the function that I find a bit complex.
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.
lol too late anyway... @hugtalbot already merged it 😆
commit 0806b07 Author: Paul Baksic <[email protected]> Date: Fri Feb 21 15:55:34 2025 +0100 [github] Use token for performance regression launching (sofa-framework#5287) Try fixing action commit 9f56fca Author: Paul Baksic <[email protected]> Date: Fri Feb 21 15:16:12 2025 +0100 [github] Add workflow for performance testing launch (sofa-framework#5286) * Add workflow for performance testing launch * Fix github token and sha commit 700b6cd Author: Olivier Roussel <[email protected]> Date: Thu Feb 20 23:27:00 2025 +0100 [IO.Mesh] Fix missing `iomanip` header in tests (sofa-framework#5279) Fix missing header commit 5307e85 Author: Hugo <[email protected]> Date: Wed Feb 19 14:25:24 2025 +0100 [ODESolver] Update data comment in EulerImplicit (sofa-framework#5282) commit fee9657 Author: Alex Bilger <[email protected]> Date: Wed Feb 19 13:48:07 2025 +0100 [ODESolver] Add option to compute residual at the end of the solving (sofa-framework#5263) commit a229972 Author: Alex Bilger <[email protected]> Date: Wed Feb 19 12:20:51 2025 +0100 [Helper] Deprecate findOrCreateAValidPath and introduce clearer functions (sofa-framework#5264) * [Helper] Fix findOrCreateAValidPath when given a file path * [Helper] Fix findOrCreateAValidPath when given a file path * Introduce clearer function names * deprecate findOrCreateAValidPath * restore previous findOrCreateAValidPath commit 4ee24f6 Author: Frederick Roy <[email protected]> Date: Wed Feb 19 20:15:38 2025 +0900 [All] Fix compilation with FLOATING_POINT_TYPE=float (sofa-framework#5269) fix compilation with FLOATING_POINT_TYPE=float commit ef7ff21 Author: Hugo <[email protected]> Date: Wed Feb 19 09:52:47 2025 +0100 [SceneUtility] Remove *AliasComponent (sofa-framework#5241) * [SceneUtility] Remove *AliasComponent * Update in the ComponentChange so that it appears as Removed * remove associated scenes commit aa36098 Author: Alex Bilger <[email protected]> Date: Wed Feb 19 00:04:17 2025 +0100 [SceneChecking] Check if a Node has an empty name (sofa-framework#5276) commit f2f0b10 Author: EulalieCoevoet <[email protected]> Date: Wed Feb 12 12:14:48 2025 +0100 [visual] Adds features to LineAxis and DrawTools (sofa-framework#5258) * [visual-gl] LineAxis & DrawTool: - fixes usage of thickness - new feature: infinite lines - new feature: vanishing infinite line - fixes typo * [visual] LineAxis: cleaning commit b4e8b98 Author: Paul Baksic <[email protected]> Date: Wed Feb 12 09:35:16 2025 +0100 [GUI] Remove Qt and make SofaImGUI as default viewer (sofa-framework#5176) * Add possibility to fetch and add by default for external plugins and set SofaGLFW as ON by default * Remove Qt-based GUI from sources * Add way to pull and build Sofa.Qt plugin * Fix compilation * Change order so SofaGLFW and SofaIMGUI are already in the target stack when runSofa produce the plugin_list.cong.default * Merge master * Make the packaging possible without Qt * Remove GuiDataRepository that was Qt specific -> will need to include it to the Qt gui plugin * Add fetchable Qt commit d2f194d Author: Alex Bilger <[email protected]> Date: Wed Feb 12 07:26:17 2025 +0100 [Contact] Clean FrictionContact (sofa-framework#5261) * [Contact] Replace double by SReal * add override keyword on destructor commit 62264fb Author: Alex Bilger <[email protected]> Date: Mon Feb 10 14:20:15 2025 +0100 [StateContainer] Allow coord difference in vOp for rigids (sofa-framework#5253) * [StateContainer] Allow coord difference in vOp for rigids * check that DataTypes support coordDifference commit 5120328 Author: erik pernod <[email protected]> Date: Mon Feb 10 14:19:28 2025 +0100 [Topology.Container] Add new method computeSegmentTriangleIntersectionInPlane in TriangleSetGeometryAlgorithm (sofa-framework#5188) * Update TriangleSetGeometryAlgorithms.h * Update TriangleSetGeometryAlgorithms.inl * [TopologyTest] Add comments * [Topology.Dynamic_test] factorize some code in TriangleSetTopology_test * [Topology.Dynamic_test] Add some tests in TriangleSetTopology_test to test adding and removing triangles * typo errors * [Topology.Dynamic_test] Add tests in TriangleSetTopology_test tto test TriangleSegmentIntersection inside same plane or with projection * Update TriangleSetTopology_test.cpp * Update TriangleSetTopology_test.cpp * Update TriangleSetTopology_test.cpp * Fix namespace commit 5448a14 Author: Alex Bilger <[email protected]> Date: Fri Jan 31 15:10:05 2025 +0100 [StateContainer] Extend the possible vector operations in vOp (sofa-framework#5237) * missing test * remove duplicated test * [StateContainer] Extend the possible vector operations in vOp --------- Co-authored-by: Paul Baksic <[email protected]> commit 6af25d5 Author: Alex Bilger <[email protected]> Date: Fri Jan 31 15:04:36 2025 +0100 [Simulation] Trigger warning when Node already contains component (sofa-framework#5212) * [Simulation] Trigger error when Node already contains component * also mention the class name * convert error to warning * fix STLExporter_test commit 9ceb6dc Author: Alex Bilger <[email protected]> Date: Fri Jan 31 15:04:21 2025 +0100 [SofaCUDA] Print CUDA standard at init of the module (sofa-framework#5166) * [SofaCUDA] Print CUDA standard at init of the module * add an empty scene loading the plugin * compiler output * remove empty scene commit 3eecf8f Author: Alex Bilger <[email protected]> Date: Wed Jan 29 22:18:50 2025 +0100 Bump version of Tracy from v0.9.1 to v0.11.1 (sofa-framework#5249) commit 3659403 Author: Alex Bilger <[email protected]> Date: Wed Jan 29 21:39:51 2025 +0100 [Core] Remove some static functions create (sofa-framework#5239) commit 989a885 Author: Alex Bilger <[email protected]> Date: Wed Jan 29 21:03:59 2025 +0100 [StateContainer] Extensive tests of MechanicalObject::vOp (sofa-framework#5233) * [StateContainer] Extensive tests of MechanicalObject::vOp * fix wrong name * fix test * Use variable for the coefficients * missing test * remove duplicated test commit 38c295d Author: Alex Bilger <[email protected]> Date: Wed Jan 29 19:54:39 2025 +0100 [Playback] Remove deprecated macro (sofa-framework#5231) commit ffddff7 Author: Paul Baksic <[email protected]> Date: Wed Jan 29 19:48:23 2025 +0100 [CMake] Add possibility to remove auto installing of resource files (sofa-framework#5230) Add possibility to remove auto installing of ressource files commit 7c6bddc Author: Alex Bilger <[email protected]> Date: Fri Jan 24 14:24:02 2025 +0100 [ODESolver] Remove repeated class name in log messages (sofa-framework#5242)
When given a file path, the function
findOrCreateAValidPath
created a folder with the name of the file. The problem is that it is not clear that the function accepts a folder path, a file path, or both. This function is now deprecated, and two functions with clearer intentions are introduced:ensureFolderExists
andensureFolderForFileExists
By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).
Reviewers will merge this pull-request only if