8000 bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string by ronaldoussoren · Pull Request #24341 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string #24341

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 2 commits into from
Feb 1, 2021

Conversation

ronaldoussoren
Copy link
Contributor
@ronaldoussoren ronaldoussoren commented Jan 26, 2021

This PR adds a way to ensure that the result of sysconfig.get_config_var() is always a string, even if the value can be interpreted as string (EDIT: as int) and uses that mechanism for MACOSX_DEPLOYMENT_TARGET.

This ensures that sysconfig.get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string regardless of how Python was configured, both for consistency and for compatibility with older versions.

https://bugs.python.org/issue42504

@ned-deily ned-deily merged commit 49926cf into python:master Feb 1, 2021
@miss-islington
Copy link
Contributor

Thanks @ronaldoussoren for the PR, and @ned-deily for merging it 🌮🎉.. I'm working now to backport this PR to: 3.9.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Feb 1, 2021
…a string (pythonGH-24341)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string
(cherry picked from commit 49926cf)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
@bedevere-bot bedevere-bot removed the needs backport to 3.9 only security fixes label Feb 1, 2021
@bedevere-bot
Copy link

GH-24410 is a backport of this pull request to the 3.9 branch.

ned-deily pushed a commit that referenced this pull request Feb 1, 2021
…a string (GH-24341) (GH-24410)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string
(cherry picked from commit 49926cf)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️

Hi! The buildbot PPC64LE RHEL8 LTO + PGO 3.9 has failed when building commit d6675fe.

What do you need to do:

  1. Don't panic.
  2. Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/505/builds/702) and take a look at the build logs.
  4. Check if the failure is related to this commit (d6675fe) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/505/builds/702

Summary of the results of the build (if available):

== Tests result: ENV CHANGED ==

410 tests OK.

10 slowest tests:

  • test_concurrent_futures: 3 min 36 sec
  • test_multiprocessing_spawn: 1 min 57 sec
  • test_tokenize: 1 min 36 sec
  • test_multiprocessing_forkserver: 1 min 35 sec
  • test_asyncio: 1 min 18 sec
  • test_lib2to3: 1 min 15 sec
  • test_unparse: 1 min 2 sec
  • test_multiprocessing_fork: 55.4 sec
  • test_io: 48.0 sec
  • test_signal: 47.4 sec

1 test altered the execution environment:
test_asyncio

14 tests skipped:
test_devpoll test_gdb test_ioctl test_kqueue test_msilib
test_ossaudiodev test_startfile test_tix test_tk test_ttk_guionly
test_winconsoleio test_winreg test_winsound test_zipfile64

Total duration: 4 min 17 sec

Click to see traceback logs
Traceback (most recent call last):
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/sslproto.py", line 321, in __del__
    self.close()
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/sslproto.py", line 316, in close
    self._ssl_protocol._start_shutdown()
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/sslproto.py", line 590, in _start_shutdown
    self._abort()
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/sslproto.py", line 731, in _abort
    self._transport.abort()
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/selector_events.py", line 680, in abort
    self._force_close(None)
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/selector_events.py", line 731, in _force_close
    self._loop.call_soon(self._call_connection_lost, exc)
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/base_events.py", line 746, in call_soon
    self._check_closed()
  File "/home/buildbot/buildarea/3.9.cstratak-RHEL8-ppc64le.lto-pgo/build/Lib/asyncio/base_events.py", line 510, in _check_closed
    raise RuntimeError('Event loop is closed')
RuntimeError: Event loop is closed

adorilson pushed a commit to adorilson/cpython that referenced this pull request Mar 13, 2021
…a string (pythonGH-24341)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string
rohitpk added a commit to rohitpk/homebrew-core that referenced this pull request Apr 23, 2021
The issue addresses the part where `MACOSX_DEPLOYMENT_TARGET` comes to be out as an integer instead of String(Float). This seems to be an issue with the new MacOS's BigSur update and has been solved in `python3.9` (MACOSX_DEPLOYMENT_TARGET).  However, there's no fix for python3.7 yet.
- Pointed to the right patch for the fix
- Revision bump

(python/cpython#24341)
BrewTestBot pushed a commit to Homebrew/homebrew-core that referenced this pull request Apr 27, 2021
Update python@3.7.rb

The issue addresses the part where `MACOSX_DEPLOYMENT_TARGET` comes to be out as an integer instead of String(Float). This seems to be an issue with the new MacOS's BigSur update and has been solved in `python3.9` (MACOSX_DEPLOYMENT_TARGET).  However, there's no fix for python3.7 yet.
- Pointed to the right patch for the fix
- Revision bump

(python/cpython#24341)

Closes #74745.

Signed-off-by: Bo Anderson <mail@boanderson.me>
Signed-off-by: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com>
ned-deily pushed a commit to ned-deily/cpython that referenced this pull request Apr 29, 2021
…a string (pythonGH-24341) (pythonGH-24410)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string
(cherry picked from commit 49926cf)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
ambv pushed a commit that referenced this pull request May 2, 2021
)

* bpo-41100: Support macOS 11 and Apple Silicon on Python 3.8

This is a partial backport of bpo-41100 changes `e8b1c038b14b5fc8120aab62c9bf5fb840274cb6` and `96d906b144e6e6aa96c5ffebecbcc5d38034bbda` for Python 3.8. We introduce the ability to build Python from source for `arm64` on macOS, but we do not make a promise of support. This allows us to omit support for Universal2 binaries as well as weak-linking of symbols from the macOS SDK based on the deployment target, which are larger changes much more difficult to merge.

This also includes a backport of subsequent bpo-42688 change `7e729978fa08a360cbf936dc215ba7dd25a06a08` to fix build errors with external `libffi`.

* bpo-41116: Ensure system supplied libraries are found on macOS 11 (GH-23301) (GH-23455)

On macOS system provided libraries are in a shared library cache
and not at their usual location. This PR teaches distutils to search
in the SDK, even if there was no "-sysroot" argument in
the compiler flags.
(cherry picked from commit 404a719)

* bpo-42504: fix for MACOSX_DEPLOYMENT_TARGET=11 (GH-23556)

macOS releases numbering has changed as of macOS 11 Big Sur.  Previously, major releases were of the form 10.x, 10.x+1, 10.x+2, etc; as of Big Sur, they are now x, x+1, etc, so, for example, 10.15, 10.15.1, ..., 10.15.7, 11, 11.0.1, 11.1, ..., 12, 12.1, etc. Allow Python to build with single-digit deployment target values. Patch provided by FX Coudert.
(cherry picked from commit 5291639)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string (GH-24341) (GH-24410)

* bpo-42504: Ensure that get_config_var('MACOSX_DEPLOYMENT_TARGET') is a string
(cherry picked from commit 49926cf)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
Co-authored-by: FX Coudert <fxcoudert@gmail.com>
Co-authored-by: Max Bélanger <aeromax@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants
0