Skip to content

Conversation

@eduardoChaucaGallegoseduardoChaucaGallegos requested a review from a teamJuly 10, 2025 16:01
@eduardoChaucaGallegoseduardoChaucaGallegos changed the title SG 38306 Python2 removal six and ensure_ functionsSG 38306 Python2 removal six and ensure_ functions, httplib2Jul 10, 2025
Copy link
Contributor

Choose a reason for hiding this comment

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

Just a small proposal.

@eduardoChaucaGallegoseduardoChaucaGallegosforce-pushed the SG-38306-python2-removal-six branch 2 times, most recently from 72a8750 to 733f058CompareJuly 15, 2025 17:22
@julien-langjulien-lang changed the title SG 38306 Python2 removal six and ensure_ functions, httplib2SG-38306 Python2 Removal - Part 1 - six and ensure_ functions, httplib2Jul 16, 2025
@julien-langjulien-langforce-pushed the SG-38306-python2-removal-six branch from c0ffd6e to ae164dcCompareJuly 16, 2025 13:23
@julien-langjulien-langforce-pushed the ticket/SG-38306-python2-ensure-ascii branch from 2f109c4 to f6275cdCompareJuly 17, 2025 17:37
@julien-langjulien-langforce-pushed the SG-38306-python2-removal-six branch from 4961679 to 9a131faCompareJuly 17, 2025 19:25
Copy link
Member

Choose a reason for hiding this comment

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

That's only possible if shotgunsoftware/tk-core#1042 is merged and released first

@julien-langjulien-lang requested a review from CopilotJuly 17, 2025 19:30
Copy link
Contributor

CopilotAI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes Python 2 compatibility code as part of the larger Python 2 removal effort, specifically targeting the six module and related utility functions. The changes clean up legacy compatibility layers that are no longer needed since the project has moved to Python 3 only.

Key changes:

  • Removed the bundled six module and related imports from test and production code
  • Deleted the custom sgutils.py and sgsix.py compatibility modules
  • Replaced six.PY38 version checks with direct sys.version_info comparisons
  • Updated configuration files to exclude removed modules from linting and coverage

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Show a summary per file
FileDescription
shotgun_api3/shotgun.pyReplaced six.PY38 checks with sys.version_info comparisons and removed six/sgutils imports
shotgun_api3/lib/six.pyComplete removal of the bundled six compatibility library
shotgun_api3/lib/sgutils.pyRemoved custom utility functions for Python 2/3 compatibility
shotgun_api3/lib/sgsix.pyRemoved Shotgun-specific six extensions module
tests/*.pyCleaned up six imports from test files
Configuration filesUpdated flake8 and coverage exclusions to remove references to deleted modules

Base automatically changed from ticket/SG-38306-python2-ensure-ascii to masterSeptember 10, 2025 18:50
@eduardoChaucaGallegoseduardoChaucaGallegos merged commit f7d076b into masterSep 10, 2025
22 checks passed
@eduardoChaucaGallegoseduardoChaucaGallegos deleted the SG-38306-python2-removal-six branch September 10, 2025 22:07
Sign up for freeto 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.

4 participants

@eduardoChaucaGallegos@julien-lang@carlos-villavicencio-adsk