You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by Josemon Maliakal <jo...@gmail.com> on 2022/04/04 09:29:01 UTC

Regarding java.lang.NullPointerException

Hello There,
I started using pyflink recently,
Have anyone know why I am getting java.lang.NullPointerException when I am
trying to write an update function like the following

 tbl = tbl.select(update_tel(tbl.data)).execute_insert('result').wait()


Caused by: java.lang.NullPointerException
        at
org.apache.beam.runners.core.construction.PipelineOptionsTranslation.toProto(PipelineOptionsTranslation.java:54)
        at
org.apache.flink.streaming.api.runners.python.beam.BeamPythonFunctionRunner.open(BeamPythonFunctionRunner.java:230)
        at
org.apache.flink.streaming.api.operators.python.AbstractPythonFunctionOperator.open(AbstractPythonFunctionOperator.java:131)
        at
org.apache.flink.table.runtime.operators.python.AbstractStatelessFunctionOperator.open(AbstractStatelessFunctionOperator.java:110)

        at
org.apache.flink.table.runtime.operators.python.scalar.AbstractPythonScalarFunctionOperator.open(AbstractPythonScalarFunctionOperator.java:100)
        at
org.apache.flink.table.runtime.operators.python.scalar.PythonScalarFunctionOperator.open(PythonScalarFunctionOperator.java:62)
        at
org.apache.flink.streaming.runtime.tasks.RegularOperatorChain.initializeStateAndOpenOperators(RegularOperatorChain.java:110)
        at
org.apache.flink.streaming.runtime.tasks.StreamTask.restoreGates(StreamTask.java:711)
        at
org.apache.flink.streaming.runtime.tasks.StreamTaskActionExecutor$1.call(StreamTaskActionExecutor.java:55)
        at
org.apache.flink.streaming.runtime.tasks.StreamTask.restoreInternal(StreamTask.java:687)
        at
org.apache.flink.streaming.runtime.tasks.StreamTask.restore(StreamTask.java:654)
        at
org.apache.flink.runtime.taskmanager.Task.runWithSystemExitMonitoring(Task.java:958)
        at
org.apache.flink.runtime.taskmanager.Task.restoreAndInvoke(Task.java:927)
        at org.apache.flink.runtime.taskmanager.Task.doRun(Task.java:766)
        at org.apache.flink.runtime.taskmanager.Task.run(Task.java:575)
        at java.base/java.lang.Thread.run(Thread.java:834)



-- 
*Regards, *
*Josemon Maliakal*
*+9605936925dev@flink.apache.org <96...@flink.apache.org>*

Re: Regarding java.lang.NullPointerException

Posted by Xingbo Huang <hx...@gmail.com>.
Hi Josemon,

Can you provide the version of PyFlink you are using, and it would be
better if you can also provide code snippets that can be easily reproduced
this problem.

Best,
Xingbo

Josemon Maliakal <jo...@gmail.com> 于2022年4月5日周二 13:31写道:

> Hello There,
> I started using pyflink recently,
> Have anyone know why I am getting java.lang.NullPointerException when I am
> trying to write an update function like the following
>
>  tbl = tbl.select(update_tel(tbl.data)).execute_insert('result').wait()
>
>
> Caused by: java.lang.NullPointerException
>         at
>
> org.apache.beam.runners.core.construction.PipelineOptionsTranslation.toProto(PipelineOptionsTranslation.java:54)
>         at
>
> org.apache.flink.streaming.api.runners.python.beam.BeamPythonFunctionRunner.open(BeamPythonFunctionRunner.java:230)
>         at
>
> org.apache.flink.streaming.api.operators.python.AbstractPythonFunctionOperator.open(AbstractPythonFunctionOperator.java:131)
>         at
>
> org.apache.flink.table.runtime.operators.python.AbstractStatelessFunctionOperator.open(AbstractStatelessFunctionOperator.java:110)
>
>         at
>
> org.apache.flink.table.runtime.operators.python.scalar.AbstractPythonScalarFunctionOperator.open(AbstractPythonScalarFunctionOperator.java:100)
>         at
>
> org.apache.flink.table.runtime.operators.python.scalar.PythonScalarFunctionOperator.open(PythonScalarFunctionOperator.java:62)
>         at
>
> org.apache.flink.streaming.runtime.tasks.RegularOperatorChain.initializeStateAndOpenOperators(RegularOperatorChain.java:110)
>         at
>
> org.apache.flink.streaming.runtime.tasks.StreamTask.restoreGates(StreamTask.java:711)
>         at
>
> org.apache.flink.streaming.runtime.tasks.StreamTaskActionExecutor$1.call(StreamTaskActionExecutor.java:55)
>         at
>
> org.apache.flink.streaming.runtime.tasks.StreamTask.restoreInternal(StreamTask.java:687)
>         at
>
> org.apache.flink.streaming.runtime.tasks.StreamTask.restore(StreamTask.java:654)
>         at
>
> org.apache.flink.runtime.taskmanager.Task.runWithSystemExitMonitoring(Task.java:958)
>         at
> org.apache.flink.runtime.taskmanager.Task.restoreAndInvoke(Task.java:927)
>         at org.apache.flink.runtime.taskmanager.Task.doRun(Task.java:766)
>         at org.apache.flink.runtime.taskmanager.Task.run(Task.java:575)
>         at java.base/java.lang.Thread.run(Thread.java:834)
>
>
>
> --
> *Regards, *
> *Josemon Maliakal*
> *+9605936925dev@flink.apache.org <96...@flink.apache.org>*
>