r-universe-org / help

Support and bug tracker for R-universe
https://docs.r-universe.dev/
8 stars 2 forks source link

CITATION.cff does not account for UTF-8 characters #382

Closed dieghernan closed 3 months ago

dieghernan commented 3 months ago

I tried to track this down but I couldn’t find where is the issue (I guess it is related with the underlying OS that runs the infrastructure and the encoding).

see https://ropensci.r-universe.dev/cffr/citation.cff


- family-names: Hernangómez
  given-names: Diego

but should be


- family-names: Hernangómez 
  given-names: Diego

Haven’t found that with my tests (11 combinations of OS and R versions): https://github.com/ropensci/cffr/actions/workflows/check-full.yaml

dieghernan commented 3 months ago

I checked on the server other files created along the cff file as of:

https://github.com/r-universe-org/build-source/blob/7bf4d8a84553d440747240d8135ec1eba2eb8e02/R/buildtools.R#L582-L597

And same issue, except for html version:

citation.json

[
  {
    "doi": "10.21105/joss.03900",
    "url": "https://doi.org/10.21105/joss.03900",
    "year": "2021",
    "publisher": "The Open Journal",
    "volume": "6",
    "number": "67",
    "pages": "3900",
    "author": [
      {
        "given": "Diego",
        "family": "Hernangómez",
        "role": {},
        "email": {},
        "comment": {}
      }
    ],
    "title": "{cffr}: Generate Citation File Format Metadata for {R} Packages",
    "journal": "Journal of Open Source Software"
  },
  ...
]

citation.txt

Hernangómez D (2021). “cffr: Generate Citation File Format Metadata for
R Packages.” _Journal of Open Source Software_, *6*(67), 3900.
doi:10.21105/joss.03900 <https://doi.org/10.21105/joss.03900>,
<https://doi.org/10.21105/joss.03900>.

A BibTeX entry for LaTeX users is

  @Article{hernangomez2021,
    doi = {10.21105/joss.03900},
    url = {https://doi.org/10.21105/joss.03900},
    year = {2021},
    publisher = {The Open Journal},
    volume = {6},
    number = {67},
    pages = {3900},
    author = {Diego Hernangómez},
    title = {{cffr}: Generate Citation File Format Metadata for {R} Packages},
    journal = {Journal of Open Source Software},
  }
...

citation.html

This one is OK

Hernangómez D (2021). “cffr: Generate Citation File Format Metadata for R Packages.” Journal of Open Source Software, 6(67), 3900. [doi:10.21105/joss.03900](https://doi.org/10.21105/joss.03900), https://doi.org/10.21105/joss.03900.

Consider also citing:

Druskat S, Spaaks JH, Chue Hong N, Haines R, Baker J, Bliven S, Willighagen E, Pérez-Suárez D, Konovalov A (2021). “Citation File Format.” [doi:10.5281/zenodo.5171937](https://doi.org/10.5281/zenodo.5171937), https://github.com/citation-file-format/citation-file-format.

Corresponding BibTeX entries:

  @Article{hernangomez2021,
    doi = {10.21105/joss.03900},
    url = {https://doi.org/10.21105/joss.03900},
    year = {2021},
    publisher = {The Open Journal},
    volume = {6},
    number = {67},
    pages = {3900},
    author = {Diego Hernangómez},
    title = {{cffr}: Generate Citation File Format Metadata for {R}
      Packages},
    journal = {Journal of Open Source Software},
  }
jeroen commented 3 months ago

Thanks, should be fixed now!