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

added error fix for Cargo.lock version #680

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ i18n


# code-import
.turbo
code/node_modules
code/package-lock.json
code/yarn.lock
Expand Down
22 changes: 20 additions & 2 deletions docs/intro/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -442,8 +442,10 @@ You should the following output:
</AccordionItem>
</Accordion>

When running `anchor build`, if you encounter `error: not a directory` similar
following:
When running `anchor build`, if you encounter similar errors following:

<Accordion>
<AccordionItem title="error: not a directory">
nickfrosty marked this conversation as resolved.
Show resolved Hide resolved

```
error: not a directory: '.../solana-release/bin/sdk/sbf/dependencies/platform-tools/rust/lib'
Expand All @@ -463,6 +465,22 @@ cargo build-sbf --force-tools-install
rm -rf ~/.cache/solana/*
```

</AccordionItem>

<AccordionItem title="lock file version 4 requires `-Znext-lockfile-bump">
You can fix this by changing the version field of `Cargo.lock` file

```
version = 3
```

See [this issue](https://github.com/coral-xyz/anchor/issues/3392) for more
information.

</AccordionItem>

</Accordion>

After applying either solution, attempt to run `anchor build` again.

If you are on Linux or WSL and encounter the following errors when running
Expand Down
Loading