Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] EDICT dictionary on Kindle
- Date: Sun, 30 Dec 2012 16:23:26 +1100
- From: Jim Breen <jimbreen@example.com>
- Subject: Re: [tlug] EDICT dictionary on Kindle
- References: <CA+04B5BRXGfiC1_=aGLZ8PCo-0wPoL3tPVR60myiLEG0i6xpNg@mail.gmail.com> <CADFHC5yk6BGvhTM0wb3nbSP+5TFSq763JodLruFr7a7bc==y3g@mail.gmail.com> <CA+04B5Dt5+SXf30Wt_L3G=zCkRAbjx3NJEcHfgr+2XZptzGsFw@mail.gmail.com> <CAMEtR2K4-tTQNmqKnGXJNWVFpAat4LSt=CNEcZQRe-s3E4RfLw@mail.gmail.com> <CABHGxq5AudMvnjSjiswDSy20V1oJ4CMVfjnRFqOVe656+a7K3Q@mail.gmail.com> <CAMEtR2JO-Z6LCCD1-U0oD1c3eX82inJbCXxY_aZFK3s_u9ATqA@mail.gmail.com> <20121216222647.GA10816@sanma.local> <CABHGxq5P51UJg_6wEqtuZWfGTcjLJuE3z9rxseOX0GXgOmr7qQ@mail.gmail.com> <20121230005538.GA48644@sanma.local>
On 30 December 2012 11:55, John Mettraux <jmettraux@example.com> wrote: > On Sun, Dec 30, 2012 at 10:50:56AM +1100, Jim Breen wrote: >> >> ... >> failed to parse: ??? [??????] /(n) (arch) (obsc) (See ???) cutting off the leg >> at the knee (form of punishment in ancient China)/EntL2542160/ >> #<ArgumentError: invalid byte sequence in US-ASCII> >> ... >> >> It seems that whatever locale is used by cron is not getting >> through to ruby, so it is defaulting to ASCII and chucking up >> on the UTF8 in the input file. The script has the usual >> "# encoding: UTF-8" as the first line, but that seem only to >> affect the script; not the data. Googling the problem shows >> a lot of discussion of the problem, but no cron-related >> solutions. >> >> I've tried all sorts of locale-setting fiddles, and tried several different >> shells, but nothing works. > > when forcing the local to en_us.ascii, I can see the ArgumentError. > > This change works around it: > > https://github.com/jmettraux/edict2-kindle/commit/91e4bf2ae811aca39f0866d87771426a75667ae7 > > It forces the script to consider the input as UTF-8. Thanks. That did the trick. It's fine now. Cheers Jim -- Jim Breen Adjunct Snr Research Fellow, Japanese Studies Centre, Monash University
- References:
- Re: [tlug] EDICT dictionary on Kindle
- From: John Mettraux
- Re: [tlug] EDICT dictionary on Kindle
- From: Jim Breen
- Re: [tlug] EDICT dictionary on Kindle
- From: John Mettraux
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] offsite backup vault providers in Japan
- Next by Date: Re: [tlug] offsite backup vault providers in Japan
- Previous by thread: Re: [tlug] EDICT dictionary on Kindle
- Next by thread: [tlug] Syncing Android Tablets
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links