This is an automated email from the ASF dual-hosted git repository.

dianfu pushed a commit to branch release-1.12
in repository https://gitbox.apache.org/repos/asf/flink.git


The following commit(s) were added to refs/heads/release-1.12 by this push:
     new de53c34  [FLINK-20467][python][docs] Fix the example in Python 
DataStream API documentation
de53c34 is described below

commit de53c34d54dca99e5e7cd8af1596829832b16ffa
Author: acqua.csq <[email protected]>
AuthorDate: Thu Dec 3 17:46:41 2020 +0800

    [FLINK-20467][python][docs] Fix the example in Python DataStream API 
documentation
    
    This closes #14297.
---
 docs/dev/python/datastream-api-users-guide/operators.md    | 2 +-
 docs/dev/python/datastream-api-users-guide/operators.zh.md | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/docs/dev/python/datastream-api-users-guide/operators.md 
b/docs/dev/python/datastream-api-users-guide/operators.md
index f570cc1..5531f6c 100644
--- a/docs/dev/python/datastream-api-users-guide/operators.md
+++ b/docs/dev/python/datastream-api-users-guide/operators.md
@@ -49,7 +49,7 @@ instance:
 # Implementing MapFunction
 class MyMapFunction(MapFunction):
     
-    def map(value):
+    def map(self, value):
         return value + 1
         
 data_stream = env.from_collection([1, 2, 3, 4, 5], type_info=Types.INT())
diff --git a/docs/dev/python/datastream-api-users-guide/operators.zh.md 
b/docs/dev/python/datastream-api-users-guide/operators.zh.md
index a8aa81d..ab46814 100644
--- a/docs/dev/python/datastream-api-users-guide/operators.zh.md
+++ b/docs/dev/python/datastream-api-users-guide/operators.zh.md
@@ -46,7 +46,7 @@ Python DataStream API 给各种算子提供了函数接口,用户可以定义
 # Implementing MapFunction
 class MyMapFunction(MapFunction):
     
-    def map(value):
+    def map(self, value):
         return value + 1
         
 data_stream = env.from_collection([1, 2, 3, 4, 5], type_info=Types.INT())

Reply via email to