GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-95914: Add Py_UNICODE encode APIs removed in PEP 624 to 3.11 What's New by CAM-Gerlach · Pull Request #96016 · python/cpython

Conversation

@CAM-Gerlach

@CAM-Gerlach CAM-Gerlach commented Aug 16, 2022 •
edited by bedevere-bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Add a mention of the deprecated Py_UNICODE encode functions removed in Python 3.11 per PEP-624 by @methane in issue #88195 / PR #25881 to 3.11 What's New, as discussed in #95914 .

Inada-san, could you take a look at this?

Also, @AA-Turner @ezio-melotti @hugovk , any idea why ! appears to not be working as documented in :c:func: here, resulting in -n warnings and incorrect rendering? Does it have something to do with the legacy C role support still used by the CPython docs?

  • Issue: List and document remaining significant PEPs in What's New in 3.11 #95914

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@CAM-Gerlach
3.11 Whatsnew: Add Py_UNICODE encode functions removed in PEP 624
d6cb5a8
@bedevere-bot bedevere-bot added docs Documentation in the Doc dir skip news awaiting review labels Aug 16, 2022
@CAM-Gerlach
CAM-Gerlach requested review from methane and pablogsal August 16, 2022 05:21
@CAM-Gerlach CAM-Gerlach added 3.11 only security fixes needs backport to 3.11 only security fixes labels Aug 16, 2022
@CAM-Gerlach CAM-Gerlach mentioned this pull request Aug 16, 2022
List and document remaining significant PEPs in What's New in 3.11 #95914
Closed
5 tasks done
@hugovk

hugovk commented Aug 16, 2022

Copy link
Copy Markdown
Member

Also, @AA-Turner @ezio-melotti @hugovk , any idea why ! appears to not be working as documented in :c:func: here, resulting in -n warnings and incorrect rendering?

Nope... The ! prefix is meant to prevent creating a reference/hyperlink. But because the functions have been removed, you can omit the ! and it won't create a link anyway (and will render as code formatting).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@CAM-Gerlach

CAM-Gerlach commented Aug 16, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

The ! prefix is meant to prevent creating a reference/hyperlink.

Right, which is why I don't understand why it doesn't work, unless this is a Spihnx bug or some corner case (which I searched for at some length in the Sphinx repo and googled, to no avail). I figure if anyone knows, @AA-Turner would...

But because the functions have been removed, you can omit the ! and it won't create a link anyway (and will render as code formatting).

Right, of course, but the whole reason I'm adding the ! is because the functions have been removed, so Sphinx doesn't try to link them and fail with a ton of spurious warnings, obscuring real ones about actual bad references/object names amidst the noise. In that case, if for whatever reason ! doesn't work in the C domain, it would be IMO better to just use literals (as is generally used elsewhere) than known-broken references that generate a ton of spurious warnings.

ezio-melotti and hugovk reacted with thumbs up emoji
All reactions
  • 👍 2 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

methane
methane approved these changes Aug 16, 2022
View reviewed changes
@bedevere-bot bedevere-bot added awaiting merge and removed awaiting review labels Aug 16, 2022
@pablogsal

pablogsal commented Aug 18, 2022

Copy link
Copy Markdown
Member

@CAM-Gerlach Is this still a draft or can it be reviewed?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ezio-melotti

ezio-melotti commented Aug 18, 2022

Copy link
Copy Markdown
Member

I believe the markup for removed functions should be fixed before merging -- from :c:func:`...` to just ``...``.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@CAM-Gerlach
Just use :func: instead of :c:func: for non-resolved funcs so ! works
f046f3b
@CAM-Gerlach
CAM-Gerlach marked this pull request as ready for review August 18, 2022 21:01
@CAM-Gerlach

CAM-Gerlach commented Aug 18, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

I ended up going with the default-domain :func:`!...` for now, so at least the formatting is consistent and the semantics are close enough. However, I am still curious to know what's going on there...

This should be ready for final review now @pablogsal

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

pablogsal
pablogsal approved these changes Aug 18, 2022
View reviewed changes

@pablogsal pablogsal left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

LGTM!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

CAM-Gerlach reacted with hooray emoji
All reactions
  • 🎉 1 reaction
@pablogsal
pablogsal merged commit b6d88b7 into python:main Aug 18, 2022
@miss-islington

miss-islington commented Aug 18, 2022

Copy link
Copy Markdown
Contributor

Thanks @CAM-Gerlach for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot bedevere-bot removed the awaiting merge label Aug 18, 2022
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Aug 18, 2022
@CAM-Gerlach @miss-islington
pythongh-95914: Add Py_UNICODE encode APIs removed in PEP 624 to 3.11…
f0d8d36
… What's New (pythonGH-96016)

* 3.11 Whatsnew: Add Py_UNICODE encode functions removed in PEP 624

* Just use :func: instead of :c:func: for non-resolved funcs so ! works
(cherry picked from commit b6d88b7)

Co-authored-by: C.A.M. Gerlach <[email protected]>
@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Aug 18, 2022
@bedevere-bot

bedevere-bot commented Aug 18, 2022

Copy link
Copy Markdown

GH-96094 is a backport of this pull request to the 3.11 branch.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

miss-islington added a commit that referenced this pull request Aug 19, 2022
@miss-islington @CAM-Gerlach
gh-95914: Add Py_UNICODE encode APIs removed in PEP 624 to 3.11 What'…
bb37d29
…s New (GH-96016)

* 3.11 Whatsnew: Add Py_UNICODE encode functions removed in PEP 624

* Just use :func: instead of :c:func: for non-resolved funcs so ! works
(cherry picked from commit b6d88b7)

Co-authored-by: C.A.M. Gerlach <[email protected]>
@CAM-Gerlach CAM-Gerlach mentioned this pull request Sep 26, 2022
Edit What's New for Python 3.11 #95913
Closed
31 of 33 tasks
@AA-Turner AA-Turner mentioned this pull request Oct 2, 2022
Fix disabling cross-references in pre-v3 C domain sphinx-doc/sphinx#10890
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@methane methane methane approved these changes
@pablogsal pablogsal pablogsal approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

3.11 only security fixes docs Documentation in the Doc dir skip news

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

7 participants

@CAM-Gerlach @hugovk @pablogsal @ezio-melotti @miss-islington @bedevere-bot @methane
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.