Skip to content

fix configs and settings for chroma for library use#55

Open
Kiraprint wants to merge 5 commits intoaimclub:mainfrom
Kiraprint:library-chroma-fix
Open

fix configs and settings for chroma for library use#55
Kiraprint wants to merge 5 commits intoaimclub:mainfrom
Kiraprint:library-chroma-fix

Conversation

@Kiraprint
Copy link

No description provided.


def _get_omml2mml_transformation() -> etree.XSLT:
omml2mml_file = Path(Path(__file__).parent, "xsl", "omml2mml", "OMML2MML.XSL")
omml2mml_file = Path(__file__).parent / "xsl/omml2mml/OMML2MML.XSL"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

А чем такой вариант лучше чем через Path?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

На linux почему-то такой вариант не работал и выдавал лишь относительный путь

extra='ignore',
)
docs_processing_config: Optional[str] = None
docs_collection_path: str = str(Path(dirname(dirname(__file__))) / 'docs' / 'example.docx')
Copy link
Contributor

@nicl-nno nicl-nno Feb 28, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

А dirname тут критичны, нельзя от корня проекта написать путь (тут и ниже)? Тяжело читается. Да и нужно ли вообще значения по умолчанию с example.docx?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

этот файл нужен пустой, для чего он?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

У меня такой же вопрос возник, потому и удалил. Технически, ChromaSettings грузилось из него, но смысла с учётом этих ниочёмных параметров в этом мало.

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.

3 participants