Repository: dbt-labs/dbt-core

Issue:
Remove py36 support
Python 3.6 end of life is December 23. We're planning to release major version v1.0 in December. For clarity and ease of support, let's remove official support for python 3.6 ahead of v1.0.

I think this looks like:
- Turning off py36 tests
- Bumping `python_requires` for `dbt-core`

Removal of related cruft (e.g. backported `dataclasses`) can come later


Discussion:
This should be done for all database adapter packages as well. Additionally, please update classifiers listed in all `setup.py` files (https://pypi.org/classifiers).

Resolving patch:
diff --git a/core/setup.py b/core/setup.py
--- a/core/setup.py
+++ b/core/setup.py
@@ -2,9 +2,9 @@
 import os
 import sys
 
-if sys.version_info < (3, 6):
+if sys.version_info < (3, 7):
     print('Error: dbt does not support this version of Python.')
-    print('Please upgrade to Python 3.6 or higher.')
+    print('Please upgrade to Python 3.7 or higher.')
     sys.exit(1)
 
 
@@ -55,7 +55,6 @@
         'agate>=1.6,<1.6.4',
         'click>=8,<9',
         'colorama>=0.3.9,<0.4.5',
-        'dataclasses>=0.6,<0.9;python_version<"3.7"',
         'hologram==0.0.14',
         'isodate>=0.6,<0.7',
         'logbook>=1.5,<1.6',
@@ -82,10 +81,9 @@
         'Operating System :: MacOS :: MacOS X',
         'Operating System :: POSIX :: Linux',
 
-        'Programming Language :: Python :: 3.6',
         'Programming Language :: Python :: 3.7',
         'Programming Language :: Python :: 3.8',
         'Programming Language :: Python :: 3.9',
     ],
-    python_requires=">=3.6.3",
+    python_requires=">=3.7",
 )
diff --git a/plugins/postgres/setup.py b/plugins/postgres/setup.py
--- a/plugins/postgres/setup.py
+++ b/plugins/postgres/setup.py
@@ -2,9 +2,9 @@
 import os
 import sys
 
-if sys.version_info < (3, 6):
+if sys.version_info < (3, 7):
     print('Error: dbt does not support this version of Python.')
-    print('Please upgrade to Python 3.6 or higher.')
+    print('Please upgrade to Python 3.7 or higher.')
     sys.exit(1)
 
 
@@ -82,10 +82,9 @@ def _dbt_psycopg2_name():
         'Operating System :: MacOS :: MacOS X',
         'Operating System :: POSIX :: Linux',
 
-        'Programming Language :: Python :: 3.6',
         'Programming Language :: Python :: 3.7',
         'Programming Language :: Python :: 3.8',
         'Programming Language :: Python :: 3.9',
     ],
-    python_requires=">=3.6.2",
+    python_requires=">=3.7",
 )
diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -14,9 +14,9 @@
     sys.exit(1)
 
 
-if sys.version_info < (3, 6):
+if sys.version_info < (3, 7):
     print('Error: dbt does not support this version of Python.')
-    print('Please upgrade to Python 3.6 or higher.')
+    print('Please upgrade to Python 3.7 or higher.')
     sys.exit(1)
 
 
@@ -62,10 +62,9 @@
         'Operating System :: MacOS :: MacOS X',
         'Operating System :: POSIX :: Linux',
 
-        'Programming Language :: Python :: 3.6',
         'Programming Language :: Python :: 3.7',
         'Programming Language :: Python :: 3.8',
         'Programming Language :: Python :: 3.9',
     ],
-    python_requires=">=3.6.2",
+    python_requires=">=3.7",
 )


Test patch: