Jennifer88huang commented on a change in pull request #5531: Documentation 
updates, mainly for Python API
URL: https://github.com/apache/pulsar/pull/5531#discussion_r341595137
 
 

 ##########
 File path: site2/docs/functions-develop.md
 ##########
 @@ -35,6 +35,20 @@ def process(input):
 ```
 For complete code, see 
[here](https://github.com/apache/pulsar/blob/master/pulsar-functions/python-examples/native_exclamation_function.py).
 
+Note that functions can be written in python2 or python3, but pulsar
+currently only looks for "python" as the interpreter to execute them.
+
+A recent Ubuntu system may have only "python3" but not "python", in which
+case functions will fail to start.  As a workaround you can create a symlink, 
but beware this has some
+[risks](https://askubuntu.com/questions/320996/how-to-make-python-program-command-execute-python-3#answer-475815):
+
+```bash
+sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 10
+```
+
+If you choose to do this, be careful not to install any other package which
+depends on "python" (2.x)
 
 Review comment:
   A tiny suggestion on this: If we can summarize the risks briefly, we can use 
a brief summary, and not use external links.
   Reason: The external link might change or someone might delete the Q&A in 
this link, then the link in our docs will be broken, it's hard to maintain 
external links.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to