Hi,
1. 你使用的环境是什么?mac的还是哪个版本的linux
2. 你是源码编译的吗?还是直接Pip install apache-flink安装的
3. 你使用conda的自带的Python环境,还是创建了venv,对应的Python版本是啥

Best,
Xingbo

大森林 <[email protected]> 于2020年10月19日周一 上午11:23写道:

> 我用的是3.6的anaconda虚拟环境.
>
>
>
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:
>                                                   "user-zh"
>                                                                     <
> [email protected]&gt;;
> 发送时间:&nbsp;2020年10月19日(星期一) 上午9:53
> 收件人:&nbsp;"大森林"<[email protected]&gt;;
> 抄送:&nbsp;"user-zh"<[email protected]&gt;;
> 主题:&nbsp;Re: 请问pyflink的udf是否必须是python3.5谢谢!
>
>
>
> Hi,
>
> pyflink 1.11支持的python版本是3.5,
> 3.6,3.7。这个报错看起来像是你的环境里面的apache-beam的版本太低导致的。你可以看下beam的版本是不是2.19
>
> Best,
> Xingbo
>
> 大森林 <[email protected]&gt; 于2020年10月17日周六 下午5:54写道:
>
> &gt;
> &gt; 您好!
> &gt; 请问目前的apache-flink是否必须在python3.5以下才能完全兼容?
> &gt;
> &gt; 完整代码是:
> &gt;
> &gt;
> https://enjoyment.cool/2020/02/27/Three-Min-Series-How-to-create-UDF-in-PyFlink-1-10/
> &gt
> <https://enjoyment.cool/2020/02/27/Three-Min-Series-How-to-create-UDF-in-PyFlink-1-10/&gt>
> ;
> &gt;
> &gt; 碰到这么个问题:
> &gt;&nbsp;&nbsp; File
> &gt;
> "dev/.conda/envs/3.5/lib/python3.5/site-packages/apache_beam/runners/common.pxd",
> &gt; line 85, in init pyflink.fn_execution.fast_operations
> &gt; ValueError: apache_beam.runners.common.PerWindowInvoker size changed,
> may
> &gt; indicate binary incompatibility. Expected 160 from C header, got 152
> from
> &gt; PyObject
> &gt;
> &gt; 感觉看起来像是底层胡cython不太兼容.
> &gt; 请问我是否必须使用python3.5的虚拟环境?感谢!
> &gt;

回复