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-66783: Automate update of Unicode data version in documentation by nmassman · Pull Request #17748 · python/cpython

Conversation

@nmassman

@nmassman nmassman commented Dec 30, 2019 •
edited by bedevere-app Bot
Loading

Uh oh!

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

Copy link
Copy Markdown

Added a sphinx extension and modified makeunicodedata.py to automate updating documentation with the current Unicode version when it changes.

https://bugs.python.org/issue22593

  • Issue: Automate update of doc references to UCD version when it changes. #66783

Sorry, something went wrong.

Uh oh!

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

All reactions
@nmassman
bpo-22593: Automate update of unicode data version in documentation
aadb75c
@the-knights-who-say-ni the-knights-who-say-ni added the CLA signed label Dec 30, 2019
@bedevere-bot bedevere-bot added the awaiting review label Dec 30, 2019
@nmassman nmassman mentioned this pull request Dec 30, 2019
Fixed incorrect unicodedata version in lexical_analysis.rst footnote #17710
Closed
@nmassman
Fix whitespace in makeunicodedata.py
70e3c28
aeros
aeros suggested changes Dec 30, 2019
View reviewed changes

@aeros aeros left a comment

Copy link
Copy Markdown
Contributor

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.

Thanks for the PR @nmassman and welcome!

I agree with the general idea behind the PR, it doesn't seem practical to maintain the latest Unicode version in 6 different locations, or for additional ones that are added in the future.

However, a few points (I might think of more later):

  1. You could store the version as a global constant in conf.py, I don't think we need a dedicated text file just to store the latest unicode version.
  2. UNICODE_VERSION or UCS_VERSION would be a far more explicit name for the constant. As far as I'm aware, "UCD" is not a commonly known acronym for Unicode.
  3. IANAL, but I believe there are legal issues associated with copyrighting your own file additions. Our primary means of providing credit/acknowledgement to contributors these days is by adding a Contributed by <name>. sentence at the end of the news entry for the PR. You can add this in yourself.

/cc @merwok

Sorry, something went wrong.

Uh oh!

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

All reactions
@bedevere-bot bedevere-bot added awaiting core review and removed awaiting review labels Dec 30, 2019
@aeros
aeros requested a review from merwok December 30, 2019 06:30
@aeros aeros added the docs Documentation in the Doc dir label Dec 30, 2019
@ned-deily
ned-deily requested a review from JulienPalard December 30, 2019 07:43
@nmassman
Cleaned up variable names and switched to modifying Doc/conf.py directly
2cdcc44
@nmassman

nmassman commented Dec 31, 2019 •
edited
Loading

Uh oh!

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

Copy link
Copy Markdown
Author

Thanks for the feedback @aeros

  1. You could store the version as a global constant in conf.py, I don't think we need a dedicated text file just to store the latest unicode version.

I waffled on this a bit, but I went back and took another crack at it. Mostly I wanted to avoid having makeunicodedata.py accidentally mangle conf.py. I think I got it working reliably, though.

  1. UNICODE_VERSION or UCS_VERSION would be a far more explicit name for the constant. As far as I'm aware, "UCD" is not a commonly known acronym for Unicode.

Kinda embarrassed that I didn't clean that up before submitting the PR. I should have slept first. :) I renamed everything to 'UNIDATA_VERSION' to match the original variable in makeunicodedata.py. This could just as easily be changed to 'UNICODE_VERSION', but I erred on the side of staying consistent to what was already in place.

  1. IANAL, but I believe there are legal issues associated with copyrighting your own file additions. Our primary means of providing credit/acknowledgement to contributors these days is by adding a Contributed by <name>. sentence at the end of the news entry for the PR. You can add this in yourself.

I wasn't sure of the convention. I copied the heading format from what was in a few of the other sphinx extensions in the same directory. I inserted the bpo link instead (which was also in one of the other extensions), and updated the news entry.

All reactions

Sorry, something went wrong.

Uh oh!

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

@merwok

merwok commented Dec 31, 2019

Copy link
Copy Markdown
Member

I think the comments in the file constitute a change log, not a copyright notice. The copyright situation is already handled by the CLA check, which ensures that the contribution has a suitable license.

It seems OK to me to add a line there, even though there is external history in VCS metadata.

All reactions

Sorry, something went wrong.

Uh oh!

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

@aeros
aeros self-requested a review April 17, 2020 03:59
@JulienPalard

JulienPalard commented Apr 12, 2021

Copy link
Copy Markdown
Member

I feel this would be easier by using rst_prolog like:

rst_prolog = f"""
.. |UNIDATA_VERSION| replace:: {UNIDATA_VERSION}
"""

it would not need an extension.

All reactions

Sorry, something went wrong.

Uh oh!

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

@ezio-melotti ezio-melotti removed the CLA signed label Jul 13, 2022
furkanonder
furkanonder approved these changes Jan 20, 2023
View reviewed changes
@erlend-aasland erlend-aasland changed the title bpo-22593: Automate update of Unicode data version in documentation gh-66783: Automate update of Unicode data version in documentation Jan 5, 2024
@bitdancer bitdancer mentioned this pull request Apr 10, 2022
Automate update of doc references to UCD version when it changes. #66783
Closed
@AA-Turner

AA-Turner commented Jan 12, 2024

Copy link
Copy Markdown
Member

Closing per #66783 (comment)

A

All reactions

Sorry, something went wrong.

Uh oh!

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

@AA-Turner AA-Turner closed this Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@furkanonder furkanonder furkanonder approved these changes
@merwok merwok Awaiting requested review from merwok
@JulienPalard JulienPalard Awaiting requested review from JulienPalard
@aeros aeros Awaiting requested review from aeros

Uh oh!

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

Assignees

No one assigned

Labels

awaiting core review docs Documentation in the Doc dir

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.

9 participants

@nmassman @merwok @JulienPalard @AA-Turner @furkanonder @aeros @the-knights-who-say-ni @ezio-melotti @bedevere-bot
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.