# Can't \`\]dev\` my own package

**URL:** https://discourse.julialang.org/t/cant-dev-my-own-package/26340
**Category:** General Usage
**Tags:** pkg
**Created:** [July 14, 2019, 12:06pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340 "2019-07-14T12:06:54Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![yha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/yha/32/3502_2.png) [@yha](https://discourse.julialang.org/u/yha)
#### Post date: [July 14, 2019, 12:06pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/1 "2019-07-14T12:06:54Z")

</div>

I’m trying to share an unregistered package that’s hosted as a private github repository.  
After `]add`ing the package from the github URL on a machine where it was not previously developed, I try to `]dev` it, I get the following error

```julia
(v1.1) pkg> dev Elegans
ERROR: The following package names could not be resolved:
 * Elegans (27ab0b70-9e64-11e9-288f-a5d350afe8a8 in manifest but not in project)
Please specify by known `name=uuid`.

```

I can’t make sense of this error. Any ideas?

---

<div class="post-metadata">

### Author: ![cserteGT3](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/csertegt3/32/8283_2.png) [@cserteGT3](https://discourse.julialang.org/u/cserteGT3)
#### Post date: [July 14, 2019, 12:13pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/2 "2019-07-14T12:13:34Z")

</div>

I assume, that it searches the registry if you don’t specify path or URL. Did you try `]dev` with the github URL?

---

<div class="post-metadata">

### Author: ![yha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/yha/32/3502_2.png) [@yha](https://discourse.julialang.org/u/yha)
#### Post date: [July 14, 2019, 12:22pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/3 "2019-07-14T12:22:55Z")

</div>

I tried it now and it worked.  
I still don’t understand why that would be necessary. I’d expect `]dev` to a package that has already been added to be an entirely local operation. Why is the registry relevant?

---

<div class="post-metadata">

### Author: ![jling](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jling/32/212909_2.png) [@jling](https://discourse.julialang.org/u/jling)
#### Post date: [July 14, 2019, 12:43pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/4 "2019-07-14T12:43:01Z")

</div>

how did you ‘added’ ‘locally’ ? `] dev` will clone the thing in to a `.../dev/` folder and you can do things with them. If you just make your local package `dev` in-place that will break the consistency of a working package?

---

<div class="post-metadata">

### Author: ![yha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/yha/32/3502_2.png) [@yha](https://discourse.julialang.org/u/yha)
#### Post date: [July 14, 2019, 12:55pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/5 "2019-07-14T12:55:24Z")

</div>

> [@jling](#):
>
> how did you ‘added’ ‘locally’ ?

I `add`ed from the github URL. I realise `]dev` clones into the `dev` folder, I just thought if I have have the package `add`ed this is the version that would get used.

> [@jling](#):
>
> If you just make your local package `dev` in-place that will break the consistency of a working package?

I’m not sure if I understood the question right, but I did not expect `dev` to be “in-place” in the sense of allowing editing of the installed copy. Just to create a separate development copy of the previously `add`ed package.

So after learning this is not the case, my updated mental model of how this works is this: when I `]dev Package` the package is looked up in the main registry and fetched from there _regardless_ of whether it is already in the manifest, so the fact that I have `]add`ed it has no effect, and in fact I can `]dev` a package without `]add`ing it first. Is that correct?  
Maybe the docs should somehow be clearer that `dev` is a variant of `add` as opposed to something you do after `add`ing. I’m reluctant to try to write it myself at this point, since I’m not sure I really understand how it works yet.

---

<div class="post-metadata">

### Author: ![jling](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jling/32/212909_2.png) [@jling](https://discourse.julialang.org/u/jling)
#### Post date: [July 14, 2019, 1:09pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/6 "2019-07-14T13:09:45Z")

</div>

> By only using `add` your Manifest will always have a “reproducible state”, in other words, as long as the repositories and registries used are still accessible it is possible to retrieve the exact state of all the dependencies in the project. This has the advantage that you can send your project ( `Project.toml` and `Manifest.toml` ) to someone else and they can “instantiate” that project in the same state as you had it locally. However, when you are developing a package, it is more convenient to load packages at their current state at some path. For this reason, the `dev` command exists.

[https://julialang.github.io/Pkg.jl/v1/managing-packages/#Developing-packages-1](https://julialang.github.io/Pkg.jl/v1/managing-packages/#Developing-packages-1)

---

<div class="post-metadata">

### Author: ![yha](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/yha/32/3502_2.png) [@yha](https://discourse.julialang.org/u/yha)
#### Post date: [July 14, 2019, 1:13pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/7 "2019-07-14T13:13:00Z")

</div>

I have read this section before asking here. It doesn’t actually say anything about how the package name is resolved. In fact, the wording “By _only_ using `add`…” in the beginning seems to reinforce the notion that `dev` is used to modify packages that have already been `add`ed.

---

<div class="post-metadata">

### Author: ![dawbarton](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dawbarton/32/215461_2.png) [@dawbarton](https://discourse.julialang.org/u/dawbarton)
#### Post date: [July 14, 2019, 1:15pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/8 "2019-07-14T13:15:31Z")

</div>

Yes, you can dev a package without adding it previously. The two operations are quite different: add gives you a copy of the package files from the latest release (no git history) whereas dev clones the repository which includes all the git history and possibly additional commits after the latest release. (It’s assumed that you take responsibility for all subsequent git pulls, etc.)

---

<div class="post-metadata">

### Author: ![jling](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jling/32/212909_2.png) [@jling](https://discourse.julialang.org/u/jling)
#### Post date: [July 14, 2019, 1:24pm UTC](https://discourse.julialang.org/t/cant-dev-my-own-package/26340/9 "2019-07-14T13:24:13Z")

</div>

I don’t know what to say, maybe you should PR a language edit.
