Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

import problem "column ingkey is not unique"

Help
m0par70
2006-10-07
2013-05-14
  • m0par70
    m0par70
    2006-10-07

    First of all, thanks for the prog. Very useful.

    I upgraded to 0.12.0.pre1 and get

    Traceback (most recent call last):
      File "/usr/share/gourmet/GourmetRecipeManager.py", line 440, in init_recipes
        check_for_data_to_import(self.rd)
      File "/usr/share/gourmet/GourmetRecipeManager.py", line 64, in check_for_data_to_import
        upgradeHandler.import_backup_file(
      File "/usr/share/gourmet/upgradeHandler.py", line 230, in import_backup_file
        rm.do_add(*action)
      File "/usr/share/gourmet/backends/sql_db.py", line 314, in do_add
        self.execute(self.cursor,SQL,d.values())
      File "/usr/share/gourmet/backends/sql_db.py", line 73, in execute
        cursor.execute(sql,params)
    IntegrityError: column ingkey is not unique

    It appears as though I ended up with duplicate ingredient entries under the old gourmet. Is there any hope, or do I need to reenter all the old recipes?

    Thanks.

     
    • m0par70
      m0par70
      2006-10-07

      After playing with it for a while, I seem to have recovered.

      I looked in .gourmet and found that I had both recipes.mk and recipes.db. Scanning recipes.db, I found no recipe information, just ingredient info. So I deleted recipes.db and restarted gourmet. Import went fine.

      I had an issue with debian's metakit (no proper packages available for sid), so when I started the upgraded gourmet the first time without metakit the .db file must have been created. After compiling and installing custom metakit packages, the new gourmet seemed to have become a little confused when both recipe.db and .mk files are available.

      All is well...

       
    • tom
      tom
      2006-10-07

      This is a bug. -- Please submit a bug report and, if you can, attach a copy of your .mk file (or e-mail it to me if you don't want to make it public) so I can figure out what's going on.

       
      • m0par70
        m0par70
        2006-10-07

        Sorry if I'm just stupid, but looking at the posting times, I wonder if you saw my follow-up reply.

        Do you still think it is a bug, or was it just due to my starting without metakit the first time, then restarting with metakit installed?

        If you still think it is a bug, I'll file a report and attach the .mk, but I thought I'd make sure you read my follow-up first.

        Thanks.