Skip to content

Commit

Permalink
Merge branch 'release-v1.54.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
aws-sam-cli-bot committed Nov 10, 2022
2 parents b534773 + 93ed570 commit 9c90df7
Show file tree
Hide file tree
Showing 1,891 changed files with 145,872 additions and 138,969 deletions.
12 changes: 6 additions & 6 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
*Issue #, if available:*
### Issue #, if available

*Description of changes:*
### Description of changes

*Description of how you validated changes:*
### Description of how you validated changes

*Checklist:*
### Checklist

- [ ] Adheres to the [development guidelines](https://github.com/aws/serverless-application-model/blob/develop/DEVELOPMENT_GUIDE.md#development-guidelines)
- [ ] Add/update [unit tests](https://github.com/aws/serverless-application-model/blob/develop/DEVELOPMENT_GUIDE.md#unit-testing-with-multiple-python-versions) using:
- [ ] Correct values
- [ ] Bad/wrong values (None, empty, wrong type, length, etc.)
- [ ] [Intrinsic Functions](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference.html)
- [ ] Add/update [integration tests](https://github.com/aws/serverless-application-model/blob/develop/INTEGRATION_TESTS.md)
- [ ] `make pr` passes
- [ ] Update documentation
- [ ] Verify transformed template deploys and application functions as expected
- [ ] Do these changes include any template validations?
- [ ] Did the newly validated properties support intrinsics prior to adding the validations? (If unsure, please review [Intrinsic Functions](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/intrinsic-function-reference.html) before proceeding).
- [ ] Does the pull request ensure that intrinsics remain functional with the new validations?

*Examples?*
### Examples?

Please reach out in the comments, if you want to add an example. Examples will be
added to `sam init` through https://github.com/awslabs/aws-sam-cli-app-templates/
Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Tests

on:
push:
branches:
- develop
pull_request:
branches:
- develop

jobs:
build:
name: ${{ matrix.os }} / ${{ matrix.python }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
python:
- "3.7"
- "3.8"
- "3.9"
- "3.10"
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- run: make init
- run: make pr
74 changes: 74 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ "develop" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "develop" ]
schedule:
- cron: '43 23 * * 2'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'python' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality


# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:${{matrix.language}}"
2 changes: 2 additions & 0 deletions .gitpod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
tasks:
- init: make init
96 changes: 1 addition & 95 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,6 @@ unsafe-load-any-extension=no
# run arbitrary code
extension-pkg-whitelist=

# Allow optimization of some AST trees. This will activate a peephole AST
# optimizer, which will apply various small optimizations. For instance, it can
# be used to obtain the result of joining multiple strings with the addition
# operator. Joining a lot of strings can lead to a maximum recursion error in
# Pylint and this flag can prevent that. It has one side effect, the resulting
# AST will be different than the one from reality.
optimize-ast=no


[MESSAGES CONTROL]

Expand All @@ -65,56 +57,31 @@ confidence=
# no Warning level messages displayed, use"--disable=all --enable=classes
# --disable=W"
disable=
C0209, # consider-using-f-string. There are too many of them
W0613, # Unused argument %r
W0640, # Cell variable %s defined in loop A variable used in a closure is defined in a loop
R0902, # Too many instance attributes (%s/%s)
R0903, # Too few public methods (%s/%s)
R0913, # Too many arguments (%s/%s)
W0703, # Catching too general exception %s
R0904, # Too many public methods (%s/%s)
R0914, # Too many local variables (%s/%s)
R0915, # Too many statements
C0415, # Import outside toplevel (%s) Used when an import statement is used anywhere other than the module toplevel. Move this import to the top of the file.
C0115, # missing-class-docstring
# below are docstring lint rules, in order to incrementally improve our docstring while
# without introduce too much effort at a time, we exclude most of the docstring lint rules.
# We will remove them one by one.
# W9005, # "%s" has constructor parameters documented in class and __init__
W9006, # "%s" not documented as being raised
# W9008, # Redundant returns documentation
# W9010, # Redundant yields documentation
W9011, # Missing return documentation
W9012, # Missing return type documentation
# W9013, # Missing yield documentation
# W9014, # Missing yield type documentation
# W9015, # "%s" missing in parameter documentation
W9016, # "%s" missing in parameter type documentation
# W9017, # "%s" differing in parameter documentation
# W9018, # "%s" differing in parameter type documentation
# W9019, # "%s" useless ignored parameter documentation
# W9020, # "%s" useless ignored parameter type documentation
# Constant name style warnings. We will remove them one by one.
C0103, # Class constant name "%s" doesn't conform to UPPER_CASE naming style ('([^\\W\\da-z][^\\Wa-z]*|__.*__)$' pattern) (invalid-name)
# New recommendations, disable for now to avoid introducing behaviour changes.
R1729, # Use a generator instead '%s' (use-a-generator)
R1732, # Consider using 'with' for resource-allocating operations (consider-using-with)
# This applies to CPython only.
I1101, # Module 'math' has no 'pow' member, but source is unavailable. Consider adding this module to extension-pkg-allow-list if you want to perform analysis based on run-time introspection of living objects. (c-extension-no-member)
# Added to allow linting. Need to work on removing over time
R0801, # dupilcated code
R0401, # Cyclic import
C0411, # import ordering
W9015, # missing parameter in doc strings
W0612, # unused variable
R0205, # useless-object-inheritanc
C0301, # line to long
R0201, # no self use, method could be a function
C0114, # missing-module-docstring
W1202, # Use lazy % formatting in logging functions (logging-format-interpolation)
E1101, # No member
W0622, # Redefining built-in 'property' (redefined-builtin)
W0611, # unused imports
W0231, # super not called
W0212, # protected-access
W0201, # attribute-defined-outside-init
R1725, # Consider using Python 3 style super() without arguments (super-with-arguments)
Expand All @@ -125,8 +92,6 @@ disable=
W0223, # abstract-method
W0107, # unnecessary-pass
W0707, # raise-missing-from
R1720, # no-else-raise
W0621, # redefined-outer-name
E0203, # access-member-before-definition
W0221, # arguments-differ
R1710, # inconsistent-return-statements
Expand All @@ -135,32 +100,14 @@ disable=
W0105, # String statement has no effect (pointless-string-statement)
C0206, # Consider iterating with .items() (consider-using-dict-items)
W9008, # Redundant returns documentation (redundant-returns-doc)
E0602, # undefined-variable
C0112, # empty-docstring
C0116, # missing-function-docstring
C0200, # consider-using-enumerate
R5501, # Consider using "elif" instead of "else if" (else-if-used)
W9017, # differing-param-doc
W9018, # differing-type-doc
W0511, # fixme
C0325, # superfluous-parens
R1701, # consider-merging-isinstance
C0302, # too-many-lines
C0303, # trailing-whitespace
R1721, # unnecessary-comprehension
C0121, # singleton-comparison
E1305, # too-many-format-args
R1724, # no-else-continue
E0611, # no-name-in-module
W9013, # missing-yield-doc
W9014, # missing-yield-type-doc
C0201, # consider-iterating-dictionary
W0237, # arguments-renamed
R1718, # consider-using-set-comprehension
R1723, # no-else-break
E1133, # not-an-iterable
E1135, # unsupported-membership-test
R1705, # no-else-return


[REPORTS]
Expand All @@ -170,11 +117,6 @@ disable=
# mypackage.mymodule.MyReporterClass.
output-format=text

# Put messages in a separate file for each module / package specified on the
# command line instead of printing them on stdout. Reports (if any) will be
# written in a file name "pylint_global.[txt|html]".
files-output=no

# Tells whether to display a full report or only the messages
reports=no

Expand All @@ -192,9 +134,6 @@ evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / stateme

[BASIC]

# List of builtins function names that should not be used, separated by a comma
bad-functions=apply,reduce

# Good variable names which should always be accepted, separated by a comma
good-names=e,i,j,k,n,ex,Run,_

Expand All @@ -211,63 +150,33 @@ include-naming-hint=yes
# Regular expression matching correct function names
function-rgx=[a-z_][a-z0-9_]{2,50}$

# Naming hint for function names
function-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression matching correct variable names
variable-rgx=[a-z_][a-z0-9_]{0,50}$

# Naming hint for variable names
variable-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression matching correct constant names
const-rgx=(([a-zA-Z_][a-zA-Z0-9_]*)|(__.*__))$

# Naming hint for constant names
const-name-hint=(([A-Z_][A-Z0-9_]*)|(__.*__))$

# Regular expression matching correct attribute names
attr-rgx=[a-z_][a-z0-9_]{1,50}$

# Naming hint for attribute names
attr-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression matching correct argument names
argument-rgx=[a-z_][a-z0-9_]{0,50}$

# Naming hint for argument names
argument-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression matching correct class attribute names
class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$

# Naming hint for class attribute names
class-attribute-name-hint=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$

# Regular expression matching correct inline iteration names
inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$

# Naming hint for inline iteration names
inlinevar-name-hint=[A-Za-z_][A-Za-z0-9_]*$

# Regular expression matching correct class names
class-rgx=[A-Z_][a-zA-Z0-9]+$

# Naming hint for class names
class-name-hint=[A-Z_][a-zA-Z0-9]+$

# Regular expression matching correct module names
module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$

# Naming hint for module names
module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$

# Regular expression matching correct method names
method-rgx=[a-z_][a-z0-9_]{2,50}$

# Naming hint for method names
method-name-hint=[a-z_][a-z0-9_]{2,30}$

# Regular expression which should only match function or class names that do
# not require a docstring.
no-docstring-rgx=^_
Expand All @@ -291,9 +200,6 @@ ignore-long-lines=^\s*(# )?<?https?://\S+>?$
# else.
single-line-if-stmt=no

# List of optional constructs for which whitespace checking is disabled
no-space-check=trailing-comma,dict-separator

# Maximum number of lines in a module
max-module-lines=1000

Expand Down
Loading

0 comments on commit 9c90df7

Please sign in to comment.