Skip to content

feat: support newer GetQueryExecution response fields#708

Merged
laughingman7743 merged 1 commit into
masterfrom
feature/add-newer-query-execution-fields
May 24, 2026
Merged

feat: support newer GetQueryExecution response fields#708
laughingman7743 merged 1 commit into
masterfrom
feature/add-newer-query-execution-fields

Conversation

@laughingman7743
Copy link
Copy Markdown
Member

WHAT

Add the following fields to AthenaQueryExecution in pyathena/model.py, all introduced to the GetQueryExecution response since the class was last extended:

Statistics:

  • service_pre_processing_time_in_millisServicePreProcessingTimeInMillis (botocore 1.32.3)
  • dpu_countDpuCount, per-query DPU usage exposed alongside the 2025-11 Capacity Reservations enhancements (botocore 1.41.2)

Top-level configuration:

  • managed_query_results_enabled / managed_query_results_kms_keyManagedQueryResultsConfiguration for the Managed Query Results feature released 2025-06 (botocore 1.38.28)
  • enable_s3_access_grants / create_user_level_prefix / s3_access_grants_authentication_typeQueryResultsS3AccessGrantsConfiguration for S3 Access Grants integration

Also bumps boto3>=1.38.2 and botocore>=1.41.2 (Nov 2025 releases) so all new fields are actually populated by the SDK.

WHY

These fields are returned by current boto3 versions but PyAthena was silently dropping them. Exposing them improves observability (extra timing buckets, DPU usage) and unblocks users adopting Managed Query Results and S3 Access Grants.

The lower-bound bump is conservative: without it the new properties would silently return None even when the user has the latest SDK and Athena returns the data. Tying the floor to the SDK release that actually serves DpuCount keeps the contract honest.

Closes #707

Add the following fields to AthenaQueryExecution, all introduced to the
GetQueryExecution response over the past two years and not previously
exposed by PyAthena:

Statistics:
- service_pre_processing_time_in_millis
- dpu_count

Top-level:
- managed_query_results_enabled / managed_query_results_kms_key
- enable_s3_access_grants / create_user_level_prefix /
  s3_access_grants_authentication_type

Bump boto3 to >=1.38.2 and botocore to >=1.41.2 (Nov 2025) so that all
new fields are actually populated by the SDK. Earlier versions would
silently return None for the newest field (DpuCount), which would be
misleading.

Refs #707
@laughingman7743 laughingman7743 marked this pull request as ready for review May 24, 2026 04:53
@laughingman7743 laughingman7743 merged commit 7a6326f into master May 24, 2026
15 checks passed
@laughingman7743 laughingman7743 deleted the feature/add-newer-query-execution-fields branch May 24, 2026 04:53
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.

Add support for newer GetQueryExecution response fields in AthenaQueryExecution

1 participant