fix(filesystem): default bucket_url to '.' for bare destination string#3955
fix(filesystem): default bucket_url to '.' for bare destination string#3955Bhagwat-45 wants to merge 1 commit into
Conversation
|
@Bhagwat-45 by setting a default you are making [credentials]
bucket_url="file:///."(I didnt check it, pwd may be slightly different) |
|
@rudolfix the initial issue was for quality of life and supporting, similar to dlt.pipeline(..., destination="filesystem")Setting up Potential solutions
If this is too complicated, we should avoid changes. |
Description
Allows bare
dlt.pipeline(..., destination="filesystem")without requiringbucket_urlto be set inconfig.toml, matching the existing behavior of theduckdbdestination.Previously this would throw a
ConfigFieldMissingException. The fix setsbucket_url = "."(current directory) as the default inFilesystemConfiguration. The existingnormalize_bucket_url()method already handles"."correctly, converting it to an absolutefile://URL at resolve time — so this is a minimal, safe one-line change.Files changed:
dlt/common/storages/configuration.py— setbucket_url: str = "."as the defaulttests/sources/filesystem/test_config_sections.py— rewrote test to reflect new default; added test verifying config section path for cloud destinations (which still require credentials)tests/load/filesystem/test_filesystem_factory.py— updated stale commenttests/workspace/cli/test_config_toml_writer.py— updated assertion and commentRelated Issues
dlt.pipeline(..., destination="filesystem")#3886Additional Context
Tests were run locally and passed:
Result: 55 passed, 21 skipped, 0 failed.