[RavenclawDev 170] problems with resetting an agent
Svetlana Stenchikova
svetastenchikova at gmail.com
Sat Oct 28 01:05:59 EDT 2006
Hi,
I am trying to createan agent (CIdSingleFilter defined below) which
identifies a single event in a database.
It asks user to specify the type, date, time criterion until only one event
matches.
eventlistresult is an array concept which is declared in an agency above and
gets filled in by the GetEvents
NoMatch, RequestClarify, AskWhich are the inform agents which get activated
depending on the content of eventlistresult
In order to simulate a loop I call ResetThisAgent, which calls RESET_AGENT
on IdSingleFilter.
If SIZE(eventlistresult)== 1, the agency successfully completes.
I would expect that if SIZE(eventlistresult)!= 1, then ResetThisAgent, would
place all of the subagents of IdSingleFilter back on stack and continue the
loop.Instead I get an exception:
***************************************************************************
[COR at 00:52:53.563] Executing dialog agent
/RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter ...
[WAR at 00:52:53.566] Failure information for Agency
/RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/NoMatch has not
completed, does not have preconditions satisfied, and is not blocked.
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/RequestClarify has
completed, does have preconditions satisfied, and is not blocked.
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/AskWhich has not
completed, does not have preconditions satisfied, and is not blocked.
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/QueryFilter has
completed, does have preconditions satisfied, and is not blocked.
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/DBGetEvents has
completed, does have preconditions satisfied, and is not blocked.
Agent /RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter/ResetThisAgent has
completed, does have preconditions satisfied, and is not blocked.
<file c:\documents and settings\sveta\my
documents\work\calendar\ravencalendar\libraries\ravenclaw\dmcore\agents\dialogagents\basicagents\dialogagency.cpp,
line 183>.
[FATAL_ERROR at 00:52:53.566] Agency
/RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter failed to complete.
<file c:\documents and settings\sveta\my
documents\work\calendar\ravencalendar\libraries\ravenclaw\dmcore\agents\dialogagents\basicagents\dialogagency.cpp,
line 149>.
***************************************************************************
Can you tell if something is wrong with my logic?
thank you
//-----------------------------------------------------------------------------
// /RavenCalendar/Task/IdSingleFilter
//-----------------------------------------------------------------------------
DEFINE_AGENCY( CIdSingleFilter,
IS_MAIN_TOPIC()
// BOOL_SYSTEM_CONCEPT(backend_error))
DEFINE_SUBAGENTS(
SUBAGENT(NoMatch, CNoMatch, "")
SUBAGENT(RequestClarify, CRequestClarify, "")
SUBAGENT(AskWhich, CAskWhich, "") //undefined num
SUBAGENT(QueryFilter, CQueryFilter, "") //agency getting concepts
SUBAGENT(DBGetEvents, CDBGetEvents, "") // get the list
SUBAGENT(ResetThisAgent, CResetThisAgent, "")
)
SUCCEEDS_WHEN(AVAILABLE(eventlistresult) && SIZE(eventlistresult)==1)
)
//---------------------------------------------------------------------------
//
//--------------------------------------------------------------------
DEFINE_EXECUTE_AGENT( CResetThisAgent,
RESET_AGENT(..)
)
also tried
//---------------------------------------------------------------------------
//
//--------------------------------------------------------------------
DEFINE_EXECUTE_AGENT( CResetThisAgent,
RESET_AGENT(/RavenCalendar/Task/TaskRemoveEvents/IdSingleFilter)
)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.srv.cs.cmu.edu/pipermail/ravenclaw-developers/attachments/20061028/f6ac9720/attachment.html
More information about the Ravenclaw-developers
mailing list