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

Bug#660190: security-tracker: add per-maintainer page (with half-baked patch)



On Mon, 2012-03-12 at 21:16 -0400, Michael Gilbert wrote:

> Also, why is "c.execute("PRAGMA foreign_keys=ON")" necessary?

sqlite doesn't enforce foreign key constraints by default:

https://sqlite.org/foreignkeys.html#fk_enable

I'm using those to ensure maintainers are deleted when source packages
are deleted from the database.

> At a cursory glance, this seems more complicated that it needs to be.
> You're creating an "id" for each source package, but that is redundant
> since the package name itself is a unique id.
> 
> All you should need is a table with only sourcepkg names and
> maintainer fields.  Then  when you process a view on (for example) a
> maintainer page you can step through all sourcepkg names listed as
> associated with that maintainer via that table.

The source package name is definitely not unique since there are
multiple suites that could have a line in the source package table.

I'm not sure if the foreign key stuff would work with non-numeric keys.

If a package gets removed from sid, we still want the issues present in
stable to be listed on the maintainer's page. Going with your suggestion
would mean that we would not know which maintainers to remove when a
package is deleted from one particular suite.

> There is also a debugging print statement.
> 
Removed in my local checkout.

-- 
bye,
pabs

http://wiki.debian.org/PaulWise

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: