Skip to content

Commit

Permalink
Handle cables where the subject is None, updated dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
heuer committed Feb 4, 2011
1 parent 3a21f0d commit 2048ae4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion cableimporter.py
Expand Up @@ -70,11 +70,12 @@ def process_cable(self, cb, overwrite):
## updates metas without erasing edges
if cable is None:
cable = initEdges({})
cable_title = cb.subject.title() if cb.subject else u''
## overwrite metas informations without erasing edges
cable.update({
# auto index
'_id' : "%s" % cable_id,
'label' : cb.subject.title(),
'label' : cable_title,
'start' : datetime.strptime(cb.created, "%Y-%m-%d %H:%M"),
'classification' : cb.classification,
'embassy' : "%s" % cb.origin,
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -29,7 +29,7 @@
setup (
name = 'cablegate_semnet',
packages = find_packages(),
install_requires = ['bson','beautifulsoup','nltk','TinasoftPytextminer'],
install_requires = ['bson','cablemap.core','nltk'],
scripts = ['execute.py'],
version = __version__,
url = __url__,
Expand Down

0 comments on commit 2048ae4

Please sign in to comment.