You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@streampipes.apache.org by "bossenti (via GitHub)" <gi...@apache.org> on 2023/02/18 20:26:42 UTC

[PR] chore(python-docs): improve getting started section (streampipes)

bossenti opened a new pull request, #1310:
URL: https://github.com/apache/streampipes/pull/1310

   <!--
     ~ Licensed to the Apache Software Foundation (ASF) under one or more
     ~ contributor license agreements.  See the NOTICE file distributed with
     ~ this work for additional information regarding copyright ownership.
     ~ The ASF licenses this file to You under the Apache License, Version 2.0
     ~ (the "License"); you may not use this file except in compliance with
     ~ the License.  You may obtain a copy of the License at
     ~
     ~    http://www.apache.org/licenses/LICENSE-2.0
     ~
     ~ Unless required by applicable law or agreed to in writing, software
     ~ distributed under the License is distributed on an "AS IS" BASIS,
     ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     ~ See the License for the specific language governing permissions and
     ~ limitations under the License.
     ~
     -->
     
     <!--
   Thanks for contributing! Here are some tips you can follow to help us incorporate your contribution quickly and easily:
   1. If this is your first time, please read our contributor guidelines:
       - https://streampipes.apache.org/getinvolved.html
       - https://cwiki.apache.org/confluence/display/STREAMPIPES/Getting+Started
   2. Make sure the PR title is formatted like: `[#<GitHub issue id>] PR title ...`
   3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., `[WIP][#<GitHub issue id>] PR title ...`.
   4. Please write your PR title to summarize what this PR proposes/fixes.
   5. Link the PR to the corresponding GitHub issue (if present) in the `Development` section in the right menu bar. 
   6. Be sure to keep the PR description updated to reflect all changes.
   7. If possible, provide a concise example to reproduce the issue for a faster review.
   8. Make sure tests pass via `mvn clean install`.
   9. (Optional) If the contribution is large, please file an Apache ICLA
       - http://apache.org/licenses/icla.pdf
   -->
   
   ### Purpose
   <!--
   Please clarify what changes you are proposing and describe how those changes will address the issue.
   Furthermore, describe potential consequences the changes might have.
   -->
   Improve the `getting started` section of the Python documentation by adding some information about how to develop & contribute as well as on how to setup StreamPipes via `docker compose`.
   
   ### Remarks
   <!--
   Is there anything left we need to pay attention on?
   Are there some references that might be important? E.g. links to Confluence, or discussions
   on the mailing list or GitHub.
   -->
   PR introduces (a) breaking change(s): no
   
   PR introduces (a) deprecation(s): no
   


-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] chore(python-docs): improve getting started section (streampipes)

Posted by "bossenti (via GitHub)" <gi...@apache.org>.
bossenti merged PR #1310:
URL: https://github.com/apache/streampipes/pull/1310


-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] chore(python-docs): improve getting started section (streampipes)

Posted by "tenthe (via GitHub)" <gi...@apache.org>.
tenthe commented on code in PR #1310:
URL: https://github.com/apache/streampipes/pull/1310#discussion_r1112272146


##########
streampipes-client-python/docs/getting-started/developing.md:
##########
@@ -0,0 +1,106 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one or more
+  ~ contributor license agreements.  See the NOTICE file distributed with
+  ~ this work for additional information regarding copyright ownership.
+  ~ The ASF licenses this file to You under the Apache License, Version 2.0
+  ~ (the "License"); you may not use this file except in compliance with
+  ~ the License.  You may obtain a copy of the License at
+  ~
+  ~    http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing, software
+  ~ distributed under the License is distributed on an "AS IS" BASIS,
+  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~ See the License for the specific language governing permissions and
+  ~ limitations under the License.
+  ~
+-->
+
+## 📖 Development Guide
+This document describes how to easily set up your local dev environment to work on the
+StreamPipes Python client 🐍.
+<br>
+
+### 🚀 First Steps
+
+1) **Set up your Python environment**
+
+Create a virtual Python environment with a tool of your choice.
+As a next step, install all required dependencies for the development, e.g., with `pip`:
+
+```bash
+pip install .[dev]  # or alternatively: pip install .[all] to include dependencies for building the docs as well
+```
+
+In case you are on macOS and using `zsh` the following should work for you:
+```bash
+pip install ."[dev]"
+```
+<br>
+
+2) **Install pre-commit hook**
+
+The pre-commit hook is run before every commit and takes care about code style,
+linting, type hints, import sorting, etc. It will stop your commit in case the changes do not apply the expected format.
+Always check to have the recent version of the pre-commit hook installed otherwise the CI build might fail. 
+If you are interested you can have a deeper look on the underlying library: [pre-commit](https://pre-commit.com/).
+
+```bash
+pre-commit install
+```
+The definition of the pre-commit hook can be found in [.pre-commit-config.yaml](.pre-commit-config.yaml).
+
+<br>
+
+### 👏 Conventions
+Below we list some conventions that we have agreed on for creating the StreamPipes Python client.
+Please comply to them when you plan to contribute to this project.
+If you have any other suggestions or would like to discuss them, we would be happy to hear from you on our mailing list [dev@streampipes.apache.org](mailto:dev@streampipes.apache.org).
+
+1) **Use `numpy` style for Python docstrings** 📄 <br>
+Please stick to the `numpy` style when writing docstrings, as we require this for generating our documentation.
+
+
+2) **Provide tests** ✅ <br>
+We are aiming for broad test coverage for the Python client and
+have therefore set a requirement of at least 90% unit test coverage.
+Therefore, please remember to write (unit) tests already during development. 
+If you have problems with writing tests, don't hesitate to ask us for help directly in the PR or
+even before that via our mailing list (see above).
+
+
+<!---
+TODO: replace link to java file by link to documentation

Review Comment:
   Can we already replace the link?



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] chore(python-docs): improve getting started section (streampipes)

Posted by "bossenti (via GitHub)" <gi...@apache.org>.
bossenti commented on code in PR #1310:
URL: https://github.com/apache/streampipes/pull/1310#discussion_r1112281903


##########
streampipes-client-python/docs/getting-started/developing.md:
##########
@@ -0,0 +1,106 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one or more
+  ~ contributor license agreements.  See the NOTICE file distributed with
+  ~ this work for additional information regarding copyright ownership.
+  ~ The ASF licenses this file to You under the Apache License, Version 2.0
+  ~ (the "License"); you may not use this file except in compliance with
+  ~ the License.  You may obtain a copy of the License at
+  ~
+  ~    http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing, software
+  ~ distributed under the License is distributed on an "AS IS" BASIS,
+  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~ See the License for the specific language governing permissions and
+  ~ limitations under the License.
+  ~
+-->
+
+## 📖 Development Guide
+This document describes how to easily set up your local dev environment to work on the
+StreamPipes Python client 🐍.
+<br>
+
+### 🚀 First Steps
+
+1) **Set up your Python environment**
+
+Create a virtual Python environment with a tool of your choice.
+As a next step, install all required dependencies for the development, e.g., with `pip`:
+
+```bash
+pip install .[dev]  # or alternatively: pip install .[all] to include dependencies for building the docs as well
+```
+
+In case you are on macOS and using `zsh` the following should work for you:
+```bash
+pip install ."[dev]"
+```
+<br>
+
+2) **Install pre-commit hook**
+
+The pre-commit hook is run before every commit and takes care about code style,
+linting, type hints, import sorting, etc. It will stop your commit in case the changes do not apply the expected format.
+Always check to have the recent version of the pre-commit hook installed otherwise the CI build might fail. 
+If you are interested you can have a deeper look on the underlying library: [pre-commit](https://pre-commit.com/).
+
+```bash
+pre-commit install
+```
+The definition of the pre-commit hook can be found in [.pre-commit-config.yaml](.pre-commit-config.yaml).
+
+<br>
+
+### 👏 Conventions
+Below we list some conventions that we have agreed on for creating the StreamPipes Python client.
+Please comply to them when you plan to contribute to this project.
+If you have any other suggestions or would like to discuss them, we would be happy to hear from you on our mailing list [dev@streampipes.apache.org](mailto:dev@streampipes.apache.org).
+
+1) **Use `numpy` style for Python docstrings** 📄 <br>
+Please stick to the `numpy` style when writing docstrings, as we require this for generating our documentation.
+
+
+2) **Provide tests** ✅ <br>
+We are aiming for broad test coverage for the Python client and
+have therefore set a requirement of at least 90% unit test coverage.
+Therefore, please remember to write (unit) tests already during development. 
+If you have problems with writing tests, don't hesitate to ask us for help directly in the PR or
+even before that via our mailing list (see above).
+
+
+<!---
+TODO: replace link to java file by link to documentation

Review Comment:
   As far as I know we do not have the Java client as part of our documentation yet 😞 



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org