Skip to content

Conversation

@candlerb
Copy link
Contributor

@candlerb candlerb commented Nov 1, 2019

Replacement for #5531
Fix #5518
This one also removes functions-api.md and functions-state.md (most of the latter moved to functions-develop.md)

@merlimat merlimat added this to the 2.5.0 milestone Nov 1, 2019
@merlimat merlimat added the doc Your PR contains doc changes, no matter whether the changes are in markdown or code files. label Nov 1, 2019
```
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
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note
You can write Pulsar Functions in python2 or python3. However, Pulsar only looks for python as the interpreter.

If you're running Pulsar Functions on Ubuntu system that only supports python3, you might fail to
start the functions. In this case, you can create a symlink. Your system will fail if
you have ever installed any other package that depends on Python 2.x. A solution is under development in Issue 5518.

sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 10

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Accepted, except I prefer "Your system will fail if you subsequently install any other package that depends on Python 2.x" (since by definition, if you've already installed a package which depends on python 2.x, you will already have "python" and Pulsar will use it)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, if so, you can use "Your system will fail if you subsequently install any other package that depends on Python 2.x".

@Jennifer88huang-zz
Copy link
Contributor

Fix #5518

@Jennifer88huang-zz Jennifer88huang-zz changed the title Documentation updates, mainly for Python API [Issue 5518][docs] Update docs mainly for Python API Nov 4, 2019
@candlerb
Copy link
Contributor Author

candlerb commented Nov 4, 2019

I think best if I now hand this branch over to @jennifer88huang for any further edits. Going back and forth is not a good use of time for either of us.

@sijie
Copy link
Member

sijie commented Nov 5, 2019

@jennifer88huang can you take over @candlerb branch and work on proofreading it?

@Jennifer88huang-zz
Copy link
Contributor

@sijie Sure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc Your PR contains doc changes, no matter whether the changes are in markdown or code files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

python functions cannot find python3 interpreter

4 participants