ItzCrazyKns / Perplexica

Perplexica is an AI-powered search engine. It is an Open source alternative to Perplexity AI
MIT License
16.46k stars 1.54k forks source link

Yarn.lock issue I discussed earlier #2

Closed a7t0fwa7 closed 7 months ago

a7t0fwa7 commented 7 months ago

Hey here was the error message I had yesterday image

I managed to fix the issue by installing Yarn on my Debian system, hence why I created a pull request adding the instructions on how to do it for those who may have encountered a similar error.

Cheers

ItzCrazyKns commented 7 months ago

That's weird, this error generally occurs when the command is not executed in the correct directory. Make sure you are in the right directory (the root directory of the project after cloning it containing the dockerfiles). Installing Yarn to fix it is even weirder. Can you provide more context and try the solution I gave?

arsaboo commented 7 months ago

I am getting the same error:

:~/Perplexica$ docker compose up
[+] Building 0.5s (11/13)                                                                                                                                                                                                                                                                                                                                                                         docker:default
 => [perplexica-backend internal] load build definition from backend.dockerfile                                                                                                                                                                                                                                                                                                                             0.1s
 => => transferring dockerfile: 370B                                                                                                                                                                                                                                                                                                                                                                        0.0s
 => [perplexica-backend internal] load metadata for docker.io/library/node:alpine                                                                                                                                                                                                                                                                                                                           0.2s
 => [perplexica-backend internal] load .dockerignore                                                                                                                                                                                                                                                                                                                                                        0.0s
 => => transferring context: 2B                                                                                                                                                                                                                                                                                                                                                                             0.0s
 => [perplexica-backend 1/9] FROM docker.io/library/node:alpine@sha256:6d0f18a1c67dc218c4af50c21256616286a53c09e500fadf025b6d342e1c90ae                                                                                                                                                                                                                                                                     0.0s
 => [perplexica-backend internal] load build context                                                                                                                                                                                                                                                                                                                                                        0.1s
 => => transferring context: 1.11kB                                                                                                                                                                                                                                                                                                                                                                         0.0s
 => CACHED [perplexica-backend 2/9] WORKDIR /home/perplexica                                                                                                                                                                                                                                                                                                                                                0.0s
 => CANCELED [perplexica-backend 3/9] COPY src /home/perplexica/src                                                                                                                                                                                                                                                                                                                                         0.1s
 => CACHED [perplexica-backend 4/9] COPY tsconfig.json /home/perplexica/                                                                                                                                                                                                                                                                                                                                    0.0s
 => CACHED [perplexica-backend 5/9] COPY .env /home/perplexica/                                                                                                                                                                                                                                                                                                                                             0.0s
 => CACHED [perplexica-backend 6/9] COPY package.json /home/perplexica/                                                                                                                                                                                                                                                                                                                                     0.0s
 => ERROR [perplexica-backend 7/9] COPY yarn.lock /home/perplexica/                                                                                                                                                                                                                                                                                                                                         0.0s
------
 > [perplexica-backend 7/9] COPY yarn.lock /home/perplexica/:
------
failed to solve: failed to compute cache key: failed to calculate checksum of ref b2850558-f631-4b0f-ac59-42faaa3e19b0::s8d5ks1y9dvjijf1tz1o8je0x: "/yarn.lock": not found
ItzCrazyKns commented 7 months ago

Hi, after a little bit of exploration I found that the package lock files were ignored by git and were not committed. This issue is fixed by https://github.com/ItzCrazyKns/Perplexica/commit/3859e3db03993838f135951b486dd1d3e214fe7f. Thanks!

How to fix? Just re-clone the project from Github and the files will be updated and then retry the installation, things should work.