fix lva & crawlobject

This commit is contained in:
2015-05-13 11:26:43 +02:00
parent 79dd7c4f68
commit 8de4946109
4 changed files with 11 additions and 9 deletions

View File

@@ -262,7 +262,7 @@ class Lva < ActiveRecord::Base
def read_et_forum
lva=self
url=lva.forumlink
ans = JSON.parse(`python ../microdata/downloadlogin.py #{url}`)
ans = JSON.parse(`python #{Rails.root}/bin/downloadlogin.py #{url}`)
ans.each do |a|
if Crawlobject.where(:objhash=>Digest::SHA512.hexdigest(a.to_json), :objtype=>1).count ==0
aa = Crawlobject.new(:raw=>a.to_json)