From 230960a22eedf06149ce64c2275591664cf592b4 Mon Sep 17 00:00:00 2001 From: Igor Nogueira de Oliveira Date: Thu, 7 May 2026 14:16:02 -0300 Subject: [PATCH] Notify now honors `withpath` parameter Notify should not represent a state of a resource since it only "exists" during execution time. This change proposes that it should be considered to always "exist", thus avoiding a change notification. Signed-off-by: Igor Nogueira de Oliveira --- lib/puppet/type/notify.rb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/lib/puppet/type/notify.rb b/lib/puppet/type/notify.rb index 81bda653f9..73b38565c5 100644 --- a/lib/puppet/type/notify.rb +++ b/lib/puppet/type/notify.rb @@ -11,7 +11,7 @@ module Puppet newproperty(:message, :idempotent => false) do desc "The message to be sent to the log. Note that the value specified must be a string." - def sync + def insync?(is) message = @sensitive ? 'Sensitive [value redacted]' : should case @resource["withpath"] when :true @@ -19,17 +19,13 @@ def sync else Puppet.send(@resource[:loglevel], message) end - nil + true end def retrieve :absent end - def insync?(is) - false - end - defaultto { @resource[:name] } end