{"record":{"id":"3bbdd0b0b6b47ef8","repo":"puppetlabs/puppet","slug":"the-loaded-fiddle-version-is-not-supported","errorCode":null,"errorMessage":"The loaded Fiddle version is not supported.","messagePattern":"The loaded Fiddle version is not supported\\.","errorType":"exception","errorClass":"LoadError","httpStatus":null,"severity":"critical","filePath":"lib/puppet/util/at_fork/solaris.rb","lineNumber":10,"sourceCode":"# frozen_string_literal: true\n\nrequire_relative '../../../puppet'\nrequire 'fiddle'\n\n# Early versions of Fiddle relied on the deprecated DL module and used\n# classes defined in the namespace of that module instead of classes defined\n# in the Fiddle's own namespace e.g. DL::Handle instead of Fiddle::Handle.\n# We don't support those.\nraise LoadError, _('The loaded Fiddle version is not supported.') unless defined?(Fiddle::Handle)\n\n# Solaris implementation of the Puppet::Util::AtFork handler.\n# The callbacks defined in this implementation ensure the forked process runs\n# in a different contract than the parent process. This is necessary in order\n# for the child process to be able to survive termination of the contract its\n# parent process runs in. This is needed notably for an agent run executed\n# by a puppet agent service to be able to restart that service without being\n# killed in the process as a consequence of running in the same contract as\n# the service, as all processes in the contract are killed when the contract\n# is terminated during the service restart.\nclass Puppet::Util::AtFork::Solaris\n  private\n\n  {\n    'libcontract.so.1' => [\n      # function name,            return value type, parameter types, ...\n      [:ct_ctl_abandon,          Fiddle::TYPE_INT,  Fiddle::TYPE_INT],\n      [:ct_tmpl_activate,        Fiddle::TYPE_INT,  Fiddle::TYPE_INT],","sourceCodeStart":1,"sourceCodeEnd":28,"githubUrl":"https://github.com/puppetlabs/puppet/blob/e227c27540975c25aa22d533a52424a9d2fc886a/lib/puppet/util/at_fork/solaris.rb#L1-L28","documentation":"Raised at require time by puppet/util/at_fork/solaris.rb when the Fiddle library loads but does not define Fiddle::Handle. Early Fiddle releases (on old Rubies) still delegated to the deprecated DL module and exposed DL::Handle instead; Puppet's Solaris at-fork handler (which keeps the child process in a different process contract so a service restart does not kill a running agent) needs real Fiddle classes, so it raises LoadError immediately. This aborts loading the Solaris at-fork support, not arbitrary Puppet code.","triggerScenarios":"Running Puppet on Solaris with a Ruby whose Fiddle predates the namespace migration (roughly Ruby < 2.0-era Fiddle/DL hybrids or a hand-built libfiddle); installing the puppet gem against the OS's ancient system Ruby instead of a packaged ruby; anything that requires puppet/util/at_fork/solaris on such a Ruby.","commonSituations":"Solaris zones/older Solaris 10-11 images where the default Ruby is ancient; gem installs instead of the puppet-agent all-in-one package; upgrading Puppet but leaving the old system Ruby in place.","solutions":["Install the puppet-agent (puppetlabs) package, which bundles a modern Ruby and Fiddle","Or upgrade the system Ruby to a release whose Fiddle defines Fiddle::Handle (2.1+)","Verify with: ruby -rfiddle -e 'puts defined?(Fiddle::Handle)' — it must print 'constant'"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"require 'fiddle'\nunless defined?(Fiddle::Handle)\n  abort 'Fiddle too old (DL-backed); upgrade Ruby or install the puppet-agent package'\nend","typeGuard":null,"tryCatchPattern":"begin\n  require 'puppet/util/at_fork/solaris'\nrescue LoadError => e\n  # e.message == 'The loaded Fiddle version is not supported.'\n  warn 'unsupported system Ruby on Solaris; switch to puppet-agent bundled Ruby'\nend","preventionTips":["Prefer the puppet-agent package (bundled Ruby+Fiddle) over gem-on-system-Ruby on Solaris","Pre-flight check: ruby -rfiddle -e 'puts defined?(Fiddle::Handle)' must print constant","Keep Solaris hosts on a supported Ruby (2.1+) when running Puppet from gems"],"tags":["puppet","solaris","fiddle","ruby-version","load-error"],"backgroundTag":"unsupported-library-version","analyzedSha":"e227c27540975c25aa22d533a52424a9d2fc886a","analyzedAt":"2026-08-21T20:49:46.650Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}