lowlighter / metrics

📊 An infographics generator with 30+ plugins and 300+ options to display stats about your GitHub account and render them as SVG, Markdown, PDF or JSON!
https://metrics.lecoq.io
MIT License
13.55k stars 1.68k forks source link

Action failing due twemoji CDN broken #1346

Closed fbuireu closed 1 year ago

fbuireu commented 1 year ago

Discussed in https://github.com/lowlighter/metrics/discussions/1345

Originally posted by **fbuireu** January 12, 2023 It seems that since 3 days ago the CND of twemoji is failing. According to the stack trace of the issue: ``` AxiosError: getaddrinfo ENOTFOUND twemoji.maxcdn.com at Function.AxiosError.from (file:///metrics/node_modules/axios/lib/core/AxiosError.js:89:14) at RedirectableRequest.handleRequestError (file:///metrics/node_modules/axios/lib/adapters/http.js:516:25) at RedirectableRequest.emit (node:events:390:28) at ClientRequest.eventHandlers. (/metrics/node_modules/follow-redirects/index.js:14:24) at ClientRequest.emit (node:events:390:28) at TLSSocket.socketErrorListener (node:_http_client:442:9) at TLSSocket.emit (node:events:390:28) at emitErrorNT (node:internal/streams/destroy:164:8) at emitErrorCloseNT (node:internal/streams/destroy:129:3) at processTicksAndRejections (node:internal/process/task_queues:83:21) { ``` Also by accessing (or trying) https://twemoji.maxcdn.com/ twemoji guys seem to be discussing a workaround in this [GitHub thread](https://github.com/twitter/twemoji/issues/580), which basically consists of a user-land approach: ``` twemoji.parse( document.body, { base: 'https://cdn.jsdelivr.net/gh/twitter/twemoji@14.0.2/assets/' } ) ```
lowlighter commented 1 year ago

Hi !

Thanks a lot for reporting this issue !

Seems like the user-land approach is a temporary measure, but it'd be better to wait for a new release since it seems they already patched the code for it.

Actually it seems they made a fork of it from what I've read in https://github.com/twitter/twemoji/issues/580#issuecomment-1380933650 (don't know the details but the original maintainers seems to have been either laid off or quitted the company 😅 ) so the resolution for this issue might just to switch the dependency to this new fork

fbuireu commented 1 year ago

Indeed! More workarounds appeared in the meantime.

Are you planning to switch dependencies to bypass the breaking action anytime soon?

Thanks for your work 😄

lowlighter commented 1 year ago

Yes I'll switch to the maintained fork and it should be fixed in next release 👍 !