moomindani commented on PR #63622:
URL: https://github.com/apache/airflow/pull/63622#issuecomment-4063085737
You're right, sorry about that. Here's an actual DAG:
```python
from datetime import datetime
from airflow.models.dag import DAG
from airflow.providers.amazon.aws.operators.s3 import (
S3CreateBucketOperator,
S3DeleteBucketOperator,
)
ACCOUNT_ID = "xxxxxxxxxxxx"
REGION = "us-east-1"
BUCKET_NAME = f"airflow-ns-test-{ACCOUNT_ID}-{REGION}-an"
with DAG(
dag_id="test_s3_account_regional_namespace",
start_date=datetime(2026, 1, 1),
schedule=None,
catchup=False,
) as dag:
create_bucket = S3CreateBucketOperator(
task_id="create_bucket",
bucket_name=BUCKET_NAME,
region_name=REGION,
bucket_namespace="account-regional",
)
delete_bucket = S3DeleteBucketOperator(
task_id="delete_bucket",
bucket_name=BUCKET_NAME,
force_delete=False,
)
create_bucket >> delete_bucket
```
I triggered this DAG on a local Airflow instance with `botocore>=1.42.0` and
confirmed:
- `create_bucket` task succeeded — bucket
`airflow-ns-test-xxxxxxxxxxxx-us-east-1-an` was created in the account-regional
namespace
- `delete_bucket` task succeeded — bucket was cleaned up
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]