problem with test (Re: [Bro-Commits] [git/bro] master: Merge remote-tracking branch 'origin/topic/robin/pp-alarms' (ec2a8d7))

With my recent alarm mail changes, I now see one test failing with
master and I have no clue why. Any idea?

Robin

scripts.base.frameworks.control.configuration_update ... failed
  % 'btest-diff controllee/.stdout' failed unexpectedly (exit code 1)
  % cat .diag
  == File ===============================
  ORIGINAL VALUE (this should be printed out first)
  ORIGINAL VALUE (this should be printed out first)
  == Diff ===============================
  --- /tmp/test-diff.22007.controllee..stdout.baseline.tmp 2011-10-26 22:27:52.570262720 +0000
  +++ /tmp/test-diff.22007.controllee..stdout.tmp 2011-10-26 22:27:52.580263105 +0000
  @@ -1,2 +1,2 @@
  ORIGINAL VALUE (this should be printed out first)
  -NEW VALUE (this should be printed out second)
  +ORIGINAL VALUE (this should be printed out first)

It looks like you probably have a left over Bro process hanging around. Bro that btest started couldn't open it's port.

  .Seth

Nevermind, I'm seeing a different error for this test. I'll take a look right now.

  .Seth

Thanks, once we have that fixed, I'll roll up a test package.

Robin

I can't get it to work. Is there some reason the send_id BiF could have broken?

  .Seth

One more thing, the communication.log file for the controller has these error messages:

  1319738043.456203 bro parent - - - error [#1/127.0.0.1:65531] serializing ID: failed
  1319738043.456203 bro parent - - - error fatal error, shutting down communication: Resource temporarily unavailable [35]
  1319738043.456203 bro parent - - - error fatal error, shutting down communication: Operation timed out [60]

It definitely looks like there is something wrong with the send_id BiF.

  .Seth

I didn't touch anything even remotely related to that I believe. But
perhaps some change triggered something we haven't before. I'll dig
into it.

Robin

Found it: it's the redefable global function. Something's in there
doesn't seem to (un-)serialize well. But sending complete functions
around isn't really supported anyway, so I think we can just stop
trying to update functions on the fly.

Seth, is there anything that relies on that? (It would still send the
notice_policy because the top-level ID for that is a table; in
principle, the function in there could cause similar trouble, but that
seems unlikely).

Robin

Found it: it's the redefable global function.

Hm, the control framework only tries to update consts. I'm surprised it's even trying to send it unless functions are actually const internally even though they're declared global.

Seth, is there anything that relies on that? (It would still send the
notice_policy because the top-level ID for that is a table; in
principle, the function in there could cause similar trouble, but that
seems unlikely).

Not that I can think of. I've had the notion of sending functions in mind for a while and I think it would be great to be able to do that (primarily at first for live updates to the notice policy at first as you indicated) but for now we can just cut out functions.

  .Seth

Yes, I think that's the case. The global_ids() call indicates it's
const (and technically that's right in the sense that the global does
have a constant value because there's no way to change it).

Robin