JavaLeb opened a new issue, #503:
URL: https://github.com/apache/flink-agents/issues/503

   ### Search before asking
   
   - [x] I searched in the 
[issues](https://github.com/apache/flink-agents/issues) and found nothing 
similar.
   
   ### Description
   
   When I ran react_agent_example.py in the Windows environment, I encountered 
the following error:
   
   C:\Users\my_user_name\.conda\envs\py311-flink-agents\python.exe 
D:\AI-Book\FlinkApplication\flink-agents\quickstart\react_agent_example.py 
   current_dir= D:\AI-Book\FlinkApplication\flink-agents\quickstart
   
C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\apache_beam\runners\portability\stager.py:63:
 UserWarning: pkg_resources is deprecated as an API. See 
https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources 
package is slated for removal as early as 2025-11-30. Refrain from using this 
package or pin to Setuptools<81.
     import pkg_resources
   Traceback (most recent call last):
     File 
"D:\AI-Book\FlinkApplication\flink-agents\quickstart\react_agent_example.py", 
line 114, in <module>
       main()
     File 
"D:\AI-Book\FlinkApplication\flink-agents\quickstart\react_agent_example.py", 
line 110, in main
       agents_env.execute()
     File 
"C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\flink_agents\runtime\remote_execution_environment.py",
 line 269, in execute
       self.__env.execute()
     File 
"C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\pyflink\datastream\stream_execution_environment.py",
 line 830, in execute
       return 
JobExecutionResult(self._j_stream_execution_environment.execute(j_stream_graph))
                                 
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File 
"C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\py4j\java_gateway.py",
 line 1322, in __call__
       return_value = get_return_value(
                      ^^^^^^^^^^^^^^^^^
     File 
"C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\pyflink\util\exceptions.py",
 line 146, in deco
       return f(*a, **kw)
              ^^^^^^^^^^^
     File 
"C:\Users\my_user_name\.conda\envs\py311-flink-agents\Lib\site-packages\py4j\protocol.py",
 line 326, in get_return_value
       raise Py4JJavaError(
   py4j.protocol.Py4JJavaError: An error occurred while calling o0.execute.
   : org.apache.flink.util.FlinkException: Failed to execute job 'Flink 
Streaming Job'.
        at 
org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.executeAsync(StreamExecutionEnvironment.java:2487)
        at 
org.apache.flink.streaming.api.environment.StreamExecutionEnvironment.execute(StreamExecutionEnvironment.java:2351)
        at 
org.apache.flink.streaming.api.environment.LocalStreamEnvironment.execute(LocalStreamEnvironment.java:68)
        at 
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at 
java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at 
org.apache.flink.api.python.shaded.py4j.reflection.MethodInvoker.invoke(MethodInvoker.java:244)
        at 
org.apache.flink.api.python.shaded.py4j.reflection.ReflectionEngine.invoke(ReflectionEngine.java:374)
        at 
org.apache.flink.api.python.shaded.py4j.Gateway.invoke(Gateway.java:282)
        at 
org.apache.flink.api.python.shaded.py4j.commands.AbstractCommand.invokeMethod(AbstractCommand.java:132)
        at 
org.apache.flink.api.python.shaded.py4j.commands.CallCommand.execute(CallCommand.java:79)
        at 
org.apache.flink.api.python.shaded.py4j.GatewayConnection.run(GatewayConnection.java:238)
        at java.base/java.lang.Thread.run(Thread.java:834)
   Caused by: org.apache.flink.util.FlinkException: Could not upload job files.
        at 
org.apache.flink.runtime.client.ClientUtils.uploadJobGraphFiles(ClientUtils.java:86)
        at 
org.apache.flink.runtime.client.ClientUtils.extractAndUploadJobGraphFiles(ClientUtils.java:62)
        at 
org.apache.flink.runtime.minicluster.MiniCluster.lambda$uploadAndSetJobFiles$31(MiniCluster.java:1137)
        at 
java.base/java.util.concurrent.CompletableFuture$UniAccept.tryFire(CompletableFuture.java:714)
        at 
java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
        at 
java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2075)
        at 
org.apache.flink.runtime.rpc.pekko.PekkoInvocationHandler.lambda$invokeRpc$1(PekkoInvocationHandler.java:268)
        at 
java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:859)
        at 
java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:837)
        at 
java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
        at 
java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2075)
        at 
org.apache.flink.util.concurrent.FutureUtils.doForward(FutureUtils.java:1315)
        at 
org.apache.flink.runtime.concurrent.ClassLoadingUtils.lambda$null$1(ClassLoadingUtils.java:93)
        at 
org.apache.flink.runtime.concurrent.ClassLoadingUtils.runWithContextClassLoader(ClassLoadingUtils.java:68)
        at 
org.apache.flink.runtime.concurrent.ClassLoadingUtils.lambda$guardCompletionWithContextClassLoader$2(ClassLoadingUtils.java:92)
        at 
java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:859)
        at 
java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:837)
        at 
java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
        at 
java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2075)
        at 
org.apache.flink.runtime.concurrent.pekko.ScalaFutureUtils$1.onComplete(ScalaFutureUtils.java:47)
        at org.apache.pekko.dispatch.OnComplete.internal(Future.scala:310)
        at org.apache.pekko.dispatch.OnComplete.internal(Future.scala:307)
        at org.apache.pekko.dispatch.japi$CallbackBridge.apply(Future.scala:234)
        at org.apache.pekko.dispatch.japi$CallbackBridge.apply(Future.scala:231)
        at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
        at 
org.apache.flink.runtime.concurrent.pekko.ScalaFutureUtils$DirectExecutionContext.execute(ScalaFutureUtils.java:65)
        at 
scala.concurrent.impl.CallbackRunnable.executeWithValue(Promise.scala:72)
        at 
scala.concurrent.impl.Promise$DefaultPromise.$anonfun$tryComplete$1(Promise.scala:288)
        at 
scala.concurrent.impl.Promise$DefaultPromise.$anonfun$tryComplete$1$adapted(Promise.scala:288)
        at 
scala.concurrent.impl.Promise$DefaultPromise.tryComplete(Promise.scala:288)
        at org.apache.pekko.pattern.PromiseActorRef.$bang(AskSupport.scala:624)
        at 
org.apache.pekko.pattern.PipeToSupport$PipeableFuture$$anonfun$pipeTo$1.applyOrElse(PipeToSupport.scala:33)
        at scala.concurrent.Future.$anonfun$andThen$1(Future.scala:536)
        at scala.concurrent.impl.Promise.liftedTree1$1(Promise.scala:33)
        at scala.concurrent.impl.Promise.$anonfun$transform$1(Promise.scala:33)
        at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
        at 
org.apache.pekko.dispatch.BatchingExecutor$AbstractBatch.processBatch(BatchingExecutor.scala:73)
        at 
org.apache.pekko.dispatch.BatchingExecutor$BlockableBatch.$anonfun$run$1(BatchingExecutor.scala:110)
        at 
scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
        at 
scala.concurrent.BlockContext$.withBlockContext(BlockContext.scala:85)
        at 
org.apache.pekko.dispatch.BatchingExecutor$BlockableBatch.run(BatchingExecutor.scala:110)
        at 
org.apache.pekko.dispatch.TaskInvocation.run(AbstractDispatcher.scala:59)
        at 
org.apache.pekko.dispatch.ForkJoinExecutorConfigurator$PekkoForkJoinTask.exec(ForkJoinExecutorConfigurator.scala:61)
        at 
java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
        at 
java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
        at 
java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
        at 
java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
        at 
java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
   Caused by: java.io.IOException: Found local file path with authority 'C:' in 
path 
'file://C://Users//my_user_name//.conda//envs//py311-flink-agents//Lib//site-packages//flink_agents//lib//flink-agents-dist-0.1.1.jar'.
 Hint: Did you forget a slash? (correct path would be 
'file:///C://Users//my_user_name//.conda//envs//py311-flink-agents//Lib//site-packages//flink_agents//lib//flink-agents-dist-0.1.1.jar')
        at 
org.apache.flink.core.fs.FileSystem.getUnguardedFileSystem(FileSystem.java:476)
        at org.apache.flink.core.fs.FileSystem.get(FileSystem.java:408)
        at org.apache.flink.core.fs.Path.getFileSystem(Path.java:284)
        at 
org.apache.flink.runtime.blob.BlobClient.uploadFile(BlobClient.java:404)
        at 
org.apache.flink.runtime.client.ClientUtils.uploadUserJars(ClientUtils.java:113)
        at 
org.apache.flink.runtime.client.ClientUtils.uploadAndSetUserJars(ClientUtils.java:105)
        at 
org.apache.flink.runtime.client.ClientUtils.uploadJobGraphFiles(ClientUtils.java:83)
        ... 47 more
   
   
   
   
   ### How to reproduce
   
   step 1: use Pycharm in Windows.
   step 2: execute react_agent_example.py
   
   ### Version and environment
   
   flink-agents v0.1.1, 
   windows,
   Python 3.11
   Pycharm.
   flink 1.20.3   local standalone.
   
   view detail in
   
https://nightlies.apache.org/flink/flink-agents-docs-release-0.1/docs/get-started/quickstart/react_agent/P
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
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]

Reply via email to