Skip to content

Commit 22e6239

Browse files
authored
Merge branch 'master' into deprecated-pythons-test
2 parents 05612fa + 39e4e85 commit 22e6239

File tree

9 files changed

+35
-2
lines changed

9 files changed

+35
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
# Master
44

5+
- Add support for Python 3.8 branch
56
- Sqlite3 Update:
67
- Test Improvements
78
- Add support for staging binary testing

bin/compile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export VENDOR_URL
5252
source "$BIN_DIR/default_pythons"
5353

5454
# Supported Python Branches
55+
PY38="python-3.8"
5556
PY37="python-3.7"
5657
PY36="python-3.6"
5758
PY35="python-3.5"

bin/default_pythons

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
#!/usr/bin/env bash
22

33
DEFAULT_PYTHON_VERSION="python-3.6.9"
4+
LATEST_38="python-3.8.0"
5+
LATEST_37="python-3.7.5"
46
LATEST_36="python-3.6.9"
5-
LATEST_37="python-3.7.4"
67
LATEST_35="python-3.5.7"
78
LATEST_34="python-3.4.10"
89
LATEST_27="python-2.7.16"
910

10-
export DEFAULT_PYTHON_VERSION LATEST_37 LATEST_36 LATEST_35 LATEST_34 LATEST_27
11+
export DEFAULT_PYTHON_VERSION LATEST_38 LATEST_37 LATEST_36 LATEST_35 LATEST_34 LATEST_27

bin/steps/python

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,13 @@ SECURITY_UPDATE="Python has released a security update! Please consider upgradin
1111

1212
# check if runtime exists
1313
if curl --output /dev/null --silent --head --fail "$VENDORED_PYTHON"; then
14+
if [[ "$PYTHON_VERSION" == $PY38* ]]; then
15+
# do things to alert the user of security release available
16+
if [ "$PYTHON_VERSION" != "$LATEST_38" ]; then
17+
puts-warn "$SECURITY_UPDATE" "$LATEST_38"
18+
echo " Learn More: https://devcenter.heroku.com/articles/python-runtimes"
19+
fi
20+
fi
1421
if [[ "$PYTHON_VERSION" == $PY37* ]]; then
1522
# do things to alert the user of security release available
1623
if [ "$PYTHON_VERSION" != "$LATEST_37" ]; then
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
requests

test/fixtures/python3_8/runtime.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
python-3.8.0
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
flask
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
python-3.8.99

test/run-versions

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,25 @@ testPython3_7_fail() {
142142
assertCapturedError
143143
}
144144

145+
testPython3_8() {
146+
updateVersion "python3_8" $LATEST_38
147+
compile "python3_8"
148+
if [[ $STACK = "cedar-14" ]]; then
149+
assertCapturedError
150+
else
151+
assertNotCaptured "security update"
152+
assertCaptured $LATEST_38
153+
assertCaptured "Installing SQLite3"
154+
assertCapturedSuccess
155+
fi
156+
}
157+
158+
testPython3_8_fail() {
159+
compile "python3_8_fail"
160+
assertCaptured "Aborting"
161+
assertCapturedError
162+
}
163+
145164
pushd $(dirname 0) >/dev/null
146165
popd >/dev/null
147166

0 commit comments

Comments
 (0)