Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

标题栏站点、WebSocket图标无法正常显示 #104

Closed
5 tasks done
zhuozhiyongde opened this issue Oct 8, 2023 · 0 comments
Closed
5 tasks done

标题栏站点、WebSocket图标无法正常显示 #104

zhuozhiyongde opened this issue Oct 8, 2023 · 0 comments

Comments

@zhuozhiyongde
Copy link
Collaborator

Describe the bug

复现方式:
最新的版本下,移除.next/文件夹,.node_modules/文件夹,使用pnpm ipnpm build重新构建,以无痕模式打开网页地址,即可复现
Cleanshot-2023-10-08-at-23 49 06
控制台报错:
Failed to load resource: the server responded with a status of 500 ()
upstream image response failed for /apps/code.png TypeError: fetch failed(这个是周四的时候报的)

通过移除pnpm-lock.yaml,在package.json中设定next、@next/bundle-analyzer版本为13.5.2(最新为13.5.4)可解决此问题,然而,原本位于应用左侧的站点图标依旧不可用:
Cleanshot-2023-10-08-at-23 31 03
直接访问站点图标路径,报错Internal Server Error
该站点图标路径是托管在路过图床的:http://localhost:2323/_next/image?url=https%3A%2F%2Fs1.ax1x.com%2F2023%2F09%2F02%2FpPBhT0O.png&w=96&q=75
使用端口直接访问前端地址(不走反向代理)无法解决新出现的这个问题。

彻底的解决方案:
回退到b4966e3版本,以上所有问题均得到解决。

附:经测试,似乎站点图像不显示的原因很玄学,如果真的移除.next/文件夹后git reset然后重装,虽然应用图标好了但是站点图标还是会寄,但我参考了之前的思路,获取了一份本地的.next/cache/images/文件夹下对应的图标文件并移动至了服务器,于是问题解决了...(wait what?

Reproduction

参见问题描述

System Info

Mac:
  System:
    OS: macOS 13.2
    CPU: (8) arm64 Apple M1 Pro
    Memory: 106.53 MB / 16.00 GB
    Shell: 5.8.1 - /bin/zsh
  Binaries:
    Node: 18.17.1 - ~/.nvm/versions/node/v18.17.1/bin/node
    Yarn: 1.22.15 - /usr/local/bin/yarn
    npm: 9.6.7 - ~/.nvm/versions/node/v18.17.1/bin/npm
    pnpm: 8.8.0 - ~/.nvm/versions/node/v18.17.1/bin/pnpm
  Browsers:
    Chrome: 116.0.5845.96
    Chrome Canary: 118.0.5990.0
    Safari: 16.3

ubuntu22.04:
  System:
    OS: Linux 5.15 Ubuntu 22.04 LTS 22.04 (Jammy Jellyfish)
    CPU: (2) x64 Intel(R) Xeon(R) Platinum 8255C CPU @ 2.50GHz
    Memory: 5.04 GB / 7.25 GB
    Container: Yes
    Shell: 5.8.1 - /usr/bin/zsh
  Binaries:
    Node: 18.18.0 - ~/.nvm/versions/node/v18.18.0/bin/node
    npm: 10.1.0 - ~/.nvm/versions/node/v18.18.0/bin/npm
    pnpm: 8.8.0 - ~/.nvm/versions/node/v18.18.0/bin/pnpm

Used Package Manager

pnpm

Validations

  • Follow our Code of Conduct
  • Read the Contributing Guide.
  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
  • The provided reproduction is a minimal reproducible of the bug.
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

No branches or pull requests

1 participant