Unitystation-fork / Unitystation-WikiV2

un wiki plus agréable a regardé.
6 stars 3 forks source link

error build prod #248

Closed Fr-Dae closed 11 months ago

Fr-Dae commented 11 months ago
debian@vps-dbc4d1a5:/usr/local/src/Unitystation-WikiV2$ npm run build

> build
> docusaurus build

[INFO] Website will be built for all these locales: 
- en
- fr
- ru
- de
[INFO] [en] Creating an optimized production build...
Overwriting existing registered function: trimmer-fr
Overwriting existing registered function: stemmer-fr
Overwriting existing registered function: stopWordFilter-fr
Overwriting existing registered function: trimmer-ru
Overwriting existing registered function: stemmer-ru
Overwriting existing registered function: stopWordFilter-ru
Overwriting existing registered function: trimmer-de
Overwriting existing registered function: stemmer-de
Overwriting existing registered function: stopWordFilter-de
Overwriting existing registered function: lunr-multi-trimmer-en-fr-ru-de

✖ Client
  Compiled with some errors in 36.24s

● Server █████████████████████████ building (12%) 0/1 entries 1000/1053 dependencies 208/531 modules 138 active 
 babel-loader › mdx-loader › docs/5_Dev/routine1.0.5/Entertainment/Clown.md

Module not found: Error: Can't resolve 'classnames' in '/usr/local/src/Unitystation-WikiV2/src/theme/SearchBar'
Error: Image static/img/Stations/UnrealStation.png used in docs/4_Univers/Maps/Offical_Station_Maps/Unrealstation.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/AddressableSounds/unity_hub_screen_with_soundandmusic.png used in docs/5_Dev/Introduction/development/Addressables.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToUI/auto_save_location.png used in docs/5_Dev/Introduction/development/How-To-User-Interface.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToMap/adding_role_to_maps.png used in docs/5_Dev/Introduction/development/How-to-Map.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToSprite/tyler_in_file.png used in docs/5_Dev/Introduction/development/How-to-Sprite.md not found.
    at async Promise.all (index 0)
[ERROR] Client bundle compiled with errors therefore further build is impossible.
Fr-Dae commented 11 months ago
debian@vps-dbc4d1a5:/usr/local/src/Unitystation-WikiV2$ npm run clear

> clear
> docusaurus clear

[SUCCESS] Removed the generated folder at "/usr/local/src/Unitystation-WikiV2/.docusaurus".
[SUCCESS] Removed the Webpack persistent cache folder at "/usr/local/src/Unitystation-WikiV2/node_modules/.cache".
debian@vps-dbc4d1a5:/usr/local/src/Unitystation-WikiV2$ npm run build
Fr-Dae commented 11 months ago

Debian 10 node 18.18

Fr-Dae commented 11 months ago
debian@vps-dbc4d1a5:/usr/local/src/Unitystation-WikiV2$ npm run build

> build
> docusaurus build

[INFO] Website will be built for all these locales: 
- en
- fr
- ru
- de
[INFO] [en] Creating an optimized production build...
Overwriting existing registered function: trimmer-fr
Overwriting existing registered function: stemmer-fr
Overwriting existing registered function: stopWordFilter-fr
Overwriting existing registered function: trimmer-ru
Overwriting existing registered function: stemmer-ru
Overwriting existing registered function: stopWordFilter-ru
Overwriting existing registered function: trimmer-de
Overwriting existing registered function: stemmer-de
Overwriting existing registered function: stopWordFilter-de
Overwriting existing registered function: lunr-multi-trimmer-en-fr-ru-de

✖ Client
  Compiled with some errors in 4.74m
  (building asset)

● Server █████████████████████████ building (64%) 1/1 entries 7281/7281 dependencies 2846/2846 modules 0 active 

Module not found: Error: Can't resolve 'classnames' in '/usr/local/src/Unitystation-WikiV2/src/theme/SearchBar'
Error: Image static/img/Stations/UnrealStation.png used in docs/4_Univers/Maps/Offical_Station_Maps/Unrealstation.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/AddressableSounds/unity_hub_screen_with_soundandmusic.png used in docs/5_Dev/Introduction/development/Addressables.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToUI/auto_save_location.png used in docs/5_Dev/Introduction/development/How-To-User-Interface.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToMap/adding_role_to_maps.png used in docs/5_Dev/Introduction/development/How-to-Map.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToSprite/tyler_in_file.png used in docs/5_Dev/Introduction/development/How-to-Sprite.md not found.
    at async Promise.all (index 0)
[ERROR] Client bundle compiled with errors therefore further build is impossible.
Fr-Dae commented 11 months ago

@GemInee pouvez vous former le module "classneames" a s'installer ?

Fr-Dae commented 11 months ago
cd /usr/local/src/Unitystation-WikiV2/
rm -fdrv node_modules ./package-lock.json
npm audit fix
npm i classnames
npm i && npm run clear && npm run build
nohup npm run serve -- --port 4012 --host 0.0.0.0 &
Fr-Dae commented 11 months ago
Error: Image static/img/Stations/UnrealStation.png used in docs/4_Univers/Maps/Offical_Station_Maps/Unrealstation.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/AddressableSounds/unity_hub_screen_with_soundandmusic.png used in docs/5_Dev/Introduction/development/Addressables.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToUI/auto_save_location.png used in docs/5_Dev/Introduction/development/How-To-User-Interface.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToMap/adding_role_to_maps.png used in docs/5_Dev/Introduction/development/How-to-Map.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToSprite/tyler_in_file.png used in docs/5_Dev/Introduction/development/How-to-Sprite.md not found.
    at async Promise.all (index 0)
[ERROR] Client bundle compiled with errors therefore further build is impossible.
Fr-Dae commented 11 months ago
       _,met$$$$$gg.          debian@vps-dbc4d1a5 
    ,g$$$$$$$$$$$$$$$P.       ------------------- 
  ,g$$P"     """Y$$.".        OS: Debian GNU/Linux 10 (buster) x86_64 
 ,$$P'              `$$$.     Host: OpenStack Nova 19.0.4 
',$$P       ,ggs.     `$$b:   Kernel: 4.19.0-17-cloud-amd64 
`d$$'     ,$P"'   .    $$$    Uptime: 412 days, 12 hours, 17 mins 
 $$P      d$'     ,    $$P    Packages: 801 (dpkg) 
 $$:      $$.   -    ,d$$'    Shell: bash 5.0.3 
 $$;      Y$b._   _,d$P'      Terminal: /dev/pts/0 
 Y$$.    `.`"Y$$$$P"'         CPU: Intel (Haswell, no TSX) (1) @ 2.394GHz 
 `$$b      "-.__              Memory: 508MiB / 1949MiB 
  `Y$$
   `Y$$.                                              
     `$$b.
       `Y$$b.
          `"Y$b._
              `"""
node -v
v18.18.0

docker -v
Docker version 24.0.6, build ed223bc
Clemy-beep commented 11 months ago
Error: Image static/img/Stations/UnrealStation.png used in docs/4_Univers/Maps/Offical_Station_Maps/Unrealstation.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/AddressableSounds/unity_hub_screen_with_soundandmusic.png used in docs/5_Dev/Introduction/development/Addressables.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToUI/auto_save_location.png used in docs/5_Dev/Introduction/development/How-To-User-Interface.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToMap/adding_role_to_maps.png used in docs/5_Dev/Introduction/development/How-to-Map.md not found.
    at async Promise.all (index 0)
Error: Image static/img/5_dev/HowToSprite/tyler_in_file.png used in docs/5_Dev/Introduction/development/How-to-Sprite.md not found.
    at async Promise.all (index 0)
[ERROR] Client bundle compiled with errors therefore further build is impossible.

Les imports d'images sont foirés. Chaque erreur correspond à un chemin d'image pas trouvé. Le premier c'est parce que le fichier s'appelle UnRealStation.png et pas UnrealStation.png, les autres c'est parce que le dossier s'appelle 5_Dev et non pas 5_dev

Fr-Dae commented 11 months ago

oh wow, c'est juste ça ? merci

Clemy-beep commented 11 months ago

Avec plaisir ! En fait il y avait 2 erreurs : ce problème d'import d'images et la librairie manquante "classnames" pour react, que tu as installée donc c'est réglé 😄

Fr-Dae commented 11 months ago

comment je peux etre sur que classnames est correctement installer ? @Clemy-beep

edit, je viens de faire ls | grep class et j'ai bien classnames

Clemy-beep commented 11 months ago

Facile, si tu n'as plus l'erreur Module not found: Error: Can't resolve 'classnames', alors c'est bon 😉 merci, tu peux m'expliquer sur discord si c'est compliquer de faire un docker avec le projet ?