Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release/4.0.0 #108

Merged
merged 66 commits into from
Apr 1, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
4eb1148
fix heartbeat manager typo
spereirag Jul 9, 2020
735237b
Merge tag 'v3.0.0' into develop
sfehlandt Aug 19, 2020
f79c68d
Make heartbeat manager a singleton
spereirag Aug 20, 2020
41f4807
Merge branch 'develop' of github.com:lsst-ts/LOVE-manager into develop
spereirag Aug 20, 2020
77e9f73
Bump cryptography from 2.8 to 3.2 in /manager
dependabot[bot] Oct 27, 2020
5bdc62d
Merge pull request #86 from lsst-ts/dependabot/pip/manager/cryptograp…
spereirag Nov 24, 2020
24645e2
Add love-csc http subapp
Nov 25, 2020
c64b767
Spelling fix
Nov 25, 2020
5994b83
Code refactor
Nov 25, 2020
7439dd1
Merge pull request #87 from lsst-ts/lovecsc-http-refactor
spereirag Dec 14, 2020
140fe78
Add config file model
spereirag Dec 28, 2020
04f06c8
Add config file serializer
spereirag Dec 28, 2020
33c5496
Add config file views
spereirag Dec 28, 2020
9848dce
Fix test typos
spereirag Dec 28, 2020
dcb512d
Add config file test cases
spereirag Dec 28, 2020
ca107e3
Add config files list test
spereirag Dec 29, 2020
c4a1cec
Add configuration files fixture
spereirag Dec 29, 2020
70e1fc1
Remove unused endpoint
spereirag Dec 30, 2020
7664ff4
Update token serializer to read first config file
spereirag Dec 30, 2020
369974a
Remove unused function
spereirag Dec 30, 2020
4911166
Fix old tests
spereirag Dec 30, 2020
7afb314
Include update timestamp in ConfigFileContentSerializer
spereirag Jan 4, 2021
f0d33da
Update default config name
spereirag Jan 4, 2021
41163fb
Remove commented out code
spereirag Jan 4, 2021
7761da8
Update documentation
spereirag Jan 4, 2021
ba4d6d4
Merge pull request #88 from lsst-ts/config-api
spereirag Jan 6, 2021
35f37bd
Fix entrypoints
Jan 7, 2021
37a5a90
Add emergency contact model
spereirag Jan 7, 2021
932bf1d
Add emergency contact endpoint
spereirag Jan 7, 2021
28f2ac1
Add fixture data
spereirag Jan 7, 2021
de5e2b8
Update jenkinsfile to publish documentation
spereirag Jan 7, 2021
8c1638a
Merge pull request #89 from lsst-ts/publish-docs
spereirag Jan 8, 2021
402d7b2
Fix jenkinsfile
spereirag Jan 8, 2021
bd2c280
Update docs source
spereirag Jan 11, 2021
5e2036f
Update docs
spereirag Jan 11, 2021
5a4c595
Merge pull request #90 from lsst-ts/emergency-contacts
spereirag Jan 12, 2021
333fde9
Replace self with cls
spereirag Jan 12, 2021
57f0719
Refactor long function
spereirag Jan 12, 2021
fb654ce
Remove comments
spereirag Jan 12, 2021
448037c
Remove unused variables
spereirag Jan 12, 2021
038aab6
Minor code fixes
spereirag Jan 12, 2021
d3b5656
Add missing HTML metadata
spereirag Jan 12, 2021
c6c1f6e
Cleanup config file tests after running them
spereirag Jan 12, 2021
425cc1a
Merge branch 'develop' into sonarqube-fixes
spereirag Jan 12, 2021
238c9aa
Merge pull request #91 from lsst-ts/sonarqube-fixes
spereirag Jan 18, 2021
f6cf3cb
Add first version of efd endpoint
spereirag Jan 19, 2021
bbca1f8
Add efd test
spereirag Jan 19, 2021
df404d2
Update efd endpoint to POST and lowercase
spereirag Jan 21, 2021
665bb56
Fix EFD test
spereirag Jan 22, 2021
9204208
Update documentation
spereirag Jan 22, 2021
c2cedf0
Black formatter fixes
Jan 26, 2021
1105b6c
Merge pull request #93 from lsst-ts/black-fixes
sebastian-aranda Jan 29, 2021
fac7955
Fix a small error: using self instead of cls
Jan 29, 2021
f83cb1b
Fix merge conflict
Jan 29, 2021
1ae0872
Merge pull request #94 from lsst-ts/microfix-manager-test
sebastian-aranda Jan 29, 2021
335d392
Fix typo
spereirag Feb 2, 2021
dda8a04
Merge branch 'develop' into efd-api
spereirag Feb 2, 2021
bd01edf
Merge pull request #92 from lsst-ts/efd-api
spereirag Feb 2, 2021
6d40508
Include pre-commit config file
Feb 5, 2021
4bd4c93
Add pre-commit instructions to README
Feb 5, 2021
46d0ea2
Merge pull request #95 from lsst-ts/include-pre-commit
sebastian-aranda Feb 8, 2021
a909ebc
Bump cryptography from 3.2 to 3.3.2 in /manager
dependabot[bot] Feb 10, 2021
10db83e
Merge pull request #96 from lsst-ts/dependabot/pip/manager/cryptograp…
spereirag Feb 24, 2021
9898868
Add ignore W503 rule to flake8
Mar 4, 2021
80c000e
Extend messages capacity and reduce expiry time
Mar 4, 2021
470a3f9
Merge pull request #98 from lsst-ts/tickets/LOVE-29
sebastian-aranda Mar 4, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .flake8
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[flake8]
max-line-length = 120
ignore = D100
ignore = D100, W503
16 changes: 16 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: check-yaml
exclude: conda/meta.yaml

- repo: https://github.com/psf/black
rev: 19.10b0
hooks:
- id: black

- repo: https://gitlab.com/pycqa/flake8
rev: 3.7.9
hooks:
- id: flake8
28 changes: 28 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ pipeline {
registryCredential = "dockerhub-inriachile"
dockerImageName = "lsstts/love-manager:"
dockerImage = ""
user_ci = credentials('lsst-io')
LTD_USERNAME="${user_ci_USR}"
LTD_PASSWORD="${user_ci_PSW}"
}

stages {
Expand Down Expand Up @@ -72,6 +75,31 @@ pipeline {
}
}

stage("Deploy documentation") {
agent {
docker {
alwaysPull true
image 'lsstts/develop-env:develop'
args "-u root --entrypoint=''"
}
}
when {
anyOf {
changeset "docs/*"
}
}
steps {
script {
sh "pwd"
sh """
source /home/saluser/.setup_dev.sh
pip install ltd-conveyor
ltd upload --product love-manager --git-ref ${GIT_BRANCH} --dir ./docs
"""
}
}
}

stage("Trigger develop deployment") {
when {
branch "develop"
Expand Down
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,18 @@ Once inside the container you will be in the `/usr/src/love/manager` folder, whe
cd ../docsrc
./create_docs.sh
```

### Linting & Formatting
In order to maintaing code linting and formatting we use `pre-commit` that runs **Flake8** (https://flake8.pycqa.org/) and **Black** (https://github.com/psf/black) using Git Hooks. To enable this you have to:

1. Install `pre-commit` in your local development environment:
```
pip install pre-commit
```

2. Set up the git hook scripts running:
```
pre-commit install
```

3. Start developing! Linter and Formatter will be executed on every commit you make
Binary file modified docs/doctrees/apidoc/api.doctree
Binary file not shown.
Binary file modified docs/doctrees/apidoc/api.tests.doctree
Binary file not shown.
Binary file modified docs/doctrees/apidoc/manager.doctree
Binary file not shown.
Binary file modified docs/doctrees/apidoc/subscription.doctree
Binary file not shown.
Binary file modified docs/doctrees/apidoc/ui_framework.doctree
Binary file not shown.
Binary file modified docs/doctrees/environment.pickle
Binary file not shown.
Binary file modified docs/doctrees/modules/how_it_works.doctree
Binary file not shown.
Binary file modified docs/doctrees/modules/how_to_use_it.doctree
Binary file not shown.
22 changes: 19 additions & 3 deletions docs/html/_sources/apidoc/api.tests.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,14 @@ api.tests.test\_commander module
:undoc-members:
:show-inheritance:

api.tests.test\_lovecsc module
------------------------------

.. automodule:: api.tests.test_lovecsc
:members:
:undoc-members:
:show-inheritance:

api.tests.test\_schema\_validation module
-----------------------------------------

Expand All @@ -28,10 +36,18 @@ api.tests.tests\_auth\_api module
:undoc-members:
:show-inheritance:

api.tests.tests\_config module
------------------------------
api.tests.tests\_configfile module
----------------------------------

.. automodule:: api.tests.tests_configfile
:members:
:undoc-members:
:show-inheritance:

api.tests.tests\_emergencycontact module
----------------------------------------

.. automodule:: api.tests.tests_config
.. automodule:: api.tests.tests_emergencycontact
:members:
:undoc-members:
:show-inheritance:
Expand Down
2 changes: 1 addition & 1 deletion docs/html/_sources/modules/how_it_works.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Code organization

Currently the application is divided in the following modules and files:

* :code:`api`: This module contains the :code:`API` Django app, which defines the models and API endpoints for authentication (:code:`Auth API`) and Commander (:code:`Commander API`) APIs. For more details please refer to the :ref:`ApiDoc` section
* :code:`api`: This module contains the :code:`API` Django app, which defines the models and API endpoints for authentication (:code:`Auth API`), Commander (:code:`Commander API`), ConfigFile (:code:`ConfigFile API`) and EmergencyContact (:code:`EmergencyContact API`) APIs. For more details please refer to the :ref:`ApiDoc` section
* :code:`ui_framework`: This module contains the :code:`UI Framework` Django app, which defines the models and API endpoints for the UI Framework views (:code:`UI Framework API`) API. For more details please refer to the :ref:`ApiDoc` section
* :code:`subscription`: This module contains the Django app that defines the consumers that handle the websocket communication.
* :code:`manager`: This module contains basic Django configuration files, such as urls and channels routing, etc.
Expand Down
4 changes: 2 additions & 2 deletions docs/html/_sources/modules/how_to_use_it.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Returns token, user data and permissions
Validate token
--------------
Validates a given authorization token, passed through HTTP Headers.
Returns a confirmation of validity, user data, permissions, server_time and (optionally) the LOVE configuraiton file.
Returns a confirmation of validity, user data, permissions, server_time and (optionally) the LOVE configuration file.
If the :code:`no_config` flag is added to the end of the URL, then the LOVE config files is not read and the corresponding value is returned as :code:`null`

- Url: :code:`<IP>/manager/api/validate-token/` or :code:`<IP>/manager/api/validate-token/no_config/`
Expand Down Expand Up @@ -119,7 +119,7 @@ If the :code:`no_config` flag is added to the end of the URL, then the LOVE conf
Swap token
--------------
Validates a given authorization token, passed through HTTP Headers.
Returns a confirmation of validity, user data, permissions, server_time and (optionally) the LOVE configuraiton file.
Returns a confirmation of validity, user data, permissions, server_time and (optionally) the LOVE configuration file.
If the :code:`no_config` flag is added to the end of the URL, then the LOVE config files is not read and the corresponding value is returned as :code:`null`

- Url: :code:`<IP>/manager/api/swap-token/` or :code:`<IP>/manager/api/swap-token/no_config/`
Expand Down
Loading