prepareForEdit exceptions

Recently, I have been noticiing that I am getting lots of prepareForEdit exceptions. I am getting the exception like follows:

2009-11-06 00:17:46,652 INFO [STDOUT] com.percussion.webservices.PSErrorResultsException
2009-11-06 00:17:46,652 INFO [STDOUT] at com.percussion.webservices.content.impl.PSContentWs.prepareForEdit(Unknown Source)

The code looks like this:

List<IPSGuid> guidList = Collections.<IPSGuid> singletonList(pageGuid);
List<com.percussion.services.content.data.PSItemStatus> statusList = cws.prepareForEdit(guidList);
List<PSCoreItem> items = cws.loadItems(guidList, false, false, false,false);
PSCoreItem pageItem = items.get(0);

Not sure what could be the problem

I would assume that pageGuid is an actual guid? Ie i get the content item and then do something like:


IPSGuid itemGuid = gmgr.makeGuid(new PSLocator(contentID));

A la documentation, prepareForEdit does throw an exception, so you should be prepared to catch it as well…(ie if someone else has checked out that item…). From that error it seems like it doesn’t know about the pageGuid…perhaps the search index hasn’t indexed that item yet? (if you just imported)…