But it works on my PC!

The random thoughts of Richard Fennell on technology and software development

‘TF400499: You have not set your team field’ when trying to update Team Settings via the TFS API

I have recently been automating TFS admin processes such as creating a new team within an existing team project. The TFS team is now our primary means we use to segment work so we need to create new teams fairly often, so automation makes good sense.

As far as I can see, there are no command line tools, like TF.EXE or WITADMIN.EXE, to do most of the team operations. They are usually browser based. So I have been using PowerShell and the TFS API for the automation.

I hit the problem that when trying to save the team’s backlog iteration, iteration paths etc. for a newly created team using  the SetTeamSettings method. I was seeing

Exception calling "SetTeamSettings" with "2" argument(s): "TF400499: You have not set your team field."
At C:\Projects\tfs2012\TFS\PowerShell\Set-TfsTeamConfig.ps1:37 char:1
+ $configSvc.SetTeamSettings($configs[0].TeamId , $configs[0].TeamSettings)
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : SoapException

This was strange as I had previously tested my PowerShell script file with hard coded values to update an existing team without error. When I inspecting the parameters being passed all looked OK, I had set a value for the team field and the read only property defining where to store the team data was correct (into the AreaPath).

After far to long I realised the problem was I had set the team field to the correct value e.g. ‘My project\My team’, but I had not created this area path before trying to reference it. Once I had created the required area path my scripted worked as expect.

So the TF400499 error is a little confusing, it does not mean ‘not set’ but ‘not set to a valid value’

When you think it cannot get worse...

... you end up presenting at TechEd.

Yesterday was fun (of a sort) I ended up doing the demo section of the ESB Guidance session at TechEd. This session was scheduled to be done by Robert Hogg (Black Marble) and Ewan Fairweather (Microsoft) but Ewan had to fly home early unexpectedly on Friday morning, so leaving somewhat of a gap.

So you say, 'that is not too bad you just step in and do the prepared and scripted demo'. Well in a perfect world you would, but about 6 hours before our session was on the formal release of  ESB 1.0 was posted to the MSDN site. As our demo was based on a CTP build, and as we knew the final release was somewhat different, we thought it only right to at least show the new documentation and file structures. So a hectic few hours were had by all.

I hope anyone attended the session go what they wanted out to if. I had to leave for my flight soon after the session so have heard no feedback other than the people who came to chat at the end of the session, who seemed happy. I am sure Robert will know more when he gets back, as his flight was later he had time to return to the olympian heights of the speaker lounge to once more feast upon unicorn steaks and ambrosia (well get coffee in a proper cup not a paper one at least).

As I made the mistake of not changing my TechEd speakers shirt before the flight home, not realizing the shirt made me look like a member of EasyJet staff, my outstanding question is - is there any future event in my life where the lovely grey/blue with orange trim TechEd speakers shirt is appropriate wear?

TechEd Barcelona - update

I have not been blogging much from here have I, it is not that the sessions are not that interesting, but no single item has been giving me an huge urge to write.

As I said in my last post I think this is a conference of best practice ideas and as such you tend to pick up a useful nugget here and there which you store away for future use. This is particularity relevant as at present I am reviewing our engineering process to improve our software development life cycle.

Like many companies we use a variety of tools beyond Visual Studio such as CruiseControl, nUnit and our own home grown work tracking system. I have to consider when it is advantageous to swap these for the new features in Visual Studio Team System 2008. Being pragmatic this is always going to be a slow migration, these is little point investing time in moving an old project that barely still under maintenance to a new system. In fact I have chosen to only move our active projects from our old SourceSafe based system to TFS at a major release point, e.g. V1 to V2, snap-shoting it at this point and not bothering to bring over all the change history.

The tools round the edge is another question. If you, as we do, have an investment in nUnit and CruiseControl for projects is there any good case to rework everything to MSTEST and TFS Build? In the long term I think the answer is yes, to get a unified end to end solution, but it is hard to justify the time to do an 'instant' swap over, so again it will be slow move. Especially when you can use a combined system e.g. have old testing nUnit and new ones in MSTEST pulling it all together with CruiseControl which can happily access the TFS SCC, build using MSBUILD and run all the testing frameworks.

 

Anyway Roy Osherove is tuning up his guitar for a session on testing to time to go....

No sizzle and not much sausage

The keynote at TechEd was as expected, we all knew about the impending release  of VS2008, and still no fixed date yet (so no sausage there) and not really anything announced product wise that was not already in the blog sphere (so no real sizzle).

I think this is going to be conference on delivering on last years promises; how to get the best from the tools and technology announced last year, now that they are now really production ready and the early adopters have had a year to play with them.

My suggestion to all attendees - check the sessions with the real world experience. Due to the CTP and beta programs, there are some real experts out there on these products and many of them are presenting here (or in the audiences at the number interactive sessions).

How to create a community

Just come out of an interesting set of round table events for 'community influencers' at TechEd. These are people who are active in both the online and face-to-face communities from all round Europe (and Australia - the reach of TechEd Europe!) attended.

In the sessions I went to the general discussion was on the point I posted about a few weeks ago and that had been a running conversions on a number of UK blogs. I was refeshing (or sad?) to find the problems we have seen at home over attendance are the same around Europe:

  • It is hard to get people to attend events in the evening
  • It is hard to convert attendees to active community members
  • A very small percentage of people who view online forums contribute.

As you would expect there is no single answer, and for most ideas there was someone to say 'we tried that and it did not work for us'. However, it did come out that things that fail for one group work for others - there is no silver bullet. So try anything and everything to get people engaged.

A general it was felt 'marketing presentations' do not draw people in, neither do events that cover what can be found on-line. Most people agreed that events, maybe in a panel or round table format, that provide real world experience or 'war stories' as I call them are often the ones that get the most interest. Of cause it helps if the speaker presents in an engaging style, but this is mitigated if you can get the whole room involved.

From my experience some of the most interesting community events  have been to are technology agnostic and focus on general development for project management issues, notably in a group workshop style. Such as those at the Extreme Programming club, but even with this interesting content this group has struggled for number. As I said before the fact I like technology agnostic groups, as a NET developer I know there is much I can learn from Java developers and vice-versa, does not mean that this is right for all.

There was an underlying discussion of how many people in the industry were looking to the community as a means to professional development, as opposed to IT being just a job that ended at 5pm. Moving the latter group into  being hard - can you engage people who have lost the 'joy for their career'?

I am sure this pre conference event will generate some online activity, keep an eye out for it.

If it is Monday it must be Barcelona

What an awful journey I have had since my last post, the trip back from the USA was fine; the problems started getting from the UK to Spain. Basically fog at Liverpool stopped all flights so we had to change airline and airport to get here in time for the TechEd conference. Should have been here by noon on Sunday and actually got here nearer 9pm, so no sigh seeing for me.

Anyway registered and at the conference venue now, so let it begin.....

Last day at SOA - day 4

Seems quiet here today at the SOA conference, less people about. I wonder how many have sneaked off early for flights? It does seem to be mostly Europeans left, judging by the languages I have heard.

This does not mean parking was easy this morning, as in the same conference center Bill Gates and Bill Clinton are speaking at an MSPAC event. Now a bit of google'ing shows MSPAC is either:

  1. Microsoft Political Action Committee 
  2. Resources for Ms. Pac-Man(www.mspac.com)
  3. Maple Syrup Producers Association of Connecticut

I really hope it is one the last two, but I doubt it.

I always thing the best thing you can bring away from conferences such as this are best practice and gotta's, to that end I saw a great session by Stephen Thomas on best practice with orchestrations, you can find his sample and slides on www.biztalkgurus.com

So that's it for the SOA conference, off to the airport now, about 12 hours at home in the UK then off to TechEd in Barcelona. Oh what a jet set life I lead.