diff --git a/CHANGES.md b/CHANGES.md index f2145439..3044a158 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -16,6 +16,28 @@ To be released. now it is forwarded to the followers as well if the activity is signed. +Version 0.4.5 +------------- + +Released on January 31, 2025. + + - Fixed a bug where the migration dashboard had not been shown correctly + when the aliases of the account contained an actor whose the server was + unreachable. [[#98]] + + - Fixed a bug where Hollo posts had included unintended extra line breaks + on Iceshrimp. [[#88]] + + - Fixed a bug where importing emojis from remote servers had failed when + some shortcodes were already in use. [[#102]] + + - Upgrade Fedify to 1.3.6. + +[#88]: https://github.com/fedify-dev/hollo/issues/88 +[#98]: https://github.com/fedify-dev/hollo/issues/98 +[#102]: https://github.com/fedify-dev/hollo/issues/102 + + Version 0.4.4 ------------- diff --git a/package.json b/package.json index 1e334a44..dbecb53c 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ }, "dependencies": { "@aws-sdk/credential-providers": "^3.716.0", - "@fedify/fedify": "1.4.0-dev.607", + "@fedify/fedify": "1.4.0-dev.623", "@fedify/markdown-it-hashtag": "0.2.0", "@fedify/markdown-it-mention": "^0.1.1", "@fedify/postgres": "^0.2.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 1e127841..55195683 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -12,8 +12,8 @@ importers: specifier: ^3.716.0 version: 3.716.0(@aws-sdk/client-sso-oidc@3.716.0(@aws-sdk/client-sts@3.716.0)) '@fedify/fedify': - specifier: 1.4.0-dev.607 - version: 1.4.0-dev.607(web-streams-polyfill@3.3.3) + specifier: 1.4.0-dev.623 + version: 1.4.0-dev.623(web-streams-polyfill@3.3.3) '@fedify/markdown-it-hashtag': specifier: 0.2.0 version: 0.2.0 @@ -401,6 +401,10 @@ packages: resolution: {integrity: sha512-ttrag6haJLWABhLqtg1Uf+4LgHWIMOVSYL+VYZmAp2v4PUGOwWmWQH0Zk8RM7YuQcLfH/EoR72/Yxz6A4FKcuw==} engines: {node: '>=16.0.0'} + '@aws-sdk/util-locate-window@3.723.0': + resolution: {integrity: sha512-Yf2CS10BqK688DRsrKI/EO6B8ff5J86NXe4C+VCysK7UOgN0l1zOTeTukZ3H8Q9tYYX3oaF1961o8vRkFm7Nmw==} + engines: {node: '>=18.0.0'} + '@aws-sdk/util-user-agent-browser@3.713.0': resolution: {integrity: sha512-ioLAF8aIlcVhdizFVNuogMK5u3Js04rpGFvsbZANa1SJ9pK2UsKznnzinJT4e4ongy55g6LSZkWlF79VjG/Yfw==} @@ -927,12 +931,12 @@ packages: resolution: {integrity: sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==} engines: {node: '>=14'} - '@fedify/fedify@1.3.4': - resolution: {integrity: sha512-92vKVyERdcTFob4VYsfX4o1/WtF3mg8hsQZ8K1zDDNYYrVD+TuBB2xAWYI0ZQvVo9daoajgilvnNF66NWK140A==} + '@fedify/fedify@1.3.6': + resolution: {integrity: sha512-3jat+xhgPyvoLaiekEU/iLuEtwAlM5MneSF0HNx8T/4HgTDbrM/LZc4qJkgziXbqrPxpdj8t0oWKXWyXNpIvBg==} engines: {bun: '>=1.1.0', deno: '>=2.0.0', node: '>=20.0.0'} - '@fedify/fedify@1.4.0-dev.607': - resolution: {integrity: sha512-v+7U2osrR4z02lCOtnkJxqowYRVw8YFGU2BxS5kSH17+wjQNqtiApHCOKP8riWVreFREiHumijEVPNVo6yimAw==} + '@fedify/fedify@1.4.0-dev.623': + resolution: {integrity: sha512-zl0NBQjXAvX/9urVfLAlnZeiOv817Tj3eetiLcFNISZnn6oWJlXeoDERyAxiufnvjNbBOOkMHbgqFt+ZjrwLzg==} engines: {bun: '>=1.1.0', deno: '>=2.0.0', node: '>=20.0.0'} '@fedify/markdown-it-hashtag@0.2.0': @@ -1367,6 +1371,10 @@ packages: resolution: {integrity: sha512-w494xO+CPwG/5B/N2l0obHv2Fi9U4DAY+sTi1GWT3BVvGpZetJjJXAynIO9IHp4zS1PinGhXtRSZydUXbJO4ag==} engines: {node: '>=16.0.0'} + '@smithy/core@2.5.7': + resolution: {integrity: sha512-8olpW6mKCa0v+ibCjoCzgZHQx1SQmZuW/WkrdZo73wiTprTH6qhmskT60QLFdT9DRa5mXxjz89kQPZ7ZSsoqqg==} + engines: {node: '>=16.0.0'} + '@smithy/credential-provider-imds@3.2.8': resolution: {integrity: sha512-ZCY2yD0BY+K9iMXkkbnjo+08T2h8/34oHd0Jmh6BZUSZwaaGlGCyBT/3wnS7u7Xl33/EEfN4B6nQr3Gx5bYxgw==} engines: {node: '>=16.0.0'} @@ -1393,6 +1401,9 @@ packages: '@smithy/fetch-http-handler@4.1.2': resolution: {integrity: sha512-R7rU7Ae3ItU4rC0c5mB2sP5mJNbCfoDc8I5XlYjIZnquyUwec7fEo78F6DA3SmgJgkU1qTMcZJuGblxZsl10ZA==} + '@smithy/fetch-http-handler@4.1.3': + resolution: {integrity: sha512-6SxNltSncI8s689nvnzZQc/dPXcpHQ34KUj6gR/HBroytKOd/isMG3gJF/zBE1TBmTT18TXyzhg3O3SOOqGEhA==} + '@smithy/hash-blob-browser@3.1.10': resolution: {integrity: sha512-elwslXOoNunmfS0fh55jHggyhccobFkexLYC1ZeZ1xP2BTSrcIBaHV2b4xUQOdctrSNOpMqOZH1r2XzWTEhyfA==} @@ -1426,10 +1437,18 @@ packages: resolution: {integrity: sha512-GTxSKf280aJBANGN97MomUQhW1VNxZ6w7HAj/pvZM5MUHbMPOGnWOp1PRYKi4czMaHNj9bdiA+ZarmT3Wkdqiw==} engines: {node: '>=16.0.0'} + '@smithy/middleware-endpoint@3.2.8': + resolution: {integrity: sha512-OEJZKVUEhMOqMs3ktrTWp7UvvluMJEvD5XgQwRePSbDg1VvBaL8pX8mwPltFn6wk1GySbcVwwyldL8S+iqnrEQ==} + engines: {node: '>=16.0.0'} + '@smithy/middleware-retry@3.0.32': resolution: {integrity: sha512-v8gVA9HqibuZkFuFpfkC/EcHE8no/3Mv3JvRUGly63Axt4yyas1WDVOasFSdiqm2hZVpY7/k8mRT1Wd5k7r3Yw==} engines: {node: '>=16.0.0'} + '@smithy/middleware-retry@3.0.34': + resolution: {integrity: sha512-yVRr/AAtPZlUvwEkrq7S3x7Z8/xCd97m2hLDaqdz6ucP2RKHsBjEqaUA2ebNv2SsZoPEi+ZD0dZbOB1u37tGCA==} + engines: {node: '>=16.0.0'} + '@smithy/middleware-serde@3.0.11': resolution: {integrity: sha512-KzPAeySp/fOoQA82TpnwItvX8BBURecpx6ZMu75EZDkAcnPtO6vf7q4aH5QHs/F1s3/snQaSFbbUMcFFZ086Mw==} engines: {node: '>=16.0.0'} @@ -1478,6 +1497,10 @@ packages: resolution: {integrity: sha512-h7xn+1wlpbXyLrtvo/teHR1SFGIIrQ3imzG0nz43zVLAJgvfC1Mtdwa1pFhoIOYrt/TiNjt4pD0gSYQEdZSBtg==} engines: {node: '>=16.0.0'} + '@smithy/smithy-client@3.7.0': + resolution: {integrity: sha512-9wYrjAZFlqWhgVo3C4y/9kpc68jgiSsKUnsFPzr/MSiRL93+QRDafGTfhhKAb2wsr69Ru87WTiqSfQusSmWipA==} + engines: {node: '>=16.0.0'} + '@smithy/types@3.7.2': resolution: {integrity: sha512-bNwBYYmN8Eh9RyjS1p2gW6MIhSO2rl7X9QeLM8iTdcGRP+eDiIWDt66c9IysCc22gefKszZv+ubV9qZc7hdESg==} engines: {node: '>=16.0.0'} @@ -1512,10 +1535,18 @@ packages: resolution: {integrity: sha512-FAGsnm/xJ19SZeoqGyo9CosqjUlm+XJTmygDMktebvDKw3bKiIiZ40O1MA6Z52KLmekYU2GO7BEK7u6e7ZORKw==} engines: {node: '>= 10.0.0'} + '@smithy/util-defaults-mode-browser@3.0.34': + resolution: {integrity: sha512-FumjjF631lR521cX+svMLBj3SwSDh9VdtyynTYDAiBDEf8YPP5xORNXKQ9j0105o5+ARAGnOOP/RqSl40uXddA==} + engines: {node: '>= 10.0.0'} + '@smithy/util-defaults-mode-node@3.0.32': resolution: {integrity: sha512-2CzKhkPFCVdd15f3+0D1rldNlvJME8pVRBtVVsea2hy7lcOn0bGB0dTVUwzgfM4LW/aU4IOg3jWf25ZWaxbOiw==} engines: {node: '>= 10.0.0'} + '@smithy/util-defaults-mode-node@3.0.34': + resolution: {integrity: sha512-vN6aHfzW9dVVzkI0wcZoUXvfjkl4CSbM9nE//08lmUMyf00S75uuCpTrqF9uD4bD9eldIXlt53colrlwKAT8Gw==} + engines: {node: '>= 10.0.0'} + '@smithy/util-endpoints@2.1.7': resolution: {integrity: sha512-tSfcqKcN/Oo2STEYCABVuKgJ76nyyr6skGl9t15hs+YaiU06sgMkN7QYjo0BbVw+KT26zok3IzbdSOksQ4YzVw==} engines: {node: '>=16.0.0'} @@ -1536,6 +1567,10 @@ packages: resolution: {integrity: sha512-bOm0YMMxRjbI3X6QkWwADPFkh2AH2xBMQIB1IQgCsCRqXXpSJatgjUR3oxHthpYwFkw3WPkOt8VgMpJxC0rFqg==} engines: {node: '>=16.0.0'} + '@smithy/util-stream@3.3.4': + resolution: {integrity: sha512-SGhGBG/KupieJvJSZp/rfHHka8BFgj56eek9px4pp7lZbOF+fRiVr4U7A3y3zJD8uGhxq32C5D96HxsTC9BckQ==} + engines: {node: '>=16.0.0'} + '@smithy/util-uri-escape@3.0.0': resolution: {integrity: sha512-LqR7qYLgZTD7nWLBecUi4aqolw8Mhza9ArpNEQ881MJJIU2sE5iHCK6TdyqqzcDLy0OPe10IY4T8ctVdtynubg==} engines: {node: '>=16.0.0'} @@ -1604,8 +1639,8 @@ packages: '@types/tedious@4.0.14': resolution: {integrity: sha512-KHPsfX/FoVbUGbyYvk1q9MMQHLPeRZhRJZdO45Q4YjvFkv4hMNghCWTvy7rdKessBsmtz4euWCWAB6/tVpI1Iw==} - '@types/ws@8.5.13': - resolution: {integrity: sha512-osM/gWBTPKgHV8XkTunnegTRIsvF6owmf5w+JtAfOw472dptdm0dlGv4xCt6GwQRcC2XVOvvRE/0bAoQcL2QkA==} + '@types/ws@8.5.14': + resolution: {integrity: sha512-bd/YFLW+URhBzMXurx7lWByOu+xzU9+kb3RboOteXYDfW+tr+JZa99OyNmPINEGB/ahzKrEuc8rcv4gnpJmxTw==} abort-controller@3.0.0: resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} @@ -2421,7 +2456,7 @@ snapshots: '@aws-crypto/supports-web-crypto': 5.2.0 '@aws-crypto/util': 5.2.0 '@aws-sdk/types': 3.714.0 - '@aws-sdk/util-locate-window': 3.693.0 + '@aws-sdk/util-locate-window': 3.723.0 '@smithy/util-utf8': 2.3.0 tslib: 2.8.1 optional: true @@ -2525,36 +2560,36 @@ snapshots: '@aws-sdk/util-user-agent-node': 3.713.0 '@aws-sdk/xml-builder': 3.709.0 '@smithy/config-resolver': 3.0.13 - '@smithy/core': 2.5.6 + '@smithy/core': 2.5.7 '@smithy/eventstream-serde-browser': 3.0.14 '@smithy/eventstream-serde-config-resolver': 3.0.11 '@smithy/eventstream-serde-node': 3.0.13 - '@smithy/fetch-http-handler': 4.1.2 + '@smithy/fetch-http-handler': 4.1.3 '@smithy/hash-blob-browser': 3.1.10 '@smithy/hash-node': 3.0.11 '@smithy/hash-stream-node': 3.1.10 '@smithy/invalid-dependency': 3.0.11 '@smithy/md5-js': 3.0.11 '@smithy/middleware-content-length': 3.0.13 - '@smithy/middleware-endpoint': 3.2.7 - '@smithy/middleware-retry': 3.0.32 + '@smithy/middleware-endpoint': 3.2.8 + '@smithy/middleware-retry': 3.0.34 '@smithy/middleware-serde': 3.0.11 '@smithy/middleware-stack': 3.0.11 '@smithy/node-config-provider': 3.1.12 '@smithy/node-http-handler': 3.3.3 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/url-parser': 3.0.11 '@smithy/util-base64': 3.0.0 '@smithy/util-body-length-browser': 3.0.0 '@smithy/util-body-length-node': 3.0.0 - '@smithy/util-defaults-mode-browser': 3.0.32 - '@smithy/util-defaults-mode-node': 3.0.32 + '@smithy/util-defaults-mode-browser': 3.0.34 + '@smithy/util-defaults-mode-node': 3.0.34 '@smithy/util-endpoints': 2.1.7 '@smithy/util-middleware': 3.0.11 '@smithy/util-retry': 3.0.11 - '@smithy/util-stream': 3.3.3 + '@smithy/util-stream': 3.3.4 '@smithy/util-utf8': 3.0.0 '@smithy/util-waiter': 3.2.0 tslib: 2.8.1 @@ -2579,26 +2614,26 @@ snapshots: '@aws-sdk/util-user-agent-browser': 3.713.0 '@aws-sdk/util-user-agent-node': 3.713.0 '@smithy/config-resolver': 3.0.13 - '@smithy/core': 2.5.6 - '@smithy/fetch-http-handler': 4.1.2 + '@smithy/core': 2.5.7 + '@smithy/fetch-http-handler': 4.1.3 '@smithy/hash-node': 3.0.11 '@smithy/invalid-dependency': 3.0.11 '@smithy/middleware-content-length': 3.0.13 - '@smithy/middleware-endpoint': 3.2.7 - '@smithy/middleware-retry': 3.0.32 + '@smithy/middleware-endpoint': 3.2.8 + '@smithy/middleware-retry': 3.0.34 '@smithy/middleware-serde': 3.0.11 '@smithy/middleware-stack': 3.0.11 '@smithy/node-config-provider': 3.1.12 '@smithy/node-http-handler': 3.3.3 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/url-parser': 3.0.11 '@smithy/util-base64': 3.0.0 '@smithy/util-body-length-browser': 3.0.0 '@smithy/util-body-length-node': 3.0.0 - '@smithy/util-defaults-mode-browser': 3.0.32 - '@smithy/util-defaults-mode-node': 3.0.32 + '@smithy/util-defaults-mode-browser': 3.0.34 + '@smithy/util-defaults-mode-node': 3.0.34 '@smithy/util-endpoints': 2.1.7 '@smithy/util-middleware': 3.0.11 '@smithy/util-retry': 3.0.11 @@ -2668,26 +2703,26 @@ snapshots: '@aws-sdk/util-user-agent-browser': 3.713.0 '@aws-sdk/util-user-agent-node': 3.713.0 '@smithy/config-resolver': 3.0.13 - '@smithy/core': 2.5.6 - '@smithy/fetch-http-handler': 4.1.2 + '@smithy/core': 2.5.7 + '@smithy/fetch-http-handler': 4.1.3 '@smithy/hash-node': 3.0.11 '@smithy/invalid-dependency': 3.0.11 '@smithy/middleware-content-length': 3.0.13 - '@smithy/middleware-endpoint': 3.2.7 - '@smithy/middleware-retry': 3.0.32 + '@smithy/middleware-endpoint': 3.2.8 + '@smithy/middleware-retry': 3.0.34 '@smithy/middleware-serde': 3.0.11 '@smithy/middleware-stack': 3.0.11 '@smithy/node-config-provider': 3.1.12 '@smithy/node-http-handler': 3.3.3 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/url-parser': 3.0.11 '@smithy/util-base64': 3.0.0 '@smithy/util-body-length-browser': 3.0.0 '@smithy/util-body-length-node': 3.0.0 - '@smithy/util-defaults-mode-browser': 3.0.32 - '@smithy/util-defaults-mode-node': 3.0.32 + '@smithy/util-defaults-mode-browser': 3.0.34 + '@smithy/util-defaults-mode-node': 3.0.34 '@smithy/util-endpoints': 2.1.7 '@smithy/util-middleware': 3.0.11 '@smithy/util-retry': 3.0.11 @@ -2757,26 +2792,26 @@ snapshots: '@aws-sdk/util-user-agent-browser': 3.713.0 '@aws-sdk/util-user-agent-node': 3.713.0 '@smithy/config-resolver': 3.0.13 - '@smithy/core': 2.5.6 - '@smithy/fetch-http-handler': 4.1.2 + '@smithy/core': 2.5.7 + '@smithy/fetch-http-handler': 4.1.3 '@smithy/hash-node': 3.0.11 '@smithy/invalid-dependency': 3.0.11 '@smithy/middleware-content-length': 3.0.13 - '@smithy/middleware-endpoint': 3.2.7 - '@smithy/middleware-retry': 3.0.32 + '@smithy/middleware-endpoint': 3.2.8 + '@smithy/middleware-retry': 3.0.34 '@smithy/middleware-serde': 3.0.11 '@smithy/middleware-stack': 3.0.11 '@smithy/node-config-provider': 3.1.12 '@smithy/node-http-handler': 3.3.3 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/url-parser': 3.0.11 '@smithy/util-base64': 3.0.0 '@smithy/util-body-length-browser': 3.0.0 '@smithy/util-body-length-node': 3.0.0 - '@smithy/util-defaults-mode-browser': 3.0.32 - '@smithy/util-defaults-mode-node': 3.0.32 + '@smithy/util-defaults-mode-browser': 3.0.34 + '@smithy/util-defaults-mode-node': 3.0.34 '@smithy/util-endpoints': 2.1.7 '@smithy/util-middleware': 3.0.11 '@smithy/util-retry': 3.0.11 @@ -2834,12 +2869,12 @@ snapshots: '@aws-sdk/core@3.713.0': dependencies: '@aws-sdk/types': 3.713.0 - '@smithy/core': 2.5.6 + '@smithy/core': 2.5.7 '@smithy/node-config-provider': 3.1.12 '@smithy/property-provider': 3.1.11 '@smithy/protocol-http': 4.1.8 '@smithy/signature-v4': 4.2.4 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/util-middleware': 3.0.11 fast-xml-parser: 4.4.1 @@ -2891,13 +2926,13 @@ snapshots: dependencies: '@aws-sdk/core': 3.713.0 '@aws-sdk/types': 3.713.0 - '@smithy/fetch-http-handler': 4.1.2 + '@smithy/fetch-http-handler': 4.1.3 '@smithy/node-http-handler': 3.3.3 '@smithy/property-provider': 3.1.11 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 - '@smithy/util-stream': 3.3.3 + '@smithy/util-stream': 3.3.4 tslib: 2.8.1 optional: true @@ -3113,7 +3148,7 @@ snapshots: '@smithy/protocol-http': 4.1.8 '@smithy/types': 3.7.2 '@smithy/util-middleware': 3.0.11 - '@smithy/util-stream': 3.3.3 + '@smithy/util-stream': 3.3.4 '@smithy/util-utf8': 3.0.0 tslib: 2.8.1 optional: true @@ -3173,15 +3208,15 @@ snapshots: '@aws-sdk/core': 3.713.0 '@aws-sdk/types': 3.713.0 '@aws-sdk/util-arn-parser': 3.693.0 - '@smithy/core': 2.5.6 + '@smithy/core': 2.5.7 '@smithy/node-config-provider': 3.1.12 '@smithy/protocol-http': 4.1.8 '@smithy/signature-v4': 4.2.4 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 '@smithy/util-config-provider': 3.0.0 '@smithy/util-middleware': 3.0.11 - '@smithy/util-stream': 3.3.3 + '@smithy/util-stream': 3.3.4 '@smithy/util-utf8': 3.0.0 tslib: 2.8.1 optional: true @@ -3198,7 +3233,7 @@ snapshots: '@aws-sdk/core': 3.713.0 '@aws-sdk/types': 3.713.0 '@aws-sdk/util-endpoints': 3.713.0 - '@smithy/core': 2.5.6 + '@smithy/core': 2.5.7 '@smithy/protocol-http': 4.1.8 '@smithy/types': 3.7.2 tslib: 2.8.1 @@ -3238,9 +3273,9 @@ snapshots: '@aws-sdk/signature-v4-multi-region': 3.713.0 '@aws-sdk/types': 3.713.0 '@aws-sdk/util-format-url': 3.713.0 - '@smithy/middleware-endpoint': 3.2.7 + '@smithy/middleware-endpoint': 3.2.8 '@smithy/protocol-http': 4.1.8 - '@smithy/smithy-client': 3.5.2 + '@smithy/smithy-client': 3.7.0 '@smithy/types': 3.7.2 tslib: 2.8.1 optional: true @@ -3317,6 +3352,11 @@ snapshots: dependencies: tslib: 2.8.1 + '@aws-sdk/util-locate-window@3.723.0': + dependencies: + tslib: 2.8.1 + optional: true + '@aws-sdk/util-user-agent-browser@3.713.0': dependencies: '@aws-sdk/types': 3.713.0 @@ -3633,7 +3673,7 @@ snapshots: '@fastify/busboy@2.1.1': {} - '@fedify/fedify@1.3.4(web-streams-polyfill@3.3.3)': + '@fedify/fedify@1.3.6(web-streams-polyfill@3.3.3)': dependencies: '@deno/shim-crypto': 0.3.1 '@deno/shim-deno': 0.18.2 @@ -3655,7 +3695,7 @@ snapshots: transitivePeerDependencies: - web-streams-polyfill - '@fedify/fedify@1.4.0-dev.607(web-streams-polyfill@3.3.3)': + '@fedify/fedify@1.4.0-dev.623(web-streams-polyfill@3.3.3)': dependencies: '@deno/shim-crypto': 0.3.1 '@deno/shim-deno': 0.18.2 @@ -3688,7 +3728,7 @@ snapshots: '@fedify/postgres@0.2.2(web-streams-polyfill@3.3.3)': dependencies: '@deno/shim-deno': 0.18.2 - '@fedify/fedify': 1.3.4(web-streams-polyfill@3.3.3) + '@fedify/fedify': 1.3.6(web-streams-polyfill@3.3.3) '@js-temporal/polyfill': 0.4.4 postgres: 3.4.5 transitivePeerDependencies: @@ -4206,6 +4246,18 @@ snapshots: '@smithy/util-utf8': 3.0.0 tslib: 2.8.1 + '@smithy/core@2.5.7': + dependencies: + '@smithy/middleware-serde': 3.0.11 + '@smithy/protocol-http': 4.1.8 + '@smithy/types': 3.7.2 + '@smithy/util-body-length-browser': 3.0.0 + '@smithy/util-middleware': 3.0.11 + '@smithy/util-stream': 3.3.4 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.1 + optional: true + '@smithy/credential-provider-imds@3.2.8': dependencies: '@smithy/node-config-provider': 3.1.12 @@ -4257,6 +4309,15 @@ snapshots: '@smithy/util-base64': 3.0.0 tslib: 2.8.1 + '@smithy/fetch-http-handler@4.1.3': + dependencies: + '@smithy/protocol-http': 4.1.8 + '@smithy/querystring-builder': 3.0.11 + '@smithy/types': 3.7.2 + '@smithy/util-base64': 3.0.0 + tslib: 2.8.1 + optional: true + '@smithy/hash-blob-browser@3.1.10': dependencies: '@smithy/chunked-blob-reader': 4.0.0 @@ -4316,6 +4377,18 @@ snapshots: '@smithy/util-middleware': 3.0.11 tslib: 2.8.1 + '@smithy/middleware-endpoint@3.2.8': + dependencies: + '@smithy/core': 2.5.7 + '@smithy/middleware-serde': 3.0.11 + '@smithy/node-config-provider': 3.1.12 + '@smithy/shared-ini-file-loader': 3.1.12 + '@smithy/types': 3.7.2 + '@smithy/url-parser': 3.0.11 + '@smithy/util-middleware': 3.0.11 + tslib: 2.8.1 + optional: true + '@smithy/middleware-retry@3.0.32': dependencies: '@smithy/node-config-provider': 3.1.12 @@ -4328,6 +4401,19 @@ snapshots: tslib: 2.8.1 uuid: 9.0.1 + '@smithy/middleware-retry@3.0.34': + dependencies: + '@smithy/node-config-provider': 3.1.12 + '@smithy/protocol-http': 4.1.8 + '@smithy/service-error-classification': 3.0.11 + '@smithy/smithy-client': 3.7.0 + '@smithy/types': 3.7.2 + '@smithy/util-middleware': 3.0.11 + '@smithy/util-retry': 3.0.11 + tslib: 2.8.1 + uuid: 9.0.1 + optional: true + '@smithy/middleware-serde@3.0.11': dependencies: '@smithy/types': 3.7.2 @@ -4404,6 +4490,17 @@ snapshots: '@smithy/util-stream': 3.3.3 tslib: 2.8.1 + '@smithy/smithy-client@3.7.0': + dependencies: + '@smithy/core': 2.5.7 + '@smithy/middleware-endpoint': 3.2.8 + '@smithy/middleware-stack': 3.0.11 + '@smithy/protocol-http': 4.1.8 + '@smithy/types': 3.7.2 + '@smithy/util-stream': 3.3.4 + tslib: 2.8.1 + optional: true + '@smithy/types@3.7.2': dependencies: tslib: 2.8.1 @@ -4450,6 +4547,15 @@ snapshots: bowser: 2.11.0 tslib: 2.8.1 + '@smithy/util-defaults-mode-browser@3.0.34': + dependencies: + '@smithy/property-provider': 3.1.11 + '@smithy/smithy-client': 3.7.0 + '@smithy/types': 3.7.2 + bowser: 2.11.0 + tslib: 2.8.1 + optional: true + '@smithy/util-defaults-mode-node@3.0.32': dependencies: '@smithy/config-resolver': 3.0.13 @@ -4460,6 +4566,17 @@ snapshots: '@smithy/types': 3.7.2 tslib: 2.8.1 + '@smithy/util-defaults-mode-node@3.0.34': + dependencies: + '@smithy/config-resolver': 3.0.13 + '@smithy/credential-provider-imds': 3.2.8 + '@smithy/node-config-provider': 3.1.12 + '@smithy/property-provider': 3.1.11 + '@smithy/smithy-client': 3.7.0 + '@smithy/types': 3.7.2 + tslib: 2.8.1 + optional: true + '@smithy/util-endpoints@2.1.7': dependencies: '@smithy/node-config-provider': 3.1.12 @@ -4492,6 +4609,18 @@ snapshots: '@smithy/util-utf8': 3.0.0 tslib: 2.8.1 + '@smithy/util-stream@3.3.4': + dependencies: + '@smithy/fetch-http-handler': 4.1.3 + '@smithy/node-http-handler': 3.3.3 + '@smithy/types': 3.7.2 + '@smithy/util-base64': 3.0.0 + '@smithy/util-buffer-from': 3.0.0 + '@smithy/util-hex-encoding': 3.0.0 + '@smithy/util-utf8': 3.0.0 + tslib: 2.8.1 + optional: true + '@smithy/util-uri-escape@3.0.0': dependencies: tslib: 2.8.1 @@ -4571,7 +4700,7 @@ snapshots: dependencies: '@types/node': 22.10.2 - '@types/ws@8.5.13': + '@types/ws@8.5.14': dependencies: '@types/node': 22.10.2 optional: true @@ -4617,7 +4746,7 @@ snapshots: bun-types@1.1.37: dependencies: '@types/node': 20.12.14 - '@types/ws': 8.5.13 + '@types/ws': 8.5.14 optional: true bytes@3.1.2: {} diff --git a/src/pages/accounts.tsx b/src/pages/accounts.tsx index be589771..c2939b6c 100644 --- a/src/pages/accounts.tsx +++ b/src/pages/accounts.tsx @@ -441,10 +441,19 @@ accounts.get("/:id/migrate", async (c) => { if (accountOwner == null) return c.notFound(); const username = `@${accountOwner.handle}`; const aliases = await Promise.all( - uniq(accountOwner.account.aliases).map(async (alias) => ({ - iri: alias, - handle: await getActorHandle(new URL(alias)), - })), + uniq(accountOwner.account.aliases).map(async (alias) => { + let handle: Awaited> | null; + try { + handle = await getActorHandle(new URL(alias)); + } catch (e) { + if (e instanceof TypeError) { + handle = null; + } else { + throw e; + } + } + return { iri: alias, handle }; + }), ); const [{ followsCount }] = await db .select({ followsCount: count() }) @@ -497,7 +506,15 @@ accounts.get("/:id/migrate", async (c) => { diff --git a/src/pages/emojis.tsx b/src/pages/emojis.tsx index b49d8f9c..0345e962 100644 --- a/src/pages/emojis.tsx +++ b/src/pages/emojis.tsx @@ -1,3 +1,4 @@ +import { getLogger } from "@logtape/logtape"; import { desc, inArray, isNotNull, ne } from "drizzle-orm"; import { Hono } from "hono"; import mime from "mime"; @@ -7,6 +8,8 @@ import { loginRequired } from "../login"; import { accounts, customEmojis, posts, reactions } from "../schema"; import { disk, getAssetUrl } from "../storage"; +const logger = getLogger(["hollo", "pages", "emojis"]); + const emojis = new Hono(); emojis.use(loginRequired); @@ -368,13 +371,16 @@ emojis.post("/import", async (c) => { ? (form.get("new")?.toString() ?? "") : null; const imports = form.getAll("import").map((i) => JSON.parse(i.toString())); - await db.insert(customEmojis).values( - imports.map(({ shortcode, url }) => ({ - category, - shortcode, - url, - })), - ); + for (const { shortcode, url } of imports) { + try { + await db.insert(customEmojis).values({ category, shortcode, url }); + } catch (error) { + logger.error( + "Failed to import emoji {shortcode} to {category}: {error}", + { category, shortcode, error }, + ); + } + } return c.redirect("/emojis"); }); diff --git a/src/text.ts b/src/text.ts index 6b65ccb4..f37483bb 100644 --- a/src/text.ts +++ b/src/text.ts @@ -160,7 +160,7 @@ export async function formatText( } } return { - html, + html: cleanupRedundantWhitespacesInHtml(html), mentions: Object.values(handles).map((v) => v.id), hashtags: env.hashtags, previewLink: env.previewLink, @@ -171,6 +171,13 @@ export async function formatText( }; } +export function cleanupRedundantWhitespacesInHtml(html: string): string { + return html.replaceAll( + /(<\/(?:h[123456r]|li|ol|p|pre|ul)?>)\s+(<(?:h[123456r]|li|ol|p|pre|ul)>)/g, + (_, a, b) => a + b, + ); +} + const HTML_ELEMENT_REGEXP = /<\/?[^>]+>/g; export function renderCustomEmojis(