You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by fo...@apache.org on 2018/05/04 07:02:04 UTC

[08/50] incubator-airflow git commit: [AIRFLOW-2348] Strip path prefix from the destination_object when source_object contains a wildcard[]

[AIRFLOW-2348] Strip path prefix from the destination_object when source_object contains a wildcard[]

Closes #3247 from csoulios/master


Project: http://git-wip-us.apache.org/repos/asf/incubator-airflow/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-airflow/commit/840930b4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-airflow/tree/840930b4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-airflow/diff/840930b4

Branch: refs/heads/v1-10-test
Commit: 840930b4d0c545adc24d8eb040974f88370e081b
Parents: 3368f42
Author: Christos Soulios <cs...@gmail.com>
Authored: Sat Apr 28 20:44:53 2018 +0200
Committer: Fokko Driesprong <fo...@godatadriven.com>
Committed: Sat Apr 28 20:44:53 2018 +0200

----------------------------------------------------------------------
 airflow/contrib/operators/gcs_to_gcs.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-airflow/blob/840930b4/airflow/contrib/operators/gcs_to_gcs.py
----------------------------------------------------------------------
diff --git a/airflow/contrib/operators/gcs_to_gcs.py b/airflow/contrib/operators/gcs_to_gcs.py
index 6acc517..9bcf9d4 100644
--- a/airflow/contrib/operators/gcs_to_gcs.py
+++ b/airflow/contrib/operators/gcs_to_gcs.py
@@ -99,7 +99,7 @@ class GoogleCloudStorageToGoogleCloudStorageOperator(BaseOperator):
             for source_object in objects:
                 if self.destination_object:
                     destination_object = "{}/{}".format(self.destination_object,
-                                                        source_object)
+                                                        source_object[wildcard_position:])
                 else:
                     destination_object = source_object
                 self.log.info('Executing copy of gs://{0}/{1} to '