Skip to content

Commit

Permalink
Merge pull request #610 from rokwire/release/1.9.0
Browse files Browse the repository at this point in the history
Release/1.9.0
  • Loading branch information
sandeep-ps authored Jan 13, 2021
2 parents 584c968 + 5358d34 commit 4f8cd6b
Show file tree
Hide file tree
Showing 90 changed files with 24,269 additions and 32 deletions.
52 changes: 52 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
## Description
_Please provide a summary of the pull request and the issue it fixes. Please add necessary details, context, dependencies, explanation of when review is needed (see next section), etc._

**Fixes #(add issue number here and remove parentheses)**

[comment]: # (This project only accepts pull requests related to open issues.)
[comment]: # (If suggesting a new feature or change, please discuss it in an issue first.)
[comment]: # (If fixing a bug, there should be an issue describing it with steps to reproduce.)

## Review Time Estimate
_Please give your idea of how soon this pull request needs to be reviewed by selecting one of the options below. This can be based on the criticality of the issue at hand and/or other relevant factors._

[comment]: # (To select an option, please put an 'x' in the applicable box.)
[comment]: # (If you're unsure about any of these, don't hesitate to ask. We're here to help!.)

- [ ] Immediately
- [ ] Within a week
- [ ] When possible

## Type of changes
_Please select a relevant option:_

[comment]: # (To select an option, please put an 'x' in the applicable box.)
[comment]: # (If you're unsure about any of these, don't hesitate to ask. We're here to help!.)

- [ ] Bug fix (non-breaking change which fixes an issue).
- [ ] New feature (non-breaking change which adds functionality).
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected).
- [ ] Other (any another change that does not fall in one of the above categories.)

## Checklist:
_Please select all applicable options:_

[comment]: # (To select your options, please put an 'x' in the all boxes that apply.)
[comment]: # (If you're unsure about any of these, don't hesitate to ask. We're here to help!.)

- [ ] I have signed the Rokwire Contributor License Agreement ([CLA](https://rokwire.org/rokwire_cla)). (_Any contributor who is not an employee of the University of Illinois whose official duties include contributing to the Rokwire software, or who is not paid by the Rokwire project, needs to sign the CLA before their contribution can be accepted._)
- [ ] I have updated the [CHANGELOG](../CHANGELOG.md).
- [ ] I have read the [Contributor Guidelines](../CONTRIBUTING.md).
- [ ] I have performed a self-review of my own code.
- [ ] I have commented my code, particularly in hard-to-understand areas.
- [ ] My change requires updating the documentation.
- [ ] I have made necessary changes to the documentation.
- [ ] I have added tests related to my changes.
- [ ] My changes generate no new warnings.
- [ ] New and existing unit tests pass locally with my changes.
- [ ] Any dependent changes have been merged and published in downstream modules.

---

[comment]: # (Template credit: This pull request template is based on Embedded Artistry {https://github.com/embeddedartistry/templates/blob/master/.github/PULL_REQUEST_TEMPLATE.md}, Clowder {https://github.com/clowder-framework/clowder/blob/develop/.github/PULL_REQUEST_TEMPLATE.md}, and TalAter {https://github.com/TalAter/open-source-templates} templates.)

4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,7 @@ authservice/credentials.env
*.egg-info/
dist/
/appconfigservice/.python-version
contributions/catalog/env/Lib/site-packages/chardet-3.0.4.dist-info/RECORD
*.pyd
*.pyi
contributions/catalog/env/Lib/site-packages/chardet-3.0.4.dist-info/INSTALLER
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
hooks:
- id: detect-secrets
args: ['--baseline', '.secrets.baseline']
exclude: .*/tests/.*
exclude: .*/bootstrap/.*
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,28 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [1.9.0] - 2020-12-17
### Fixed
- Fix the error code to 400 on events missing fields query. [#448](https://github.com/rokwire/rokwire-building-blocks-api/pull/448)
- Text changes to Contributions Catalog. [#601](https://github.com/rokwire/rokwire-building-blocks-api/issues/601)
### Added
- Add capabilities dataset in contribution building block. [#401](https://github.com/rokwire/rokwire-building-blocks-api/issues/401)
- Add contribution building block. [#406](https://github.com/rokwire/rokwire-building-blocks-api/issues/406)
- Add talent data to contribution dataset. [#407](https://github.com/rokwire/rokwire-building-blocks-api/issues/407)
- Add search option in contribution and capability dataset. [#458](https://github.com/rokwire/rokwire-building-blocks-api/issues/458)
- Contributor guidelines. [#572](https://github.com/rokwire/rokwire-building-blocks-api/issues/572)
- A pull request template. [#573](https://github.com/rokwire/rokwire-building-blocks-api/issues/573)
- Add Contributions Catalog Frontend. [#462](https://github.com/rokwire/rokwire-building-blocks-api/issues/462)
- Add Github authentication for Contributions Catalog. [#580](https://github.com/rokwire/rokwire-building-blocks-api/issues/580)
- Add Rokwire Group admins AD group to list of authorized event write groups. [#607](https://github.com/rokwire/rokwire-building-blocks-api/issues/607)

## Changed
- Separated contribution yaml from rokwire.yaml. [#514](https://github.com/rokwire/rokwire-building-blocks-api/issues/514)
- Timestamp format for non pii dataset has been changed. [#566](https://github.com/rokwire/rokwire-building-blocks-api/issues/566)
- Apply query parameters to subevent search. [#581](https://github.com/rokwire/rokwire-building-blocks-api/issues/581)
- Support multiple groups when doing authorization. [#447](https://github.com/rokwire/rokwire-building-blocks-api/issues/447)
- Support events building block group authorization. [#596](https://github.com/rokwire/rokwire-building-blocks-api/issues/596)

## [1.8.0] - 2020-10-01
### Added
- Add multiple client id ability to auth library. [#548](https://github.com/rokwire/rokwire-building-blocks-api/issues/548)
Expand Down Expand Up @@ -79,6 +101,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [1.4.0] - 2020-06-11
### Added
- Index to PII and Non-PII database collections. [#428](https://github.com/rokwire/rokwire-building-blocks-api/issues/428)
- Add search option in contribution and capability dataset. [#458](https://github.com/rokwire/rokwire-building-blocks-api/issues/458)

### Changed
- Incoming requests can be validated against a list of API keys. [#277](https://github.com/rokwire/rokwire-building-blocks-api/issues/277)
Expand Down Expand Up @@ -113,6 +136,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [1.2.0] - 2020-03-24
### Added
- Add capabilities dataset in contribution building block. [#401](https://github.com/rokwire/rokwire-building-blocks-api/issues/401)
- Add contribution building block. [#406](https://github.com/rokwire/rokwire-building-blocks-api/issues/406)
- Add environment variable to set url prefix for the connexion events building block. [#369](https://github.com/rokwire/rokwire-building-blocks-api/issues/369)
- Add super events tag to refactoring branch. [#316](https://github.com/rokwire/rokwire-building-blocks-api/issues/316)
- Get events by multiple event ids. [#268](https://github.com/rokwire/rokwire-building-blocks-api/issues/268)
Expand Down
45 changes: 45 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Contributing to Rokwire Platform

First of all, thanks for considering contributing to the Rokwire Platform. We look forward to hearing and learning from you and receiving your contribution. We have put together the following guidelines to help you navigate the contribution process and to outline expectations.

## Code of Conduct

The [Rokwire Code of Conduct](CODE_OF_CONDUCT.md) governs this project and everyone participating in it. By participating in this project, we expect you to uphold this code. Please report unacceptable behavior to [email protected].

## How to Contribute

There are different ways you can contribute to the Rokwire Platform. You can start by searching the existing issues and pull requests in the Rokwire GitHub repositories. It will help to see if what you are planning to contribute is already under discussion. As described below, we welcome various kinds of contributions, such as Reporting Bugs, Requesting Features/Enhancements, Contributing Code.

## Reporting Bugs/Accessibility/Usability Issues

If you find any bugs, accessibility or usability issues please report them using the appropriate [issue templates](https://github.com/rokwire/rokwire-building-blocks-api/issues/new/choose). Please make sure that it’s not a duplicate of an existing issue by searching the [issues list](https://github.com/rokwire/rokwire-building-blocks-api/issues). Please provide as many details as possible to help the contributors who, like you, will be working on it in the future.

## Requesting Features/Enhancements

We are always on the lookout for new ideas and feature requests. Please share your thoughts about a new feature or enhancement by submitting a [Feature Request](https://github.com/rokwire/rokwire-building-blocks-api/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=%5BFEATURE%5D). Please make sure that this is not a duplicate of an existing feature request by searching the [issues list](https://github.com/rokwire/rokwire-building-blocks-api/issues). Here also, please share as many details as possible for future discussion.

## Contributing Code

We are excited that you may be interested in contributing code to the Rokwire Platform. To maintain standards of programming and to keep things manageable, we request that you follow the workflow shared below. Any contributor who is not an employee of the University of Illinois whose official duties include contributing to the Rokwire software, or who is not paid by the Rokwire project, needs to sign the [Rokwire Contributors License Agreement (CLA)](https://rokwire.org/rokwire_cla) before their contribution can be accepted. If you belong to this group, please complete and sign the CLA and then scan and email a PDF file of the CLA to [email protected]. If necessary, you can send an original signed agreement to Rokwire, University of Illinois, 331 Grainger Engineering Library, 1301 W. Springfield Avenue, MC-274, Urbana, Illinois 61801.

### Development Workflow

1. Create a [GitHub account](https://github.com/join), if you don’t already have one.
2. Start the development workflow either by [creating a new issue](https://docs.github.com/en/free-pro-team@latest/github/managing-your-work-on-github/creating-an-issue) or by starting from an already existing issue in the repository. We expect that each contribution, whether major or minor, always starts from an issue. An issue can be either a bug report, accessibility report, usability report, or a feature request. When creating a new GitHub issue, please make sure to include as many details as possible. If starting from an existing GitHub issue, please make sure that you understand it clearly, and if not, please share your questions/comments in the issue to get things clarified before you start writing code. When working on a new feature request, it will be a good idea to have discussions with the Rokwire Open Source community through GitHub issues, before starting design and development.
3. [Create a fork of the repository and clone](https://docs.github.com/en/free-pro-team@latest/github/getting-started-with-github/fork-a-repo) it to your development machine.
4. [Create a new branch](https://docs.github.com/en/free-pro-team@latest/github/collaborating-with-issues-and-pull-requests/creating-and-deleting-branches-within-your-repository#creating-a-branch) from the `develop` branch. Please use the following naming convention for naming branches: `<issue number>-<short-description-separated-by-hyphens>`. For example, `201-add-maps-for-event-locations`.
5. Implement the code changes on your branch. Please make sure to update the [CHANGELOG](CHANGELOG.md) and relevant documentation as needed.
6. From your branch in the forked repository, make a pull request against the develop branch in the root repository. Please follow the instructions and provide more details about your pull request using the [pull request template](.github/pull_request_template.md).
7. Please link your pull request to the GitHub issue that you are trying to implement or fix. Please see the relevant [GitHub documentation](https://docs.github.com/en/github/managing-your-work-on-github/linking-a-pull-request-to-an-issue) on this.
8. When the pull request is created, the code repository maintainer(s) gets added as reviewers automatically. Work with the maintainer(s) to get your change reviewed. The maintainer(s) may also invite other experts or developers as reviewers.
9. After your pull request is reviewed and approved by the maintainer(s), a maintainer will [merge your branch](https://docs.github.com/en/free-pro-team@latest/github/collaborating-with-issues-and-pull-requests/merging-a-pull-request#merging-a-pull-request-on-github) to the develop branch using a squash commit.
10. After your branch has been merged to the remote develop branch, pull the latest code from the remote repository to your forked repository to view your change in your development environment.
11. At this point, you may want to [delete your local branch](https://docs.github.com/en/free-pro-team@latest/github/collaborating-with-issues-and-pull-requests/creating-and-deleting-branches-within-your-repository#deleting-a-branch) in your forked repository.

### Code Reviews

Each repository will have at least one maintainer who will be responsible for reviewing the incoming pull request. In certain situations, other contributors may also be brought in as reviewers by the maintainer. After a pull request gets successfully reviewed, the incoming branch is merged to the develop branch. To keep the commit history clean, we will try to squash the commits into a single commit for each merge onto the develop branch.

### Documentation

Currently, most of the developer documentation is available as READMEs in the code repositories. We describe the various API endpoints using the OpenAPI specification. The Rokwire Platform API documentation is available for your reference at https://api.rokwire.illinois.edu/docs/.
2 changes: 1 addition & 1 deletion appconfigservice/appconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ openapi: 3.0.0
info:
title: Rokwire App Config Building Block API
description: App Config Building Block API Documentation
version: 1.8.0
version: 1.9.0
servers:
- url: https://api.rokwire.illinois.edu
description: Production server
Expand Down
2 changes: 1 addition & 1 deletion appconfigservice/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pymongo[tls,srv]==3.7.2
pytest==5.0.1
requests==2.22.0
pyjwt==1.7.1
cryptography==2.7
cryptography==3.2
gunicorn==20.0.4
python-dotenv==0.10.3
gevent==20.9.0
Expand Down
11 changes: 11 additions & 0 deletions auth-middleware-test-svc/flaskapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,17 @@
def hello_world():
return "Hello world!"

@app.route('/authorize')
def authorize():
id_info = auth_middleware.authenticate()
group_list = None
try:
group_list = id_info["uiucedu_is_member_of"]
except Exception:
raise Exception('Token did not contain the group info')
auth_middleware.authorize(group_list)
auth_middleware.authorize(auth_middleware.rokwire_app_config_manager_group)
return "authorized"

if __name__ == '__main__':
app.run(port=5000, debug=True)
2 changes: 1 addition & 1 deletion authservice/auth.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ openapi: 3.0.2
info:
title: Rokwire Auth Building Block API
description: Authentication Building Block API Documentation
version: "1.8.0"
version: "1.9.0"
paths:
/authentication/phone-initiate:
post:
Expand Down
32 changes: 32 additions & 0 deletions contributions/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
FROM python:3-alpine

LABEL maintainer="[email protected]"

EXPOSE 5000

WORKDIR /usr/src/app/lib

COPY lib .

WORKDIR /usr/src/app/contributions

COPY contributions .

RUN apk --update add python py-pip openssl ca-certificates py-openssl && \
apk --update add --virtual build-dependencies libffi-dev openssl-dev python-dev py-pip build-base && \
pip install --upgrade pip && \
pip install -r requirements.txt --no-cache-dir && \
apk del build-dependencies

WORKDIR /usr/src/app/contributions/api


COPY contributions/contribution.yaml .

ENV MONGO_CONTRIBUTION_URL="" \
API_LOC="." \
FLASK_APP="contributions_rest_service" \
FLASK_ENV="development" \
CONTRIBUTION_URL_PREFIX=""

CMD ["gunicorn", "contributions_rest_service:app", "--config", "/usr/src/app/contributions/api/gunicorn.config.py"]
Loading

0 comments on commit 4f8cd6b

Please sign in to comment.