Skip to content
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

Templates missing in Chinese etymology and pronunciation #620

Open
GrimPixel opened this issue May 8, 2024 · 2 comments
Open

Templates missing in Chinese etymology and pronunciation #620

GrimPixel opened this issue May 8, 2024 · 2 comments

Comments

@GrimPixel
Copy link

GrimPixel commented May 8, 2024

For example,

Phono-semantic compound (形聲/形声, OC *ʔsaːɡs, *ʔsaːɡs, *ʔsaːɡ) : semantic 亻 (“man”) + phonetic 乍 (OC *zraːɡs).
mandarin \t͡su̯ɔ˥\, \t͡su̯ɔ˧˥\, \t͡su̯ɔ˥˩\
Pinyin : zuō, zuó, zuò
EFEO : tso, tso, tso
Wade-Giles : tso1, tso2, tso4
Yale : dzwō, dzwó, dzwò
Zhuyin : ㄗㄨㄛ,ㄗㄨㄛˊ,ㄗㄨㄛˋ
xxyzz added a commit to xxyzz/wiktextract that referenced this issue May 9, 2024
@xxyzz
Copy link
Collaborator

xxyzz commented May 9, 2024

Extract fr edition's cmn-pron template is added in #621.

The en edition issue will wait for @kristian-clausal to have a look next week. I guess it's related with the etymology, pronunciation and pos title structure, and the second etymology title("Etymology") overwrites the first one("Glyph origin").

@kristian-clausal
Copy link
Collaborator

I thought the simplest, dumbest way to fix this was to combine the two sections together. We have a function in en/page.py where Tatu does some old-school text editing to fix the 'depth' of article sections; that is, if there are too few "==="'s just add them. More sophisticated than that, but not by much. I added a bit of code to see if two Etymology sections (Glyph Origin is seen as an alias for Etymology sections) next to each other (without any sections inside the previous Etymology section) and then... Oh, I just thought of a bug. And then it leaves out the title of the other etymology section, effectively combining them. This way the Glyph Origin gets a new home. The bug I thought of was that we do some stuff with the Etymology sections related to numbered Etymology sections (Etymology 1, Etymology 2, etc.), so that needs tweaking... Probably just check if either of the titles has a number and using that as the title instead. Committed to the current PR request with the other Chinese stuff (zh-x example templates).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants