Displaying 20 results from an estimated 7000 matches similar to: "App upgrade steps from 1.2.4 to 2.0.2?"
2008 Jan 17
6
how to control self.method access
i think self.method just like class method,so if i want to define it
as a private method,i should use
private_class_method :my_method
but i found follow code in < <Agile Web Development with Rails>>
private
def self.hash_password(password)
Digest::SHA1.hexdigest(password)
end
just a mistake or there have some thing which i cannot get?
2011 May 22
6
How to capture correctly a specific exception
I a using delayed_job, and I am raising an exception this way :
config/initializers/custom_exceptions.rb
class RemoteLockerException < StandardError; end
class RemoteLockerDenied < StandardError; end
lib/instruction_request_job.rb
class InstructionRequestJob < Struct.new(:style, :request_id)
def perform
....
> connector =
2006 Nov 02
2
Rescue don't work on web applications
Hi,
I''ve a Rails application who starts a Ruby script .
The script is made via Web -> database.
Than you can select a script to start via a database list.
Problem:
In case of errors , I like to start a rescue showing the users the
problems.
render(:text => "<pre>" + CGI::escapeHTML(`
begin
/home/luc/radrails/cpe/public/startq_test.rb
2006 May 26
13
win32-dir, unicode
Hi,
I''ve got a preliminary version of the pure Ruby version of win32-dir in
CVS. However, I was hoping to work out the Unicode issue. Run this:
from = "C:\\test"
to = "?????"
Dir.mkdir(from) unless File.exists?(from)
Dir.create_junction(to, from)
It works, but my explorer (and dos) window shows the name garbled. I
don''t think it''s a font
2008 Mar 08
1
How to downgrade from rails 2.0.2
Somehow I have ended up with v2.0.2 on my Mac. I am running Leopard so
am not sure whether this version came with it. Here are the various
versions of components:
macfizz$ rails -v
Rails 2.0.2
macfizz$ ruby -v
ruby 1.8.6 (2007-09-24 patchlevel 111) [universal-darwin9.0]
macfizz$ gem -v
1.0.1
macfizz$
Anyway, for various reasons I''m not that happy with 2.0.2 and want to
downgrade
2008 Jan 18
15
scaffold :product missing in Rails 2.0.2 version of depot tutorial?
I am getting an error when I try to run the code for the depot
application (page 67 in the Agile Web Development on Rails book, 2nd
edition). I built the complete depot app with Rails 1.2.6, and all
worked well. I then updated to Gem 1.0.1 and RoR 2.0.2, and attempted
to repeat the tutorial, and got this strange behavior.
I used "rails depot --database=mysql" because I have not
2008 Oct 15
5
REXML vs libxml
Hi all,
I''ve been looking at the performance of my fb app and one glaring issue
seems to be with the parsing speed of rexml in processing the results. Has
anyone looked into porting the facebooker parser from rexml to libxml? If
not, any reason I shouldn''t try?
Thanks!
Yu-Shan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
2010 Jan 25
3
question on sqldf syntax
trying to structure sql to merge two datasets. structure follows:
dbs.possible.combos (all possible combinations of dates and places)
Date Place
1/1/10 N-01
1/1/10 S-02
1/2/10 N-01
1/2/10 S-02
etc...
dbs.aggregate (the raw data aggregated by date and location)
Date Place Days
1/1/10 N-01 6
1/1/10 S-02 10
1/2/10 S-02 5
Trying to merge so I look-up the values for each possible combo
dbs.final
2005 Feb 23
3
bias of a boot statistic
Question:
How can I get access to the bias value of a boot statistic?
Details:
Boot function:
boot(data, statistic, R, sim="ordinary", stype="i",
strata=rep(1,n), L=NULL, m=0, weights=NULL,
ran.gen=function(d, p) d, mle=NULL, ...)
When I create an object, containing the bootstrap statistic (object <- boot
(....))I can call it and will get an output
2008 Feb 22
4
has_many and belongs_to in rails 2.0.2 (child.Parent) is not working
Hi All
I have 2 models working well in rails 1.2.6 :
class TypeService < ActiveRecord::Base
has_many :Services
end
class Service < ActiveRecord::Base
belongs_to :TypeService
end
I was able to get the name of the service with Rails 1.2.3:
s = Service.find(1)
name_type_service = s.TypeService.name <<-- Now with rails 2.0.2
that doesn''t work
With rails 2.0.2
s
2010 Jun 21
2
Return value associated with a factor
I am using the code below to extract census tract information.
save.tract$state, save.tract$county and save.tract$tract are returned as
factors. In the last three statements, I need to save the actual value of
the factor, but, instead, the code is yielding the position of the factor.
How do I instead return the value of the factor?
By way of example, for Lon=-82.49574 and Lat=29.71495, the code
2014 Jul 04
57
[Bug 80901] New: [NVCF] PWM fan speed too high under kernel 3.15
https://bugs.freedesktop.org/show_bug.cgi?id=80901
Priority: medium
Bug ID: 80901
Assignee: nouveau at lists.freedesktop.org
Summary: [NVCF] PWM fan speed too high under kernel 3.15
Severity: normal
Classification: Unclassified
OS: Linux (All)
Reporter: gianni at rootcube.net
Hardware: x86-64 (AMD64)
2020 Feb 07
2
prioritizing aggregated DBs
Hey all, I've been using ->add_database for a few years
to tie sharded DBs together and it works great.
Now, I want to be able to search across several DBs
which aren't sharded, say: linux-DB, glibc-DB, freebsd-DB.
I want to search for something across all of them, but
prioritize results to favor one or some of those DBs over
others. Is there a way to do that without reindexing?
Or
2009 Mar 26
3
[LLVMdev] OT: Python on LLVM
Hi,
Slightly off-topic (as it's not directly about using or developing LLVM):
http://code.google.com/p/unladen-swallow/wiki/ProjectPlan
"Our long-term proposal is to replace CPython's custom virtual machine
with a JIT built on top of LLVM, while leaving the rest of the Python
runtime relatively intact."
Just curious, has anyone here heard more about this project?
Regards,
2008 Mar 25
1
Moving to ROR 2.0.2
Looking for any gotchas:
Currently running ROR 1.2.3 want to move to 2.0.2. I see the
recommendation to move to 1.2.6 fix the deprecations and then to 2.0.2,
which I plan to do.
I am currently running lightty with SCGI (zed shaw''s version 1.7) on
both win and UNIX platforms without issue.
I have looked at the new features and can iron all that out:
- pagination as plug
- adapters as
2008 Nov 21
1
Multiple databases vs Single large database
Hi
I've decided to use xapian because my files table in my mysql database is going
to grow very large, and it seems mysql isn't good at full text searching. I'm
doing this with the php wrapper by the way.
The way my system is set out, each user has their own set of files, and when
doing a search it is going to be for a specific user's file (based on file
name, title,
2008 Oct 02
1
acts_as_taggable_on environment issues
Like most people, I''ve got two machines: one for development and one
for production. I''ve done everything I can to make sure the ruby/rails
environments are the same, but of course they''re not identical (I''ll
get into that in a moment). The error that I''m getting happens when I
call a method in a background task controller on the production
machine; I
2006 Jun 23
1
Can not rescue ferret exception. What is wrong?
Hi,
I have a big index and wildcard query raises an exception. That is all
right. The problem is I can not rescue this exception and it bombs right
to user page. Why?
I am on Linux. Ferret 0.9.3 with C extentions.
>> class A
>> def self.b
>> Book.index.search(''isbn:00*'')
>> rescue
>> puts ''ok''
>> end
>> end
=>
2007 Dec 03
4
RSYNC
If I try:
rsync -lptgoD -e "ssh -i /root/.ssh/rsync-key" --verbose --exclude="/*.*"
--exclude="*.xml" --include="+ */Tariff/"
192.168.1.1:/home/e-smith/files/ibays/frogs/files/dbs/
rsync lists the correct files, but if I add the destination like this:
rsync -lptgoD -e "ssh -i /root/.ssh/rsync-key" --verbose --exclude="/*.*"
2015 Sep 10
12
Dovecot CalDAV server
I've been once in a while over the years thinking about implementing CalDAV (and CardDAV) to Dovecot. It might be time to start that soon. Does anyone have any suggestions? So far my main goals would be:
- scalable, of course
- configurable storage (object storage, regular fs, maybe some key-value dbs, maybe storing as emails)
- efficient indexes (potentially using key-value dbs? or maybe