Skip to content

fix: adding .lower() so new Pandas dtypes will match the type lookup. #3740

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 9, 2023
Merged

fix: adding .lower() so new Pandas dtypes will match the type lookup. #3740

merged 4 commits into from
May 9, 2023

Conversation

brifordwylie
Copy link
Contributor

Issue #2868

Description of changes:
Added .lower() after Pandas dtype string cast, so that the new Pandas dtypes (which start with capitals e.g… Int64) will match the type lookup.

Testing done:
Unit tests: tox tests/unit

I'm not sure why 3 of the tests failed.. :(

FAILED tests/unit/sagemaker/jumpstart/test_cache.py::test_jumpstart_local_metadata_override_header - AssertionError: Expected 'open...
FAILED tests/unit/sagemaker/jumpstart/test_cache.py::test_jumpstart_local_metadata_override_specs - botocore.exceptions.ConfigParse...
FAILED tests/unit/sagemaker/jumpstart/test_cache.py::test_jumpstart_local_metadata_override_specs_not_exist_both_directories - Asse...
======================== 3 failed, 8511 passed, 3489 skipped, 3 xpassed, 3558 warnings

Merge Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your pull request.

General

  • I have read the CONTRIBUTING doc
  • I certify that the changes I am introducing will be backward compatible, and I have discussed concerns about this, if any, with the Python SDK team
  • I used the commit message format described in CONTRIBUTING
  • I have passed the region in to all S3 and STS clients that I've initialized as part of this change.
  • I have updated any necessary documentation, including READMEs and API docs (if appropriate)

Tests

  • I have added tests that prove my fix is effective or that my feature works (if appropriate)
  • I have added unit and/or integration tests as appropriate to ensure backward compatibility of the changes
  • I have checked that my tests are not configured for a specific region or account (if appropriate)
  • I have used unique_name_from_base to create resource names in integ tests (if appropriate)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

…Caps (e.g. Int64), will match the type lookup
@brifordwylie brifordwylie requested a review from a team as a code owner March 21, 2023 19:55
@brifordwylie brifordwylie requested review from mufaddal-rohawala and removed request for a team March 21, 2023 19:55
@brifordwylie brifordwylie changed the title fix: adding .lower() so that the new Pandas dtypes, which start with … fix: adding .lower() so new Pandas dtypes will match the type lookup. Mar 21, 2023
Copy link
Member

@mufaddal-rohawala mufaddal-rohawala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/bot run all

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-pr
  • Commit ID: ab4be8d
  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-unit-tests
  • Commit ID: ab4be8d
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-local-mode-tests
  • Commit ID: ab4be8d
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@codecov-commenter
Copy link

codecov-commenter commented Mar 22, 2023

Codecov Report

Merging #3740 (8ddb5a6) into master (4844aa1) will decrease coverage by 0.64%.
The diff coverage is n/a.

❗ Current head 8ddb5a6 differs from pull request most recent head 590e3a9. Consider uploading reports for the commit 590e3a9 to get more accurate results

@@            Coverage Diff             @@
##           master    #3740      +/-   ##
==========================================
- Coverage   89.71%   89.07%   -0.64%     
==========================================
  Files        1060      231     -829     
  Lines      101652    22846   -78806     
==========================================
- Hits        91193    20351   -70842     
+ Misses      10459     2495    -7964     
Impacted Files Coverage Δ
src/sagemaker/feature_store/feature_group.py 74.78% <ø> (ø)

... and 1290 files with indirect coverage changes

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-notebook-tests
  • Commit ID: ab4be8d
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-slow-tests
  • Commit ID: ab4be8d
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@brifordwylie
Copy link
Contributor Author

@mufaddal-rohawala thanks for the approval... I'm assuming one of the SDK devs will merge it in when they get a chance... big thanks to all the folks putting effort into this package, it's super nice.

@brifordwylie
Copy link
Contributor Author

I hate to bug.. but I have a downstream project that relies on this fix, could some nice person merge this when they get a chance? @mufaddal-rohawala

@mufaddal-rohawala mufaddal-rohawala self-assigned this Mar 25, 2023
Copy link
Member

@mufaddal-rohawala mufaddal-rohawala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/bot run all

@mufaddal-rohawala
Copy link
Member

@brifordwylie thanks for contributing. I'l get this PR merged by tomorrow. Please dont update from master to avoid PR check reruns.

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-unit-tests
  • Commit ID: 8ddb5a6
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-local-mode-tests
  • Commit ID: 8ddb5a6
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-pr
  • Commit ID: 8ddb5a6
  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-notebook-tests
  • Commit ID: 8ddb5a6
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-slow-tests
  • Commit ID: 8ddb5a6
  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

Copy link
Member

@mufaddal-rohawala mufaddal-rohawala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/bot run all

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-pr
  • Commit ID: 590e3a9
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-slow-tests
  • Commit ID: 590e3a9
  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-local-mode-tests
  • Commit ID: 590e3a9
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-notebook-tests
  • Commit ID: 590e3a9
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@sagemaker-bot
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: sagemaker-python-sdk-unit-tests
  • Commit ID: 590e3a9
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mufaddal-rohawala mufaddal-rohawala merged commit 79795af into aws:master May 9, 2023
@brifordwylie brifordwylie deleted the pandas_dtypes_lower_fix branch May 10, 2023 20:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FeatureGroup _INTEGER_TYPES attribute incompatible with pandas 1.1.5 dtypes.
4 participants