# Silverbullet update (edge) through deno not working

**URL:** https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508
**Category:** v1: Troubleshooting (legacy)
**Created:** [June 11, 2024, 5:23am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508 "2024-06-11T05:23:30Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [June 11, 2024, 5:23am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/1 "2024-06-11T05:23:30Z")

</div>

1st time i see this error when trying to upgrade silverbullet.  
Any ideas?

```auto
>silverbullet upgrade
Now going to attempt an upgrade...
error: Integrity check failed for remote specifier. The source code is invalid, as it does not match the expected hash in the lock file.

  Specifier: https://edge.silverbullet.md/silverbullet.js
  Actual: e8d58388a1ffa66ef97028669e04bf1035f10463fc87989037ea3bf9e8fc09c1
  Expected: 54c3931273adc930cd520940285fa83b4096be5f56e4aa236e4e4bee2a8bda1b

This could be caused by:
  * the lock file may be corrupt
  * the source itself may be corrupt

Use the --lock-write flag to regenerate the lockfile or --reload to reload the source code from the server.
Something went wrong there...

```

---

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [June 13, 2024, 6:44am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/2 "2024-06-13T06:44:45Z")

</div>

I guess an easy fix is to delete the silverbullet binary and download it again, but wondering if there is a better way to fix this, in case someone experiences this issue in the future

---

<div class="post-metadata">

### Author: ![zef](https://community.silverbullet.md/user_avatar/community.silverbullet.md/zef/32/7_2.png) [@zef](https://community.silverbullet.md/u/zef)
#### Post date: [June 13, 2024, 10:18am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/3 "2024-06-13T10:18:47Z")

</div>

This is really strange, what lock file? There is no lock file… or do you have one somewhere in your cache somewhere? I think it should be called `deno.lock`.

---

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [June 13, 2024, 11:19am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/4 "2024-06-13T11:19:13Z")

</div>

I honestly had no idea what it was telling me about, because i could not find anything.

In my `~/.deno/bin/` folder i only had the silverbullet binary.

I deleted it and download it again with deno and then it worked again.

But i was super confused when the error appeared as I didn’t know how I should have proceeded.

---

<div class="post-metadata">

### Author: ![zef](https://community.silverbullet.md/user_avatar/community.silverbullet.md/zef/32/7_2.png) [@zef](https://community.silverbullet.md/u/zef)
#### Post date: [June 13, 2024, 5:57pm UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/5 "2024-06-13T17:57:27Z")

</div>

Let me know if the next upgrade succeeds again.

---

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [July 12, 2024, 6:57am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/6 "2024-07-12T06:57:14Z")

</div>

I just got it again this morning:

```auto
>silverbullet upgrade
Now going to attempt an upgrade...
error: Integrity check failed for remote specifier. The source code is invalid, as it does not match the expected hash in the lock file.

  Specifier: https://get.silverbullet.md/
  Actual: 6a87ced48063c5ec3daf6842d6e1322d8499ad55281a8e18ee280a6dac6cd86d
  Expected: 1211cfcac962462d5bbffb244b8fa58d05baa85b228e64aea75fbbfdf55f15d8

This could be caused by:
  * the lock file may be corrupt
  * the source itself may be corrupt

Use the --lock-write flag to regenerate the lockfile or --reload to reload the source code from the server.
Something went wrong there...

```

---

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [July 12, 2024, 7:03am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/7 "2024-07-12T07:03:10Z")

</div>

It seems there is something not working when installing through deno and trying to upgrade

```auto
❯ rm ~/.deno/bin/silverbullet
rm: remove regular file '/home/user/.deno/bin/silverbullet'? y

 ❯ deno install -f --name silverbullet --unstable-kv --unstable-worker-options -A https://get.silverbullet.md
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag.
✅ Successfully installed silverbullet
/home/user/.deno/bin/silverbullet

❯ silverbullet upgrade
Now going to attempt an upgrade...
error: Integrity check failed for remote specifier. The source code is invalid, as it does not match the expected hash in the lock file.

  Specifier: https://get.silverbullet.md/
  Actual: 6a87ced48063c5ec3daf6842d6e1322d8499ad55281a8e18ee280a6dac6cd86d
  Expected: 1211cfcac962462d5bbffb244b8fa58d05baa85b228e64aea75fbbfdf55f15d8

This could be caused by:
  * the lock file may be corrupt
  * the source itself may be corrupt

Use the --lock-write flag to regenerate the lockfile or --reload to reload the source code from the server.
Something went wrong there...

```

---

<div class="post-metadata">

### Author: ![zef](https://community.silverbullet.md/user_avatar/community.silverbullet.md/zef/32/7_2.png) [@zef](https://community.silverbullet.md/u/zef)
#### Post date: [July 12, 2024, 3:50pm UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/8 "2024-07-12T15:50:50Z")

</div>

I really do not know where it’s finding the lock file… Ok, what I can do is simply disable the check, it looks like there’s a `—no-check` option, maybe I just add that…

---

<div class="post-metadata">

### Author: ![zef](https://community.silverbullet.md/user_avatar/community.silverbullet.md/zef/32/7_2.png) [@zef](https://community.silverbullet.md/u/zef)
#### Post date: [July 14, 2024, 10:11am UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/9 "2024-07-14T10:11:46Z")

</div>

I’ve tried to address this here: [Deno upgrade and attempt to fix upgrade issues · silverbulletmd/silverbullet@d54c400 · GitHub](https://github.com/silverbulletmd/silverbullet/commit/d54c400b7634c2fecd31586f20401360dd36d52a)

Basically I disabled lock file checking, it’s kind of pointless anyway.

---

<div class="post-metadata">

### Author: ![paletochen](https://community.silverbullet.md/letter_avatar_proxy/v4/letter/p/cdc98d/32.png) [@paletochen](https://community.silverbullet.md/u/paletochen)
#### Post date: [July 14, 2024, 5:05pm UTC](https://community.silverbullet.md/t/silverbullet-update-edge-through-deno-not-working/508/10 "2024-07-14T17:05:22Z")

</div>

Thanks.

It works now:

```auto
❯ deno install -f --name silverbullet --lock-write --unstable-kv --unstable-worker-options --no-config --reload -A https://edge.silverbullet.md/silverbullet.js
⚠️ `deno install` behavior will change in Deno 2. To preserve the current behavior use the `-g` or `--global` flag.
✅ Successfully installed silverbullet
/home/user/.deno/bin/silverbullet

❯ silverbullet upgrade
Now going to attempt an upgrade...
So, that's done. Now let's see if this actually did anything...
Nope. I hate to tell you this, but it looks like we're still running 0.8.1. This was a bit of a futile exercise. Let's try again soon some time.

```
