1 |
commit: 7d1ec147e3fa1a86649bc51d6f1bf145de3d7194 |
2 |
Author: Magnus Granberg <zorry <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Aug 31 01:45:47 2011 +0000 |
4 |
Commit: Magnus Granberg <zorry <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Aug 31 01:45:47 2011 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=dev/zorry.git;a=commit;h=7d1ec147 |
7 |
|
8 |
fix error when foo-ggg/baa is emty |
9 |
|
10 |
--- |
11 |
gobs/bin/gobs_updatedb | 4 +++- |
12 |
gobs/pym/package.py | 2 ++ |
13 |
2 files changed, 5 insertions(+), 1 deletions(-) |
14 |
|
15 |
diff --git a/gobs/bin/gobs_updatedb b/gobs/bin/gobs_updatedb |
16 |
index 794cb78..34aac67 100755 |
17 |
--- a/gobs/bin/gobs_updatedb |
18 |
+++ b/gobs/bin/gobs_updatedb |
19 |
@@ -91,7 +91,9 @@ def update_cpv_db(mysettings): |
20 |
if package_id is None: |
21 |
# Add new package with ebuilds |
22 |
package_id = init_package.add_new_package_db(categories, package) |
23 |
- package_id_list_tree.append(package_id) |
24 |
+ # FIXME log some way that package_id was None |
25 |
+ if not package_id is None: |
26 |
+ package_id_list_tree.append(package_id) |
27 |
# Ceck if we have the cp in the package table |
28 |
elif package_id is not None: |
29 |
# Update the packages with ebuilds |
30 |
|
31 |
diff --git a/gobs/pym/package.py b/gobs/pym/package.py |
32 |
index 0efc8aa..78af8be 100644 |
33 |
--- a/gobs/pym/package.py |
34 |
+++ b/gobs/pym/package.py |
35 |
@@ -184,6 +184,8 @@ class gobs_package(object): |
36 |
categories_dir = self._mysettings['PORTDIR'] + "/" + categories + "/" |
37 |
# Get the ebuild list for cp |
38 |
ebuild_list_tree = self._myportdb.cp_list((categories + "/" + package), use_cache=1, mytree=None) |
39 |
+ if ebuild_list_tree is []: |
40 |
+ return None |
41 |
config_cpv_listDict = self.config_match_ebuild(categories, package) |
42 |
config_id = get_default_config(conn) |
43 |
packageDict ={} |