Modify ↓
Ticket #5625 (closed defect: fixed)
Opened 5 years ago
Last modified 20 months ago
SpamFilter extlinks and division by zero errors
| Reported by: | shawnw@… | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | plugin - spam-filter |
| Component: | plugin/spamfilter | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | |||
| Release Notes: | |||
| API Changes: | |||
Description
Setting the max_external_links config variable to 0 causes the extlinks spam filter to raise division by zero errors instead of lowering the karma of a submission with any external links.
The test method of ExternalLinksFilterStrategy? ends up doing a
return -abs(self.karma_points) * num_ext / self.max_links, ...
which causes the error.
On the plus side, it looks like setting max_external_links to 1 will do what I want.
Attachments
Change History
comment:1 Changed 3 years ago by rblank
- Milestone set to not applicable
comment:2 Changed 2 years ago by cboos
- Milestone changed from not applicable to spam-filter-plugin
- Owner mgood deleted
comment:3 Changed 20 months ago by dstoecker
- Resolution set to fixed
- Status changed from new to closed
Note: See
TracTickets for help on using
tickets.



In r9881.