{"id":29012165,"url":"https://github.com/liblouis/louis-migrate-yaml","last_synced_at":"2026-07-10T19:31:28.213Z","repository":{"id":192005136,"uuid":"685597192","full_name":"liblouis/louis-migrate-yaml","owner":"liblouis","description":"A tool to migrate liblouis yaml test files to normalized yaml","archived":false,"fork":false,"pushed_at":"2023-09-22T13:52:46.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-10-25T02:30:58.894Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/liblouis.png","metadata":{"files":{"readme":"Readme.org","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-08-31T15:29:36.000Z","updated_at":"2023-08-31T15:30:27.000Z","dependencies_parsed_at":null,"dependency_job_id":"be48f239-f200-416d-ba1f-021c4c473c8c","html_url":"https://github.com/liblouis/louis-migrate-yaml","commit_stats":null,"previous_names":["liblouis/louis-migrate-yaml"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/liblouis/louis-migrate-yaml","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Flouis-migrate-yaml","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Flouis-migrate-yaml/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Flouis-migrate-yaml/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Flouis-migrate-yaml/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liblouis","download_url":"https://codeload.github.com/liblouis/louis-migrate-yaml/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liblouis%2Flouis-migrate-yaml/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35341768,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-10T02:00:06.465Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-25T18:15:18.983Z","updated_at":"2026-07-10T19:31:28.169Z","avatar_url":"https://github.com/liblouis.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"* louis-migrate-yaml\n\nA tool to migrate liblouis YAML files to a new normalized format.\n\n* Why\n\nWhile the existing liblouis YAML file format is very succinct it is\nnot valid according to the [[https://yaml.org/spec/1.2.2][YAML spec]] because liblouis uses the same\nkey in a mapping multiple times, i.e. the keys in a mapping are not\nunique. This is [[https://yaml.org/spec/1.2.2/#mapping][not allowed]].\n\nThis is also the reason why [[https://serde.rs/][Serde]], the standard mechanism to read YAML\nfiles cannot be used to read the liblouis YAML files.\n\nThe goal of this tool is to migrate the liblouis YAML format to a new\nvalid YAML format.\n\n* How\n\nThe [[https://github.com/liblouis/liblouis/blob/master/tools/lou_checkyaml.c][original C-based YAML parser]] can handle the liblouis YAML because\nit is an event based parser and has no problem with non-unique keys in\nmappings.\n\nSo in theory we could enhance the C-based YAML tool to convert the\nYAML tests.\n\nInstead we decided to write a Rust-based tool based on the Rust\n[[https://docs.rs/libyaml/latest/libyaml/][libyaml bindings]].\n\n* Why not integrate this in the main liblouis Rust implementation?\n\nInstead of converting the liblouis YAML we could just use this\nimplementation to run the YAML tests. Why separate it into a different\ntool?\n\nThe main reason is the dependency on libyaml. We'd like to keep to\npure Rust to make sure we can compile liblouis everywhere including\n[[https://www.rust-lang.org/what/wasm][WebAssembly]].\n\nGranted the newest version of the bindings uses [[https://crates.io/crates/unsafe-libyaml/0.2.9][unsafe-libyaml]], a\nversion of libyaml that was transpiled to Rust, hence the bindings are\nno longer dependent on the C library. But it probably still is a big\npile of unsafe code, not something you desperately want to depend on.\n\nIf we keep the dependency in a separate tool, and migrate the YAML\ntest files to a new format we can keep louis-rs in pure Rust.\n\n* Depend on libyaml after all but just for checking the YAML tests?\n\nWe could, as a provisional measure, make [[https://github.com/liblouis/louis-parser-nom][louis-rs]] depend on libyaml\nand interprete the original YAML files directly to run the tests. This\nwould certainly simplify the process of the rewrite in Rust. We could\nargue that only the ~checkyaml~ functionality is really dependent on\nlibyaml. We could also, in theory, make this feature optional and [[https://doc.rust-lang.org/cargo/reference/features.html][hide\nit behind a feature]]. So only the checking of YAML files would maybe to\nbe so easily portable. I might be willing to make that compromise.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliblouis%2Flouis-migrate-yaml","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliblouis%2Flouis-migrate-yaml","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliblouis%2Flouis-migrate-yaml/lists"}