Mantis - cswutils
Viewing Issue Advanced Details
4795 regular use minor always 2011-06-24 22:11 2011-07-17 02:08
igalic  
maciej  
normal  
closed  
fixed  
none    
none  
0004795: No results matched the query for CatalogRelease
when running make package on my machine I'll see:

CRITICAL:root:Database schema version: 1, Application expects version: 7
WARNING:root:Old database schema detected.
WARNING:root:Dropping and creating all tables.
WARNING:root:Cache database is not up to date. Refreshing it.
WARNING:root:Refreshing the database. It may take a long time, please be patient.
WARNING:root:If you need a way to make it faster, please see:
WARNING:root:http://wiki.opencsw.org/checkpkg#toc5 [^]
.......................................................................................................................................................
100% |################################################################################################################################################################################################|
INFO:root:Juicing the srv4 package stream files...
100% |################################################################################################################################################################################################|
Traceback (most recent call last):
  File "gar//bin/checkpkg", line 179, in <module>
    main()
  File "gar//bin/checkpkg", line 127, in main
    sqo_catrel = models.CatalogRelease.selectBy(name=options.catrel).getOne()
  File "/opt/csw/lib/python/site-packages/sqlobject/sresults.py", line 280, in getOne
    % self.sourceClass.__name__)
sqlobject.main.SQLObjectNotFound: No results matched the query for CatalogRelease
gmake: *** [pkgcheck] Error 2
? file icon 0001-checkpkg-Report-if-catalog-release-not-in-db.patch [^] (1,633 bytes) 2011-06-25 12:29
Issue History
2011-06-24 22:11 igalic New Issue
2011-06-25 11:52 maciej Status new => assigned
2011-06-25 11:52 maciej Assigned To => maciej
2011-06-25 12:29 maciej File Added: 0001-checkpkg-Report-if-catalog-release-not-in-db.patch
2011-06-25 12:38 maciej Note Added: 0009137
2011-06-25 12:38 maciej Status assigned => feedback
2011-06-25 14:16 igalic Note Added: 0009138
2011-06-25 14:19 igalic Note Added: 0009139
2011-07-17 02:08 maciej Note Added: 0009196
2011-07-17 02:08 maciej Status feedback => closed
2011-07-17 02:08 maciej Resolution open => fixed

Notes
(0009137)
maciej   
2011-06-25 12:38   
Hi Igor,

My suspicion is that checkpkg is called with a catalog release which is neither current nor unstable. I'm attaching a patch which adds more logging: it displays what catalog name was requested, and what are the available ones. It still propagates the exception, so there will be a stack trace at the end, but above the stack trace, there will be a bit of useful information.

The catalog release is set around line 61 of gar.pkg.mk:

http://sourceforge.net/apps/trac/gar/browser/csw/mgar/gar/v2/gar.pkg.mk#L61 [^]

You could try setting that variable to 'current' in .garrc.
(0009138)
igalic   
2011-06-25 14:16   
CATALOG_RELEASE = current

in ~/.garrc makes it work out fine.
(0009139)
igalic   
2011-06-25 14:19   
Should I try the patch without CATALOG_RELEASE or are you confident that this will work out fine?
(0009196)
maciej   
2011-07-17 02:08   
The patch is now submitted, it works fine. Information about CATALOG_RELEASE is now on the wiki.

http://wiki.opencsw.org/checkpkg#toc4 [^]