Skip to content
This repository has been archived by the owner on Jul 3, 2023. It is now read-only.

Commit

Permalink
Removes python3.6 support
Browse files Browse the repository at this point in the history
  • Loading branch information
elijahbenizzy committed Jan 30, 2023
1 parent abb2f46 commit 7f53f88
Show file tree
Hide file tree
Showing 8 changed files with 5 additions and 34 deletions.
12 changes: 0 additions & 12 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ jobs:
workflows:
unit-test-workflow:
jobs:
- test:
name: build-py36
python-version: '3.6'
task: tests
- test:
name: build-py37
python-version: '3.7'
Expand All @@ -49,10 +45,6 @@ workflows:
name: pre-commit
python-version: '3.9'
task: pre-commit
- test:
name: dask-py36
python-version: '3.6'
task: dask
- test:
name: dask-py37
python-version: '3.7'
Expand All @@ -65,10 +57,6 @@ workflows:
name: spark-py38
python-version: '3.8'
task: pyspark
- test:
name: integrations-py36
python-version: '3.6'
task: integrations
- test:
name: integrations-py37
python-version: '3.7'
Expand Down
2 changes: 1 addition & 1 deletion build_conda.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ CONDA_HOME=$HOME/anaconda3
# conda activate && anaconda login
pkg='sf-hamilton'
# adjust the Python versions you would like to build
array=( 3.6 3.7 3.8 3.9 3.10 3.11 )
array=(3.7 3.8 3.9 3.10 3.11 )
echo "Building conda package ..."
cd ~
# this will create a ~/sf-hamilton directory with metadata to build the package.
Expand Down
11 changes: 3 additions & 8 deletions graph_adapter_tests/h_async/test_h_async.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,13 +82,8 @@ async def test_driver_end_to_end_telemetry(send_event_json):
}
# to ensure the last telemetry invocation finishes executing
# get all tasks -- and the current task, and await all others.
try:
# only works for 3.7+
tasks = asyncio.all_tasks()
current_task = asyncio.current_task()
await asyncio.gather(*[t for t in tasks if t != current_task])
except AttributeError:
# required for 3.6
await asyncio.sleep(1)
tasks = asyncio.all_tasks()
current_task = asyncio.current_task()
await asyncio.gather(*[t for t in tasks if t != current_task])
assert send_event_json.called
assert len(send_event_json.call_args_list) == 2
3 changes: 0 additions & 3 deletions graph_adapter_tests/h_dask/test_h_dask.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import sys

import pandas as pd
import pytest
from dask.delayed import delayed
Expand Down Expand Up @@ -46,7 +44,6 @@ def test_dask_graph_adapter_simple(client):
# TODO: do some more asserting?


@pytest.mark.skipif(sys.version_info < (3, 7), reason="requires python3.7")
def test_smoke_screen_module(client):
config = {"region": "US"}
dr = driver.Driver(config, smoke_screen_module, adapter=h_dask.DaskGraphAdapter(client))
Expand Down
6 changes: 1 addition & 5 deletions hamilton/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,8 @@ def index_key_name(pd_object: Union[pd.DataFrame, pd.Series]) -> str:

def get_parent_time_index_type():
"""Helper to pull the right time index parent class."""
if hasattr(
pd_extension, "NDArrayBackedExtensionIndex"
): # for python 3.7+ & pandas >= 1.2
if hasattr(pd_extension, "NDArrayBackedExtensionIndex"):
index_type = pd_extension.NDArrayBackedExtensionIndex
elif hasattr(pd_extension, "ExtensionIndex"): # for python 3.6 & pandas <= 1.2
index_type = pd_extension.ExtensionIndex
else:
index_type = None # weird case, but not worth breaking for.
return index_type
Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
dataclasses; python_version < '3.7'
numpy
pandas
typing_inspect
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ def load_requirements():
"Natural Language :: English",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
Expand Down
3 changes: 0 additions & 3 deletions tests/test_end_to_end.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import sys

import pytest

import hamilton.driver
Expand Down Expand Up @@ -34,7 +32,6 @@ def test_data_quality_workflow_fails():
)


@pytest.mark.skipif(sys.version_info < (3, 7), reason="requires python3.7")
def test_smoke_screen_module():
config = {"region": "US"}
dr = hamilton.driver.Driver(config, tests.resources.smoke_screen_module)
Expand Down

0 comments on commit 7f53f88

Please sign in to comment.