Forums: users (Thread #34942)

bsfilter 1.0.19 Rev. 1.97、ruby 2.1.0でundefined method `force_encodingエラー (2014-01-16 15:57 by tsuchiya_masaru #71309)

CentOS6.5でbsfilter+.procmailrcによるフィルタリングを行っていましたが、
いつの間にかX-Spam-Probabilityがヘッダーに挿入されなくなりました。そ
のため、Spamフィルタリングが働かず、困っています。

bsfilterそのものは正常に動いています。
==================================================
$ bsfilter 11079
combined probability 11079 1 0.500003
==================================================

.procmailrcのレシピは
==================================================
PATH=/bin:/usr/bin:/usr/local/bin
SHELL=/bin/bash
MAILDIR=$HOME/Mail
LOGFILE=$HOME/Mail/procmaillog
VERBOSE=yes
BSFILTER=/usr/bin/bsfilter

:0 fw
| /usr/bin/bsfilter --pipe --insert-flag --insert-probability

:0
* ^X-Spam-Probability: *(1|0\.[89])
spam/.
(以下略)
==================================================
となっています。

procmaillogの内容ですが
==================================================
procmail: Executing "/usr/bin/bsfilter,--pipe,--insert-flag,--insert-probability"
/usr/bin/bsfilter:1086: undefined method `force_encoding' for "[\260\241-\364\244]+":String (NoMethodError)
==================================================
とエラーが表示されています。

ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-linux]
bsfilter      RELEASE 1.0.19     REVISION 1.87

Reply to #71309×

You can not use Wiki syntax
You are not logged in. To discriminate your posts from the rest, you need to pick a nickname. (The uniqueness of nickname is not reserved. It is possible that someone else could use the exactly same nickname. If you want assurance of your identity, you are recommended to login before posting.) Login