# Updating an extension

**URL:** https://discourse.slicer.org/t/updating-an-extension/169
**Category:** Development
**Created:** [April 21, 2017, 6:29pm UTC](https://discourse.slicer.org/t/updating-an-extension/169 "2017-04-21T18:29:50Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![Lorensen](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lorensen/32/31_2.png) [@Lorensen](https://discourse.slicer.org/u/Lorensen)
#### Post date: [April 21, 2017, 6:29pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/1 "2017-04-21T18:29:51Z")

</div>

It has been a LONG time since I worked with extensions. I have made changes to my extension SwissSkullStripper. I have tested it with my local Slicer build. Now I would like to replace the old version.

When I  
make ExperimentalUpload

I get the error:

```auto
Call Stack (most recent call first):
  /home/lorensen/ProjectsGIT/Slicer/Extensions/CMake/SlicerExtensionPackageAndUploadTarget.cmake:260 (midas_api_upload_extension)

CMake Error at /home/lorensen/ProjectsGIT/Slicer/Extensions/CMake/SlicerExtensionPackageAndUploadTarget.cmake:288 (message):
  Upload of
  [73236f9-linux-amd64-SwissSkullStripper-git307bf86-2017-04-21.tar.gz]
  failed !

  Check that:

  (1) you have been granted permission to upload

  (2) your email and api key are correct

 Size of output: 8K
Command exited with the value: 0
MakeCommand:/usr/bin/cmake --build . --config "Release" --target "packageupload" -- -i
Error(s) when building project
   1 Compiler errors
   2 Compiler warnings
SetCTestConfiguration:BuildDirectory:/home/lorensen/ProjectsGIT/SwissSkullStripperExtension/build
SetCTestConfiguration:SourceDirectory:/home/lorensen/ProjectsGIT/SwissSkullStripperExtension/build
SetCTestConfiguration:ProjectName:SwissSkullStripper
SetCTestConfiguration:DropMethod:http
SetCTestConfiguration:DropSite:
SetCTestConfiguration:DropLocation:/submit.php?project=Slicer4
SetCTestConfiguration:IsCDash:TRUE
Submit files (using http)
   Send to track: Extensions-Experimental
   Using HTTP submit method
   Drop site:http:///submit.php?project=Slicer4
   Upload file: /home/lorensen/ProjectsGIT/SwissSkullStripperExtension/build/Testing/20170421-1823/Build.xml to http:///submit.php?project=Slicer4&FileName= ___73236f9-SwissSkullStripper-git307bf86-g%2B%2B-64bits-Qt4.8-Release___ 20170421-1823-Extensions-Experimental ___XML___ Build.xml&MD5=e6d1eb2838f4ac2a0e8f2037732b710f Size: 3890
   Error when uploading file: /home/lorensen/ProjectsGIT/SwissSkullStripperExtension/build/Testing/20170421-1823/Build.xml
   Error message was: Empty reply from server
   Problems when submitting via HTTP
Uploading package URL for extension SwissSkullStripper ...
make[3]: *** [CMakeFiles/ExperimentalUpload] Error 255
make[2]: *** [CMakeFiles/ExperimentalUpload.dir/all] Error 2
make[1]: *** [CMakeFiles/ExperimentalUpload.dir/rule] Error 2
make: *** [ExperimentalUpload] Error 2
[build(master)]

```

---

<div class="post-metadata">

### Author: ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)
#### Post date: [April 21, 2017, 6:38pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/2 "2017-04-21T18:38:59Z")

</div>

You can test extension packaging and install locally: Build a package and install it in the Extension manager (click the small “wrench” icon in the top-right corner). If all works well then push the updated version and update the git hash in the ExtensionsIndex repository.

The ExperimentalUpload target is only for testing if the extension upload mechanism works correctly. As this mechanism is quite robust (I don’t remember the factory machines having any problem with uploading), you don’t need to test it. If you would like to test it anyway then you need to get an API key and pass it to CMake when you configure the extension (see details here: [https://www.slicer.org/wiki/Documentation/Nightly/Developers/Tutorials/BuildTestPackageDistributeExtensions](https://www.slicer.org/wiki/Documentation/Nightly/Developers/Tutorials/BuildTestPackageDistributeExtensions)).

---

<div class="post-metadata">

### Author: ![Lorensen](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lorensen/32/31_2.png) [@Lorensen](https://discourse.slicer.org/u/Lorensen)
#### Post date: [April 21, 2017, 6:40pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/3 "2017-04-21T18:40:20Z")

</div>

I have an old API key. Should that still work.

---

<div class="post-metadata">

### Author: ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)
#### Post date: [April 21, 2017, 6:41pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/4 "2017-04-21T18:41:31Z")

</div>

I think they have an expiry date. You can probably check it in Midas if it is still active.

---

<div class="post-metadata">

### Author: ![Lorensen](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lorensen/32/31_2.png) [@Lorensen](https://discourse.slicer.org/u/Lorensen)
#### Post date: [April 21, 2017, 6:48pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/5 "2017-04-21T18:48:06Z")

</div>

Yes, it had expired…  
I deleted the old one, the the “Generate new API key” does nothing…

---

<div class="post-metadata">

### Author: ![Lorensen](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lorensen/32/31_2.png) [@Lorensen](https://discourse.slicer.org/u/Lorensen)
#### Post date: [April 21, 2017, 6:53pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/6 "2017-04-21T18:53:56Z")

</div>

I see, it wanted an Application Name.

---

<div class="post-metadata">

### Author: ![Lorensen](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lorensen/32/31_2.png) [@Lorensen](https://discourse.slicer.org/u/Lorensen)
#### Post date: [April 21, 2017, 6:58pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/7 "2017-04-21T18:58:48Z")

</div>

I still get the same error on the ExperimentalUpload. BTW, the documentaion mentions the target ExperimentalUploadOnly, but that target does not exist.

---

<div class="post-metadata">

### Author: ![jcfr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jcfr/32/17825_2.png) [@jcfr](https://discourse.slicer.org/u/jcfr)
#### Post date: [April 21, 2017, 9:59pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/8 "2017-04-21T21:59:24Z")

</div>

> [@Lorensen](#):
>
> I see, it wanted an Application Name.

Make sure application name is `Default`

> [@Lorensen](#):
>
> I still get the same error on the ExperimentalUpload. BTW, the documentaion mentions the target ExperimentalUploadOnly, but that target does not exist.

Good catch. We need to update the documentation. That target has been removed.

See [http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=24289](http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=24289)

You could instead do

```bash
make uploadpackage

```

I will fix the corresponding documentation: [Documentation/Nightly/Developers/FAQ/Extensions - Slicer Wiki](https://www.slicer.org/wiki/Documentation/Nightly/Developers/FAQ/Extensions#What_are_the_extension_specific_targets:_ExperimentalUpload.2C_ExperimentalUploadOnly.2C_)…\_.3F

---

<div class="post-metadata">

### Author: ![jcfr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/jcfr/32/17825_2.png) [@jcfr](https://discourse.slicer.org/u/jcfr)
#### Post date: [April 21, 2017, 10:11pm UTC](https://discourse.slicer.org/t/updating-an-extension/169/9 "2017-04-21T22:11:03Z")

</div>

> [@jcfr](#):
>
> I will fix the corresponding documentation

@Lorensen I updated the [developer documentation](https://www.slicer.org/wiki/Documentation/Nightly/Developers/FAQ/Extensions#What_are_the_extension_specific_targets:_ExperimentalUpload.2C_ExperimentalUploadOnly.2C_..._.3F). Would appreciate if could let me know if there are other currences.
