Dave To
2006-Dec-16 21:36 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argument.
I''m hoping someone has encountered this before. I''m using AAF trunk and trying to multi_search across 2 models. It works fine on my windows (Webricks) dev env but now that i''ve deployed to linux, (Apache, FastCGI) I''m getting the following error: ArgumentError ( isn''t a valid directory argument. You should use either a String or a Directory): /vendor/plugins/acts_as_ferret/lib/multi_index.rb:82:in `initialize'' /vendor/plugins/acts_as_ferret/lib/multi_index.rb:82:in `ensure_searcher'' /vendor/plugins/acts_as_ferret/lib/multi_index.rb:51:in `query_parser'' /vendor/plugins/acts_as_ferret/lib/multi_index.rb:60:in `process_query'' /vendor/plugins/acts_as_ferret/lib/multi_index.rb:26:in `search_each'' /vendor/plugins/acts_as_ferret/lib/class_methods.rb:442:in `id_multi_search'' /vendor/plugins/acts_as_ferret/lib/class_methods.rb:422:in `multi_search'' /app/controllers/search_controller.rb:8:in `query'' Anybody know what might be causing this? Thanks, Dave -- Posted via http://www.ruby-forum.com/.
Dave To
2006-Dec-16 23:00 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
Upon further inspection, it looks like the real error is: error opening ../config/../index/production/[class_index_dir] IO Error occured at <except.c>:79 in xraise I''ve checked the permissions on my index dir and it''s 755. The owner is the same as that running the app. Any ideas how to troubleshoot? thanks -- Posted via http://www.ruby-forum.com/.
Jens Kraemer
2006-Dec-17 22:07 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
On Sun, Dec 17, 2006 at 12:00:04AM +0100, Dave To wrote:> Upon further inspection, it looks like the real error is: > > error opening ../config/../index/production/[class_index_dir] IO Error > occured at <except.c>:79 in xraise > > I''ve checked the permissions on my index dir and it''s 755. The owner is > the same as that running the app. Any ideas how to troubleshoot?what Ferret version do you use ? multi_search seems to be broken with the latest ferret, for me 0.10.11 seemed to work. Jens -- webit! Gesellschaft f?r neue Medien mbH www.webit.de Dipl.-Wirtschaftsingenieur Jens Kr?mer kraemer at webit.de Schnorrstra?e 76 Tel +49 351 46766 0 D-01069 Dresden Fax +49 351 46766 66
Dave To
2006-Dec-18 08:53 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
Jens Kraemer wrote:> On Sun, Dec 17, 2006 at 12:00:04AM +0100, Dave To wrote: >> Upon further inspection, it looks like the real error is: >> >> error opening ../config/../index/production/[class_index_dir] IO Error >> occured at <except.c>:79 in xraise >> >> I''ve checked the permissions on my index dir and it''s 755. The owner is >> the same as that running the app. Any ideas how to troubleshoot? > > what Ferret version do you use ? multi_search seems to be broken with > the latest ferret, for me 0.10.11 seemed to work. > > Jens > > -- > webit! Gesellschaft f?r neue Medien mbH www.webit.de > Dipl.-Wirtschaftsingenieur Jens Kr?mer kraemer at webit.de > Schnorrstra?e 76 Tel +49 351 46766 0 > D-01069 Dresden Fax +49 351 46766 66Hi Jens, I''m running ferret 0.10.13. I think this could be the reason why. I altered my code to run find_by_contents(query) and it works fine. Looks like multi-search on AAF doesn''t jive yet with the latest ferret. Thanks for the tip. -- Posted via http://www.ruby-forum.com/.
Ignacio
2007-Jan-12 15:13 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
> Hi Jens, I''m running ferret 0.10.13. I think this could be the reason > why. I altered my code to run find_by_contents(query) and it works fine. > Looks like multi-search on AAF doesn''t jive yet with the latest ferret. > Thanks for the tip.Hi, i have the same problem with ferret 0.10.11. Some can help me? -- Posted via http://www.ruby-forum.com/.
Ignacio
2007-Jan-12 15:36 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
Ignacio wrote:>> Hi Jens, I''m running ferret 0.10.13. I think this could be the reason >> why. I altered my code to run find_by_contents(query) and it works fine. >> Looks like multi-search on AAF doesn''t jive yet with the latest ferret. >> Thanks for the tip. > > Hi, i have the same problem with ferret 0.10.11. Some can help me?I find the problem. The method multi-search supposes that the index has been constructed before. A solution can be to realize a find_by_contents in all models at begin (to construct the indexes), some one knows other better solution? -- Posted via http://www.ruby-forum.com/.
Aryk Grosz
2007-Feb-02 07:17 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
So will the 0.10.11 version of this plugin fix this problem? Im getting the error sporadically after the index was already built. I cant seem to figure out whats causing it. -- Posted via http://www.ruby-forum.com/.
dave
2007-Feb-06 22:43 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
Aryk Grosz wrote:> So will the 0.10.11 version of this plugin fix this problem? Im getting > the error sporadically after the index was already built. I cant seem to > figure out whats causing it.If it only happens sporadically, I would say that it might be because the index hasn''t been built. Is there content in your index dir when you encounter this? -- Posted via http://www.ruby-forum.com/.
Aryk Grosz
2007-Feb-07 02:28 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
Are you suggesting that the content is getting deleted. This happens after several successful searches using the index and then it crashes. Everytime I check, there are index files in the index folder though... dave wrote:> Aryk Grosz wrote: >> So will the 0.10.11 version of this plugin fix this problem? Im getting >> the error sporadically after the index was already built. I cant seem to >> figure out whats causing it. > > If it only happens sporadically, I would say that it might be because > the index hasn''t been built. Is there content in your index dir when you > encounter this?-- Posted via http://www.ruby-forum.com/.
Mischa Berger
2007-Feb-07 21:04 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
> I find the problem. The method multi-search supposes that the index has > been constructed before. A solution can be to realize a find_by_contents > in all models at begin (to construct the indexes), some one knows other > better solution?(re)building the index with rebuild_index sounds more approprate to me than ''to realize a find_by_contents'' HTH Mischa -- Posted via http://www.ruby-forum.com/.
Jens Kraemer
2007-Feb-08 09:23 UTC
[Ferret-talk] Getting "ArgumentError ( isn''t a valid directory argume
On Wed, Feb 07, 2007 at 10:04:40PM +0100, Mischa Berger wrote:> > I find the problem. The method multi-search supposes that the index has > > been constructed before. A solution can be to realize a find_by_contents > > in all models at begin (to construct the indexes), some one knows other > > better solution? > > (re)building the index with rebuild_index sounds more approprate to me > than ''to realize a find_by_contents''yeah, however find_by_contents implicitly rebuilds the index if none exists ;-) Jens -- webit! Gesellschaft f?r neue Medien mbH www.webit.de Dipl.-Wirtschaftsingenieur Jens Kr?mer kraemer at webit.de Schnorrstra?e 76 Tel +49 351 46766 0 D-01069 Dresden Fax +49 351 46766 66