Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

We have a development project in Python (ArcGIS 10). This project involves a mixture of toolboxes, map templates, layer files, file geodatabase templates (acting as templates being imported into a map by scripts) and various other things.

We use Eclipse as our source editor and SVN as our Source Code Repository.

Though we have a problem with keeping all the files (that aren't py files) in a synchronised project by everyone. The toolbox routinely gets messed up by multiple people editing the toolbox and then template files get adjusted and then not updated for other people as they are not checked back in.

How are people in organisations with more than one python developer on a company toolbox project ensuring that the project and all the different files are get versioned and managed correctly? Or is it a case through everything goes into Eclipse (including template layers and GDB's used by the scripts) into the project and hope that people check out the files correctly?

Many thanks Rob

share|improve this question
    
So you have everything currently in SVN (templates, layer files, source code, toolboxes)? Is the problem that some people just aren't checking in properly? –  Chad Cooper Nov 19 '12 at 15:00
    
Except layer files and template datasets. Yes they are not checking in when they are finished and also in Eclipse you have to (as far as I know) manually update to the latest version to get the latest version of a file (e.g. tbx). I'm just wondering if others have got a smarter way of doing this then we are attempting at the moment –  Rob Nov 19 '12 at 15:18

5 Answers 5

up vote 5 down vote accepted

If I know that I am going to working with other developers, one of the first things I do nowadays is to setup a Continuos Integration server like Jenkins.

The idea is to always trigger your test suite after every check-in and you will get an automated e-mail right away if it fails. In your case, it could be a simple Selenium script. That clicks around a browser, or some ArcObjects script that automates ArcMap. There are several presentations out there about Selenium.

The cool thing about Jenkins, is that there are several plugins that allow you to integrate/leverage other technologies (build systems, lint, etc). You can get awesome reports about how much of your code is being covered by the test. They are really easy to setup.

Personally, instead of SVN, I like to integrate with Git and GitHub... there are several advantages of doing this like relying on GitHub for authentication.

But of course, the first step is to get Jenkins running. If you have never done it, reserve one day and breathe a lot since it can be very quirky... but once you have it running, it is really awesome.

share|improve this answer

If I understood well, one of your problems is that developers are not using properly the SVN and this, lets the content in the SVN repository unstable.

So maybe you can try a couple of things:

Set a clear repository use policy

Make it clear to all the developers the way to use the repository and when and what to commit. So the repository always have working copy of the project.

Use a distributed control system

If you use a distributed control system like Git or Mercurial, each user can commit to their repository and only send their versions to a centralized one when they are sure it will work, you can maybe even set windows of commit for each user so they don't step on each others code.

Saying this, in your case I'd go for Mercurial, because it's developed in Python and you can create hooks to tailor it to your needs. And because the learning curve from SVN it's quite easy... a good point to start is hginit tutorial, that actually have a section called SVN re-education.

share|improve this answer

I think you need somebody in charge and more accountability. My suggestion would be to appoint or recruit an administrator for the toolbox(es). Make the public toolbox and everything in its space read-only except to the administrator. The administrator can be responsible for making sure things get tested, checked in (or managed--in the case of items outside of SVN space). Since the administrator will get a chance to see what people are doing, he/she will know when someone needs training, i.e., he can catch people doing things improperly.

share|improve this answer

This is a people problem rather than a technology problem. The toolbox and the template files are being edited outside of Source Control, so there is no control over it. These files should be in version control even though they are binary files and you can't diff or compare them. As a general rule of Thumb, anything that is not generated from your code, and is required to run or compile the code, should be under Source Control.

That way the entire project will be under the source control, and there will always be a working copy. The developers should edit the toolbox and template in their local version after locking and commit back when their local copy is working.

As to

...not updated for other people as they are not checked back in

This is a people problem, and unless all your developers understand why this is important, no amount of technology is going to help.

share|improve this answer

The toolbox routinely gets messed up by multiple people editing the toolbox

For this particular problem, we put our toolbox in an ArcSDE Database. I haven't try with other type of database! Unless two persons edit the same tool at the same time, it work great. Really less problems than with file toolbox (.tbx).

share|improve this answer
    
Are you saying that you version the toolbox in SDE so that multiple people can edit the different tools at the same time? You haven't had any problems with this approach? –  Arabella Jun 3 '13 at 7:05
    
No, I don't think you can version a toolbox. You just create a toolbox in SDE. And multiple people can edit different tools at the same time. Two problems, obviously if someone edit the same tool and as ArcToolbox load the content at the opening of the toolbox(SDE) and keep it in memory, if someone else open a tool that has been edit since the opening of the toolbox(SDE). The later can be minimized as if it's known, you can resart ArcMap or you can close the SDE connection and re-open it. Hopes this is clear. –  jeb Jul 31 '13 at 23:21

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.