47
47
if e.mimetype in mimetype_pkgweights and e.pkgname in mimetype_pkgweights [ e.mimetype ]:
48
48
pkgweight = mimetype_pkgweights [ e.mimetype ] [ e.pkgname ]
50
print "insert into package (pkgname, pkgdesc, pkglongdesc, name, mimetype, architecture, appid, distribution, section, weight) values (?,?,?,?,?,?,\"{"+e.app_id.strip()+"}\",?,?,?)", \
51
e.pkgname, e.pkgdesc, e.pkglongdesc, e.name, e.mimetype, architecture, e.distribution, e.section, pkgweight
50
print "insert into package (pkgname, pkgdesc, pkglongdesc, name, mimetype, architecture, appid, distribution, section, weight, filehint, description) values (?,?,?,?,?,?,\"{"+e.app_id.strip()+"}\",?,?,?,?,?)", \
51
e.pkgname, e.pkgdesc, e.pkglongdesc, e.name, e.mimetype, architecture, e.distribution, e.section, pkgweight, e.filehint, e.description
54
self._apt_con.execute("insert into package (pkgname, pkgdesc, pkglongdesc, name, mimetype, architecture, appid, distribution, section, weight) values (?,?,?,?,?,?,\"{"+e.app_id.strip()+"}\",?,?,?)", \
55
(e.pkgname, e.pkgdesc, e.pkglongdesc, e.name, e.mimetype, architecture, e.distribution, e.section, pkgweight))
54
self._apt_con.execute("insert into package (pkgname, pkgdesc, pkglongdesc, name, mimetype, architecture, appid, distribution, section, weight, filehint, description) values (?,?,?,?,?,?,\"{"+e.app_id.strip()+"}\",?,?,?,?,?)", \
55
(e.pkgname, e.pkgdesc, e.pkglongdesc, e.name, e.mimetype, architecture, e.distribution, e.section, pkgweight, e.filehint, e.description))
56
56
print " ... inserted ... "
57
57
except Exception, e:
58
58
print "ERROR", e.args