This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Syntax highlighting for ASDL
Type: enhancement Stage: resolved
Components: Documentation Versions: Python 3.9
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: BTaskaya, docs@python, eric.araujo, ezio.melotti, mdk, rhettinger, terry.reedy, willingc, zach.ware
Priority: normal Keywords: patch

Created on 2020-05-05 13:51 by BTaskaya, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
Screen Shot 2020-05-05 at 10.17.15 PM.png rhettinger, 2020-05-06 05:39 Screen shot of the AST docs
asdl.png BTaskaya, 2020-05-06 19:06
asdl2.png BTaskaya, 2020-05-06 19:40
python_bold.png BTaskaya, 2020-05-06 22:03
asdl_no_style.png BTaskaya, 2020-05-06 22:03
bold_dark_blue.png BTaskaya, 2020-05-07 10:45
Pull Requests
URL Status Linked Edit
PR 19928 merged BTaskaya, 2020-05-05 13:54
PR 19950 merged rhettinger, 2020-05-06 05:24
PR 19967 merged BTaskaya, 2020-05-06 19:13
Messages (22)
msg368148 - (view) Author: Batuhan Taskaya (BTaskaya) * (Python committer) Date: 2020-05-05 13:51
ASDL is around here for a long time, and it was showed as raw text on documentation (under library/ast), IMHO it would be great to highlight it.
msg368209 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-05 21:38
+1
msg368225 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-06 05:24
New changeset d60040ba226bd2e3b6f58d074015aa2499dc1cb8 by Batuhan Taskaya in branch 'master':
bpo-40517: Implement syntax highlighting support for ASDL (#19928)
https://github.com/python/cpython/commit/d60040ba226bd2e3b6f58d074015aa2499dc1cb8
msg368226 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-06 05:34
New changeset eff870b618ca6f6b7a60a271f15af7e54b8a1b97 by Raymond Hettinger in branch 'master':
Revert "bpo-40517: Implement syntax highlighting support for ASDL (#19928)" (#19950)
https://github.com/python/cpython/commit/eff870b618ca6f6b7a60a271f15af7e54b8a1b97
msg368228 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-06 05:39
I really like this idea but it needs different styling.  Attaching a screen shot will significant readability and beauty issues.

Suggest:
* Boldfacethe class names (Module, Interactive, etc)
* Unboldface the fields names (body, types_ignores, argtypes, etc)
* The tinted grape color does not work well on the green background.
* Perhaps have a graphic designer take a look.
msg368230 - (view) Author: Batuhan Taskaya (BTaskaya) * (Python committer) Date: 2020-05-06 07:57
Oh, sorry for that bad look :/ I just want it to look consistent, let me see what I can do further (I'll probably consult a friend of mine who understand this things). By the way, I could've just adjust the values over the existing code if you didn't revert, the core logic would be same we just need to change token types.
msg368266 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-06 15:25
Sorry about the commit/revert. I fat fingered a comment.  Please do resubmit the PR.  In general, this is a nice idea.  The look just needs to be tweaked a bit.
msg368291 - (view) Author: Batuhan Taskaya (BTaskaya) * (Python committer) Date: 2020-05-06 19:06
Hey Raymond, can you give me your feedback on asdl.png (the screenshot of new theme)?
msg368292 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2020-05-06 19:18
The new screenshot looks nice.  The colors are much better.  Can you post another run with the class names in bold.
msg368294 - (view) Author: Batuhan Taskaya (BTaskaya) * (Python committer) Date: 2020-05-06 19:40