Skip to content
This repository was archived by the owner on Jun 30, 2021. It is now read-only.

Commit 687ce74

Browse files
author
Lu Hong
committed
Change handlers.handle_request to handlers.publish
1 parent 05a133c commit 687ce74

File tree

4 files changed

+101
-8
lines changed

4 files changed

+101
-8
lines changed

.gitignore

Lines changed: 98 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,105 @@
11
# Byte-compiled / optimized / DLL files
2-
*__pycache__/
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
9+
# Distribution / packaging
10+
.Python
11+
build/
12+
develop-eggs/
13+
dist/
14+
downloads/
15+
eggs/
16+
.eggs/
17+
lib/
18+
lib64/
19+
parts/
20+
sdist/
21+
var/
22+
wheels/
23+
*.egg-info/
24+
.installed.cfg
25+
*.egg
26+
MANIFEST
27+
.idea*
28+
29+
# PyInstaller
30+
# Usually these files are written by a python script from a template
31+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
32+
*.manifest
33+
*.spec
34+
35+
# Installer logs
36+
pip-log.txt
37+
pip-delete-this-directory.txt
338

439
# Unit test / coverage reports
40+
htmlcov/
41+
.tox/
542
.coverage
43+
.coverage.*
44+
.cache
45+
nosetests.xml
46+
coverage.xml
47+
*.cover
48+
.hypothesis/
649
.pytest_cache/
750

8-
# IDE
9-
.idea*
51+
# Translations
52+
*.mo
53+
*.pot
1054

11-
# Distribution / packaging
12-
dist/
55+
# Django stuff:
56+
*.log
57+
local_settings.py
58+
db.sqlite3
59+
60+
# Flask stuff:
61+
instance/
62+
.webassets-cache
63+
64+
# Scrapy stuff:
65+
.scrapy
66+
67+
# Sphinx documentation
68+
docs/_build/
69+
70+
# PyBuilder
71+
target/
72+
73+
# Jupyter Notebook
74+
.ipynb_checkpoints
75+
76+
# pyenv
77+
.python-version
78+
79+
# celery beat schedule file
80+
celerybeat-schedule
81+
82+
# SageMath parsed files
83+
*.sage.py
84+
85+
# Environments
86+
.env
87+
.venv
88+
env/
89+
venv/
90+
ENV/
91+
env.bak/
92+
venv.bak/
93+
94+
# Spyder project settings
95+
.spyderproject
96+
.spyproject
97+
98+
# Rope project settings
99+
.ropeproject
100+
101+
# mkdocs documentation
102+
/site
103+
104+
# mypy
105+
.mypy_cache/

app/handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
LOGGER = log_helper.getLogger(__name__)
77

88

9-
def handle_request(request, context):
9+
def publish(request, context):
1010
"""Publish to Serverless Apps Repo.
1111
1212
CodePipeline invokes the lambda to publish an application

app/log_helper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99

1010
# intentionally breaking naming convention to match logger.getLogger()
11-
def getLogger(name): # pylint: disable=invalid-name
11+
def getLogger(name):
1212
"""Initialize logger with given name.
1313
1414
Sets log level based on configured value.

test/unit/test_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44

55

66
def test_handle_request():
7-
handlers.handle_requeset({}, None)
7+
handlers.publish({}, None)

0 commit comments

Comments
 (0)