Francois Beausoleil
2005-Dec-02 07:39 UTC
PDF::Writer and Transaction::Simple - conflict between Rails version ?
Hi ! I'm having a BIG problem here. I am outputting PDFs from some of my controllers. Things work fine. I put in vendor/ Transaction::Simple 1.3.0 Now, after I added Transaction::Simple to vendor/, some of my tests are failing - they are all tests which use transactions explicitely. Something like this: def move_before(line) raise ArgumentError, 'expected another QuoteLine - received Nil' unless line self.class.transaction(self, line) do self.insert_at(line.position) end end This now fails because the transaction seems to rollback everytime. So, I removed Transaction::Simple, but now PDF::Writer fails to render tables by raising this: 1) Error: test_view_as_pdf(Admin::QuotesControllerTest): MissingSourceFile: No such file to load -- group PDF::Writer is trying to load Transaction::Simple::Group at this point. Anybody has a solution for this quandary ? Thanks for any help ! -- François Beausoleil http://blog.teksol.info/ _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
David Mitchell
2005-Dec-02 09:42 UTC
Re: PDF::Writer and Transaction::Simple - conflict between Rails version ?
Possibly obvious - have you tried removing and reinstalling PDF::Writer? At a guess, installing Transaction::Simple overwrote a file that PDF::Writer was using, and when you removed Transaction::Simple it removed the overwritten file. If reinstalling PDF::Writer doesn''t work, I''d just work through everything you''ve got installed progressively and reinstall each one until the problem goes away. Good luck Dave M. On 12/2/05, Francois Beausoleil <francois.beausoleil-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi ! > > I''m having a BIG problem here. I am outputting PDFs from some of my > controllers. Things work fine. I put in vendor/ Transaction::Simple > 1.3.0 > > Now, after I added Transaction::Simple to vendor/, some of my tests > are failing - they are all tests which use transactions explicitely. > > Something like this: > def move_before(line) > raise ArgumentError, ''expected another QuoteLine - received Nil'' unless line > self.class.transaction(self, line) do > self.insert_at(line.position) > end > end > > This now fails because the transaction seems to rollback everytime. > So, I removed Transaction::Simple, but now PDF::Writer fails to render > tables by raising this: > 1) Error: > test_view_as_pdf(Admin::QuotesControllerTest): > MissingSourceFile: No such file to load -- group > > PDF::Writer is trying to load Transaction::Simple::Group at this point. > > Anybody has a solution for this quandary ? > > Thanks for any help ! > -- > François Beausoleil > http://blog.teksol.info/ > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >
Austin Ziegler
2005-Dec-02 13:58 UTC
Re: PDF::Writer and Transaction::Simple - conflict between Rails version ?
On 12/2/05, David Mitchell <monch1962-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Possibly obvious - have you tried removing and reinstalling PDF::Writer?That won''t solve this. PDF::Writer 1.1.x *requires* Transaction::Simple 1.3.0; it requires the group functionality. If Rails is being shipped with a version of Transaction::Simple *prior* to 1.3.0, then it should be updated -- quickly. -austin -- Austin Ziegler * halostatue-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org * Alternate: austin-/yODNl0JVVCozMbzO90S/Q@public.gmane.org
Francois Beausoleil
2005-Dec-05 20:11 UTC
Re: PDF::Writer and Transaction::Simple - conflict between Rails version ?
Hi ! 2005/12/2, Austin Ziegler <halostatue@gmail.com>:> On 12/2/05, David Mitchell <monch1962@gmail.com> wrote: > > Possibly obvious - have you tried removing and reinstalling PDF::Writer? > > That won't solve this. PDF::Writer 1.1.x *requires* > Transaction::Simple 1.3.0; it requires the group functionality. If > Rails is being shipped with a version of Transaction::Simple *prior* > to 1.3.0, then it should be updated -- quickly.I'd like to chime in that I removed the bundled Transaction::Simple from Rails, and used an unpacked Transaction::Simple 1.3.0 in vendor to good effect. Thanks for the help ! -- François Beausoleil http://blog.teksol.info/ _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails