Skip to content

fix init.doc field on translation.json - #5193

Open
HazizCISSE wants to merge 1 commit into
MarketSquare:mainfrom
HazizCISSE:right-init.doc-json-field
Open

fix init.doc field on translation.json#5193
HazizCISSE wants to merge 1 commit into
MarketSquare:mainfrom
HazizCISSE:right-init.doc-json-field

Conversation

@HazizCISSE

Copy link
Copy Markdown

I'm translating Browser Library in french with robotframework-browser-translation.
There is an issue on the json translation file generated by the command : "uv run python -m Browser.entry translation robotframework_browser_translation/translation_xx.json".

The init.doc field contains the same text as intro.doc field. So when you generate a html documentation with libdoc command : "python3 -m robot.libdoc "Browser::language=fr" browser_xxx.html".
The generated file contains the introduction twice : once in "introduction" section and in "importing" section.

I'v tried this modification on Browser Library and it worked :
on line 48 of "Browser/entry/translation.py" :
old :  inspect.getdoc(browser)
new : inspect.getdoc(browser.init )

The generated json contains the right text in init.doc field and the html documentation introduction section is ok.

@aaltat

aaltat commented Aug 31, 2026

Copy link
Copy Markdown
Member

There is an MyPy lint error that needs to be fixed before this can be merged

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

Successfully merging this pull request may close these issues.

2 participants