# PSA: pin Revise at 2

**URL:** <https://discourse.julialang.org/t/psa-pin-revise-at-2/44412>\
**Category:** General Usage\
**Created:** [August 6, 2020, 11:17am UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412 "2020-08-06T11:17:13Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)\
**Post date:** [August 6, 2020, 11:17am UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412/1 "2020-08-06T11:17:13Z")

</div>

**Update: now that Revise 3 has been released, this is no longer necessary. Just use fully-updated packages.**

Several folks are having Revise problems that stem from Pkg installing a very old Revise version. You can fix it with

```julia
pkg> add Revise@2
pkg> pin Revise

```

For those who want the details: some of Revise’s dependencies have been upgraded in preparation for a Revise v3, but that release isn’t ready yet. Pkg’s resolver happens to notice that it can install newer versions of the dependencies if it goes back to an ancient version of Revise that didn’t have those dependencies.

This will be fixed when Revise 3 comes out, but for now pinning Revise seems likely to be the only reliable option.

---

<div class="post-metadata">

**Author:** ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)\
**Post date:** [August 6, 2020, 11:54am UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412/2 "2020-08-06T11:54:30Z")

</div>

Perhaps a better approach is to add

```julia
[compat]
Revise = "2"

```

to the project file. `pin` completely locks the version and does not allow for updates.

---

<div class="post-metadata">

**Author:** ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)\
**Post date:** [August 6, 2020, 12:15pm UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412/3 "2020-08-06T12:15:56Z")

</div>

Yes, that’s even better. Hopefully we won’t need more 2.x updates much longer, as it seems there are few bugs that are not the main target of v3, but you never know.

For those who may not fully understand @fredrikekre’s suggestion, you can edit whatever `Project.toml` files you use to include that `[compat]` line. That includes your default environments, e.g., `.julia/environments/v1.5/Project.toml`. That file doesn’t usually have `[compat]` entries but adding one in this case is a great idea.

---

<div class="post-metadata">

**Author:** ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Post date:** [August 17, 2020, 8:13am UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412/4 "2020-08-17T08:13:57Z")

</div>

> [@tim.holy](#):
>
> Hopefully we won’t need more 2.x updates much longer, as it seems there are few bugs that are not the main target of v3

Perhaps

```toml
[compat]
Revise = ">= 2"

```

would be better for those who want to upgrade automatically when Revise 3.0 is released.

---

<div class="post-metadata">

**Author:** ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)\
**Post date:** [September 16, 2020, 2:46pm UTC](https://discourse.julialang.org/t/psa-pin-revise-at-2/44412/5 "2020-09-16T14:46:52Z")

</div>

This is no longer necessary due to the release of Revise 3. Users who pinned Revise are recommended to `free Revise` followed by `update`. If you added a `[compat]` to your default environment, you are encouraged to remove it now.
