Skip to content

sdks/python: enable recursive deletion for GCSFileSystem Paths#33611

Merged
liferoad merged 4 commits intoapache:masterfrom
mohamedawnallah:enableRecursiveDeleteGCS
Feb 5, 2025
Merged

sdks/python: enable recursive deletion for GCSFileSystem Paths#33611
liferoad merged 4 commits intoapache:masterfrom
mohamedawnallah:enableRecursiveDeleteGCS

Conversation

@mohamedawnallah
Copy link
Copy Markdown
Contributor

@mohamedawnallah mohamedawnallah commented Jan 15, 2025

Description

In this PR, we enable recursive deletion for Google Cloud Storage (GCS) paths, including directories and blobs. The delete method is updated to remove all blobs under a directory (prefix) when deleting GCS directories.

Additionally, we update the delete test to verify the recursive deletion of directories containing multiple files.

Changes include:

  • Enhanced delete method to support recursive directory deletion.
  • Added tests for recursive deletion of directories and files.

Fixes #27605

Current Behavior

Before After
before after

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Mention the appropriate issue in your description (for example: addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment fixes #<ISSUE NUMBER> instead.
  • Update CHANGES.md with noteworthy changes.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.

To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests
Go tests

See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Python GCSFileSystem.delete does not recursively delete

3 participants