[libcxx-commits] [libcxx] 1a0dd5a - [libc++] Avoid duplicate LWGXYZ prefixes in status tables (#148874)

via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jul 21 07:02:59 PDT 2025


Author: Louis Dionne
Date: 2025-07-21T10:02:54-04:00
New Revision: 1a0dd5a67eee833a56566b8cdad8c439553708a3

URL: https://github.com/llvm/llvm-project/commit/1a0dd5a67eee833a56566b8cdad8c439553708a3
DIFF: https://github.com/llvm/llvm-project/commit/1a0dd5a67eee833a56566b8cdad8c439553708a3.diff

LOG: [libc++] Avoid duplicate LWGXYZ prefixes in status tables (#148874)

When synchronizing the status tables with Github issues, we use the
title of the Github issue as the name of the paper in the status table.
However, the Github issue titles are prefixed with PXYZ or LWGXYZ (which
is useful to quickly find papers), and that is redundant in the context
of status tables. This patch ensures that we don't add that redundant
PXYZ or LWGXYZ prefix.

As a drive-by, also specify the encoding for opening files explicitly,
which fixes issues on Windows.

Added: 
    

Modified: 
    libcxx/utils/synchronize_csv_status_files.py

Removed: 
    


################################################################################
diff  --git a/libcxx/utils/synchronize_csv_status_files.py b/libcxx/utils/synchronize_csv_status_files.py
index 3132857434e7a..5dbd734de7fb0 100755
--- a/libcxx/utils/synchronize_csv_status_files.py
+++ b/libcxx/utils/synchronize_csv_status_files.py
@@ -231,7 +231,7 @@ def from_github_issue(issue: Dict):# -> PaperInfo:
 
         return PaperInfo(
             paper_number=paper,
-            paper_name=issue['title'],
+            paper_name=issue['title'].removeprefix(paper + ': '),
             status=PaperStatus.from_github_issue(issue),
             meeting=issue.get('meeting Voted', None),
             first_released_version=None, # TODO
@@ -269,14 +269,14 @@ def merge(paper: PaperInfo, gh: PaperInfo) -> PaperInfo:
 
 def load_csv(file: pathlib.Path) -> List[Tuple]:
     rows = []
-    with open(file, newline='') as f:
+    with open(file, newline='', encoding='utf-8') as f:
         reader = csv.reader(f, delimiter=',')
         for row in reader:
             rows.append(row)
     return rows
 
 def write_csv(output: pathlib.Path, rows: List[Tuple]):
-    with open(output, 'w', newline='') as f:
+    with open(output, 'w', newline='', encoding='utf-8') as f:
         writer = csv.writer(f, quoting=csv.QUOTE_ALL, lineterminator='\n')
         for row in rows:
             writer.writerow(row)
@@ -417,7 +417,7 @@ def main(argv):
     # Load all the Github issues tracking papers from Github.
     if args.load_github_from:
         print(f"Loading all issues from {args.load_github_from}")
-        with open(args.load_github_from, 'r') as f:
+        with open(args.load_github_from, 'r', encoding='utf-8') as f:
             project_info = json.load(f)
     else:
         print("Loading all issues from Github")


        


More information about the libcxx-commits mailing list