[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [PATCH] Modify blends_prospective_gatherer.py : Raise IntegrityError in case of duplicate keys in table blends_prospectivepackages



I droped this patch in favour of the next one.

On Mon, Aug 24, 2015 at 11:27:46PM +0530, zenith158@gmail.com wrote:
> From: Akshita Jha <akshita-guest@users.alioth.debian.org>
> 
> ---
>  udd/blends_prospective_gatherer.py | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/udd/blends_prospective_gatherer.py b/udd/blends_prospective_gatherer.py
> index 69652e8..7a7f89f 100644
> --- a/udd/blends_prospective_gatherer.py
> +++ b/udd/blends_prospective_gatherer.py
> @@ -422,6 +422,9 @@ class blends_prospective_gatherer(gatherer):
>      except KeyError, err:
>        print "Error while inserting packages", err
>        raise
> +    except IntegrityError as err:
> +      print "Duplicate Key Error while inserting packages", err
> +      raise
>  
>      cur.execute("DEALLOCATE package_insert")
>      
> -- 
> 1.9.1
> 
> 

-- 
http://fam-tille.de


Reply to: