Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4001726
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T07:56:24+00:00 2026-05-20T07:56:24+00:00

I am getting this error when calling a builder template from sinatra route: wrong

  • 0

I am getting this error when calling a builder template from sinatra route:

wrong number of arguments (1 for 0)

Sinatra – 1.1.2

Builder – 3.0.0

MongoMapper – 0.8.6

Calling it like this:

get '/current_load.xml' do
  @caption = "Load Average"
  @sub_caption = "5 minutes"

  @time = Performance.where(:NAGIOS_SERVICEDESC => "Current Load").fields(:NAGIOS_LONGDATETIME).all

  content_type :xml
  builder :current_load
end

the builder file starts off like this:

xml.instruct!

Here’s the full trace of the error:

ArgumentError - wrong number of arguments (1 for 0):
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlbase.rb:135:in `to_xs'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlbase.rb:135:in `_escape'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlbase.rb:140:in `_escape_quote'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:320:in `_attr_value'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:308:in `_insert_attributes'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:306:in `each'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:306:in `_insert_attributes'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:284:in `_special'
 /usr/lib/ruby/gems/1.8/gems/builder-3.0.0/lib/builder/xmlmarkup.rb:250:in `instruct!'
 /opt/nec/www/nec/views/current_load.builder:1:in `evaluate_source'

If I change Builder to 2.1.2, I receive no error
or
If I take MongoMapper out I receive no error

Sounds like an issue between two gems??

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T07:56:25+00:00Added an answer on May 20, 2026 at 7:56 am

    Sinatra 1.1.3 successfully fixed this error.

    That is the only change in the environment

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I keep getting a error:undefined message when calling this AJAX method. $.ajax({ type: GET,
I am getting this error when calling a web service method which writes to
Getting a VerifyError using the TweenMax lib when calling TweenMax.to . This error doesn't
Am getting this error message and matched my brackets and couldn't find anything wrong.
I'm getting this error when calling a java web service. I'm using the same
I am getting this error while calling $.ajax methods Error: [Exception... Access to restricted
Im getting this routing error No route matches {:controller=>posts, :action=>show} when i click on
I am getting this error when i am calling a Hibernate Criteria with hibernate
I am following this example . I keep getting this error whenever calling upon
When I am calling getrowdata() I am getting this error $t.p.colModel[i] is undefined in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.