3

当我运行我的 Kynetx 应用程序时,我收到以下错误:

Can't use an undefined value as an ARRAY reference at /web/lib/perl/Kynetx/Persistence.pm line 284, <GEN0> line 465. 

我的代码如下所示:

rule page_loaded is active {
  select when pageview "manticore.*" setting()
  pre {
    savedName = current ent:userName;
  }
  if (savedName neq "") then {
    notify("Hello #{savedName}!!","Welcome back!") with sticky = true;
  }
  notfired {
    raise explicit event name_not_saved_yet;
  }  
}  

我之前有这段代码工作过,现在不知道是什么杀死了它。

更新: 来自调试信息。

// 2010/12/07 16:45:31 DEBUG Scheduler.pm a57x4 clear_saved_name Schedule iterator returning email_client with current RID count 0 and current rule count 3
// 2010/12/07 16:45:31 DEBUG Rules.pm a57x4 email_client Rule email_client is active
// 2010/12/07 16:45:31 DEBUG Rules.pm a57x4 email_client [selected] email_client
// 2010/12/07 16:45:31 DEBUG Rules.pm a57x4 email_client
//------------------- begin rule execution: email_client ------------------------
// 2010/12/07 16:45:31 ERROR Rules.pm a57x4 email_client Ruleset a57x4 failed: Can't use an undefined value as an ARRAY reference at /web/lib/perl/Kynetx/Persistence.pm line 284, <GEN0> line 6. 
4

1 回答 1

3

我们改变了存储轨迹的方式。我会尽快修复错误。

如果我向您展示一些秘密功能,您需要保证不告诉

对于您的实体变量,请尝试使用语法(如果您有变量 myUserName):

 set ent:userName myUserName

然后,对于您的示例,您可以编写:

pre {
  savedName = ent:userName || "";
}
if (savedName neq "") then ....

当我们发布修复程序时,我会更新这个答案

于 2010-12-08T00:00:46.933 回答