faker-ruby/faker · error · ArgumentError

#{tax_order} is not a valid taxonomic order

Error message

#{tax_order} is not a valid taxonomic order

What it means

Error "#{tax_order} is not a valid taxonomic order" thrown in faker-ruby/faker.

Source

Thrown at lib/faker/creature/bird.rb:148

        # Produces a random common name for a bird
        #
        # @param [String | Symbol | nil] tax_order Tax
        # @return [String]
        # @raises TypeError If `tax_order` cannot be converted into a Symbol
        # @raises ArgumentError If `tax_order` is not a valid taxonomic order
        #
        # @example
        #   Faker::Creature::Bird.common_name #=> 'wren'
        #
        # @faker.version next
        def common_name(tax_order = nil)
          map = translate('faker.creature.bird.order_common_map')
          if tax_order.nil?
            sample(map.values.flatten).downcase
          else
            raise TypeError, 'tax_order parameter must be symbolizable' \
              unless tax_order.respond_to?(:to_sym)
            raise ArgumentError, "#{tax_order} is not a valid taxonomic order" \
                                 unless map.keys.include?(tax_order.to_sym)

            the_order = translate('faker.creature.bird.order_common_map')[tax_order.to_sym]
            sample(the_order).downcase
          end
        end

        ##
        # Produces a random and plausible common name for a bird
        #
        # @return [String]
        #
        # @example
        #   Faker::Creature::Bird.plausible_common_name #=> 'Hellinger's Wren'
        #
        # @faker.version next
        def plausible_common_name
          parse('creature.bird.plausible_common_names').capitalize

View on GitHub (pinned to cca4184947)

When it happens

Trigger: Thrown at lib/faker/creature/bird.rb:148 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of faker-ruby/faker@cca4184947 (2026-08-21). Data as JSON: /api/errors/6866b3ad181e4b9c. Report an issue: GitHub.