Skip to content

Commit 14192f8

Browse files
authored
Merge branch 'main' into ignore-temp-dir
2 parents 62f25fd + d0afe92 commit 14192f8

195 files changed

Lines changed: 4236 additions & 435 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.eslintrc.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,18 @@
1818
"import/no-amd": "error",
1919
"import/no-commonjs": "error",
2020
"import/no-dynamic-require": "error",
21-
"import/no-extraneous-dependencies": ["error", {"devDependencies": false}],
21+
"import/no-extraneous-dependencies": ["error"],
2222
"import/no-namespace": "off",
2323
"import/no-unresolved": "error",
2424
"import/no-webpack-loader-syntax": "error",
25+
"import/order": ["error", {
26+
"alphabetize": {"order": "asc"},
27+
"newlines-between": "always"
28+
}],
2529
"no-async-foreach/no-async-foreach": "error",
2630
"no-console": "off",
2731
"no-sequences": "error",
28-
"one-var": ["error", "never"],
29-
"sort-imports": ["error", { "allowSeparatedGroups": true }]
32+
"one-var": ["error", "never"]
3033
},
3134
"overrides": [{
3235
// "temporarily downgraded during transition to eslint
@@ -46,9 +49,7 @@
4649
"@typescript-eslint/restrict-template-expressions": "off",
4750
"func-style": "off",
4851
"github/no-then": "off",
49-
"import/no-extraneous-dependencies": "off",
50-
"no-shadow": "off",
51-
"sort-imports": "off"
52+
"no-shadow": "off"
5253
}
5354
}]
5455
}

.github/workflows/python-deps.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: Test Python Package Installation
2+
3+
on:
4+
push:
5+
branches: [main, v1]
6+
pull_request:
7+
8+
jobs:
9+
10+
test-setup-python-scripts:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
include:
16+
- test_dir: python-setup/tests/pipenv/requests-2
17+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 2
18+
- test_dir: python-setup/tests/pipenv/requests-3
19+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 3
20+
21+
- test_dir: python-setup/tests/poetry/requests-2
22+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 2
23+
- test_dir: python-setup/tests/poetry/requests-3
24+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 3
25+
26+
- test_dir: python-setup/tests/requirements/requests-2
27+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 2
28+
- test_dir: python-setup/tests/requirements/requests-3
29+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 3
30+
31+
- test_dir: python-setup/tests/setup_py/requests-2
32+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 2
33+
- test_dir: python-setup/tests/setup_py/requests-3
34+
test_script: $GITHUB_WORKSPACE/python-setup/tests/check_requests_123.sh 3
35+
36+
# This one shouldn't fail, but also won't install packages
37+
- test_dir: python-setup/tests/requirements/non-standard-location
38+
test_script: test -z $LGTM_INDEX_IMPORT_PATH
39+
40+
steps:
41+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
42+
- uses: actions/checkout@v2
43+
44+
- name: Initialize CodeQL
45+
uses: github/codeql-action/init@v1
46+
with:
47+
languages: python
48+
49+
- name: Test Auto Package Installation
50+
run: |
51+
set -x
52+
$GITHUB_WORKSPACE/python-setup/install_tools.sh
53+
echo -e '\n\n\n\n\n' && sleep 0.5
54+
cd $GITHUB_WORKSPACE/${{ matrix.test_dir }}
55+
find /opt/hostedtoolcache/CodeQL -path "*x64/codeql" -exec $GITHUB_WORKSPACE/python-setup/auto_install_packages.py {} \;
56+
- name: Setup for extractor
57+
run: |
58+
echo $CODEQL_PYTHON
59+
# only run if $CODEQL_PYTHON is set
60+
test ! -z $CODEQL_PYTHON && $GITHUB_WORKSPACE/python-setup/tests/from_python_exe.py $CODEQL_PYTHON || /bin/true
61+
- name: Verify packages installed
62+
run: |
63+
${{ matrix.test_script }}

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,15 @@ on:
2222
push:
2323
pull_request:
2424
schedule:
25+
# ┌───────────── minute (0 - 59)
26+
# │ ┌───────────── hour (0 - 23)
27+
# │ │ ┌───────────── day of the month (1 - 31)
28+
# │ │ │ ┌───────────── month (1 - 12 or JAN-DEC)
29+
# │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT)
30+
# │ │ │ │ │
31+
# │ │ │ │ │
32+
# │ │ │ │ │
33+
# * * * * *
2534
- cron: '0 0 * * 0'
2635

2736
jobs:

init/action.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ inputs:
1919
queries:
2020
description: Comma-separated list of additional queries to run. By default, this overrides the same setting in a configuration file; prefix with "+" to use both sets of queries.
2121
required: false
22+
setup-python-dependencies:
23+
description: Try to auto-install your python dependencies
24+
required: true
25+
default: 'true'
2226
runs:
2327
using: 'node12'
2428
main: '../lib/init-action.js'

lib/actions-util.js

Lines changed: 11 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/actions-util.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)