similar to: Where to put Exceptions

Displaying 20 results from an estimated 200000 matches similar to: "Where to put Exceptions"

2006 Apr 05
1
where do you put Classes in RoR
I''m just trying RoR and it works very smoothly. I''am also somewhat familiar with ruby however I do not know where my Classes are supposed to go in RoR. E.g. my ruby file looks like include a_few_lib_here Class function_name def aaaa end end #main program yadayada = function_name(parameter) I understand: - the main program goes in a controller I have to create - but
2006 Apr 11
2
How do I apply a patch to Rails?
Hi, How do I apply a patch to Rails? >From what I can find it looks like I need to be running on the latest version from SVN. I don''t want to do that however. I have also tried applying the changes to the .rb file concerned, but that didn''t seem to work. Martin -- Posted via http://www.ruby-forum.com/.
2006 Apr 17
0
Where is the correct place to put custom exception classes?
I would like to create a custom exception class for my app. Where is the best place for it and is there any facility in Rails to make it easy for me to have access to my exceptions? Thanks, Wes -- Posted via http://www.ruby-forum.com/.
2008 Jul 01
4
Exceptions available in Ruby on Rails
Hi, Can anybody list out what are all the exceptions available in ROR? Thanks in advance... Karthik. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to
2006 Mar 07
10
Star Rating Component?
Hi, I''m looking for a star rating component for RoR, a bit like Votio (http://redalt.com/downloads/ - find the votio heading) or the star rating used on Amazon. I don''t really need the AJAX capabilities, just the ability to bind the results to a hidden drop down, or radio inputs. Multiple raters per page is also an issue. Any recomendations? -- Posted via
2006 May 30
0
Where to put new macros?
I want do add a new macro based on to auto_complete.rb but I don''t know where to put it inside my project directory structure in order to make RoR load it properly. Second question: Can I overwrite the original macro without modifying the rails installation? How?
2006 Feb 01
2
Getting Started with Site Redesign and RoR
Hello all: I am in the process of redesigning my site and was thinking about incorporating RoR into the overall structure. However, there are multiple things I would like to create with Rails, namely a gallery, a weblog, and portfolio management system. Given that I am going to be using a lot of RoR, what is the best way to accomplish this task? Here are some random things that have come
2006 Jan 07
1
AWS, SOAP, and Exceptions
Can someone shed some light on how to convert an Exception to a SOAPFault on Rails 1.0/AWS 1.0? I''ve been digging through the source code and see that in soap_protocol.rb there is a method called encode_response() that seems to perform the translation of an Exception to a SOAPFault. However, if I use the following code block within my Web Service controller: def
2006 Jan 17
1
Rails too Active?
I feel the need to protest about a disturbing trend in the vibrant RoR community - name dilution. ActiveRecord is called that precisely because it is that. The name come from Martin Fowler, and it expresses a class which is a database record, only _active_ - that is with methods & behaviors (unlike a classical database record, which is completely passive.) If you look in the
2007 Jul 19
8
Where do I put code for my own types?
Sorry for all the questions today... Beyond the obvious things--models, controllers, helpers, and other framework-related types--where should I put the code for my own types? For example, I was thinking of writing my own AJAX-friendly paginator, but I don''t know where to put the code for that sort of thing. I would prefer to keep things object-oriented, so I would rather do a lot of
2006 Feb 28
1
Wrong id after join!
The Problem ----------- After using a join in my find the id attributes set in my Entity objects are wrong! It is setting the Entity id to the value from Postcode id! The Code -------- entities = Entity.find(:all, :conditions => [...omited...], :joins => "as e inner join postcodes as pc on substring_index(e.postcode,'' '', 1) =
2009 Feb 09
0
classpath Issue
I am new to Ruby/RoR and would appreciate any help on the issue I am trying to resolve far past 2 days. I have a java application as a jar and I have included in the controller as below. require ''java'' require ''C:/Documents and Settings/user/Desktop/application.jar'' include_package ''whatever.something'' After that I am calling a method
2005 Dec 29
7
belongs_to causing NoMethodError exceptions ... ?
I''ve got a really strange problem using belongs_to. I apologize in advance for the length... this is going to take a while to explain. Basic idea: Creating a User requires that the user enter an email address and activation key that matches an existing PendingUser. After creating the user successfully, that pending user should be marked as "used". The problem: When I
2006 Mar 17
2
ajax exception
Hello! This is my first post so hello to the ROR community :) I am implementing an online editor using the prototype.js lib. On one of the ajax.request calls I make something weird happens. In the debugger I get this output: =================== 10:36:04:796 [DEBUG] FileBrowser.onServiceResult > inResult = success 10:36:04:812 [DEBUG] FileBrowser.onServiceResult > inResult = exception |
2006 Jan 31
4
has_one without inverse belongs_to
I have two models called entity and user. The entities table has a column called users_id that contains the user id of the user that created the entity. In entity I have... has_one :user ... as I want to be able to show the user who created the entity from the entity object. But this produces the following error... Mysql::Error: #42S22Unknown column ''users.entity_id'' in
2007 Mar 31
0
routing problem with controllers in other dirs
Hi all I have a problem with mapping url to controller which is deeper in controller directory (not root directory). I wanted to move acts_as_authenticated account_controller deeper to directory (let''s call it Foo) and route it as /Foo/Account, but i always seem to get exception that no route matched my request file structure: /app +- /controllers +- /Foo +-
2009 Feb 10
2
form_remote_for NOT passing param: I want put and I get post
Hello, I''m struggling my brain with this ajax issue ... Basically I have a form for creating records, and I want to submit it using Ajax. On previous versions of RoR (2.0.2) it was working, but the same methods doesn''t work on 2.2.2, and I started to make changes and changes and read forums and the api, but no way ... <% form_remote_for (:expedient, :url => {:action
2017 Aug 09
1
Java bindings exceptions [was Re: Asking Help]
On Wed, Aug 09, 2017 at 11:09:55PM +0100, Olly Betts wrote: > The Xapian exception classes aren't wrapped for Java at the moment, so > currently you'll get a java.io.IOException exception, and you can check > for DatabaseModifiedError using code like this (untested): > > try { > // Code which might cause DatabaseModifiedError. > } catch (Exception e) { Sorry,
2010 Jan 29
0
Plugin not catching exceptions
Hello, I''m writing a plugin which make an xml-rpc call that throw an exception if the foreign call fail (due to a bad fault-structure). So I catch this exception in my code (I expect it to fail) : [...] server = XMLRPC::Client.new( host, "/xmlrpc/db", 8069) begin result = server.call("change_admin_password", oldPassword, newPassword) rescue
2007 Apr 06
4
using Ruby as a front end for a trading system
Hi All, needed some direction for a newbie to RoR. I have done work in Java, .net and perl, and really prefer perl and java over .net, now we are we are looking to start building a financial trading application, most of the team wants to go with .net while I am trying to build the case with Ruby. Some of our classes have been developed in delphi7. Would I be able to use RoR on the front end of