Refine logger naming - #107
Merged
Merged
Conversation
- Updated logger initialization in `src/server/plantdb/server/cli/fsdb_rest_api.py` to use `__name__.split('.')[-1]`.
- Changed logger setup in the following CLI modules to use `__name__.split('.')[0]`:
- `src/commons/plantdb/commons/cli/fsdb_import_folder.py`
- `src/commons/plantdb/commons/cli/fsdb_import_images.py`
- `src/commons/plantdb/commons/cli/fsdb_import_file.py`
- `src/client/plantdb/client/cli/fsdb_rest_api_sync.py`
- `src/commons/plantdb/commons/cli/shared_fsdb.py`
- Ensures logger names reflect the module name, improving consistency across the codebase.
…t database
- Import `test_database` from `plantdb.commons.test_database` in `src/server/plantdb/server/test_rest_api.py`
- Import `API_PREFIX` from `plantdb.server.test_rest_api`
- Create a test database with `test_database(dataset=None)` before starting the API
- Construct request URLs using `f"{api.get_base_url()}/{API_PREFIX}/scans"` instead of the hard‑coded `/scans` path
- Adjust example usage comments to reflect the new imports and URL construction.
ArthurLuciani2
approved these changes
Jul 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
__name__(or its components) rather than__file__, ensuring logger names match the module names for consistency.API_PREFIXandtest_database, create a temporary test database, and build request URLs using the prefix instead of hard‑coded paths.