This commit halves MAX_USERS and MAX_PKGS, in addition
to setting OPEN_PROPOSALS to 15 and CLOSE_PROPOSALS to 50.
A few counts are now configurable via environment variable:
- MAX_USERS, default: 38000
- MAX_PKGS, default: 32000
- OPEN_PROPOSALS, default: 15
- CLOSE_PROPOSALS, default: 15
Signed-off-by: Kevin Morris <kevr@0cost.org>
As of Python updates, we are no longer considering rows with
empty salts to be legacy hashes. Update gendummydata.py to
generate salts for the legacy passwords it uses with
salt rounds = 4.
Signed-off-by: Kevin Morris <kevr@0cost.org>
As per our regex and policies, usernames should consist of
ascii alphanumeric characters and possibly (-, _ or .).
gendummydata.py was creating unicode versions of some
usernames and adding them into the DB. With our newfound
collations, this becomes a problem as it treats them as
the same.
This should have never been the case here, and so,
gendummydata.py has been patched to normalize all of its
usernames and package names.
Signed-off-by: Kevin Morris <kevr@0cost.org>
Use `/usr/bin/env python3` instead of `/usr/bin/python3` in the shebang
of Python scripts. This adds support for non-standard Python interpreter
paths such as the paths used in virtualenv environments.
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
PackageBases.FlaggerComment and PackageComments.RenderedComment cannot
be NULL and would cause problems in the output file for sqlite users.
This patch adds empty strings ("") as values for these fields.
Signed-off-by: Mark Weiman <mark.weiman@markzz.com>
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
Sqlite3 does not support the MD5 function like MySQL does, instead of the
database program hash the passwords, have Python's hashlib module do it
instead.
Signed-off-by: Mark Weiman <mark.weiman@markzz.com>
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
The number of columns in the SQLs doesn't match the number of rows,
so an error like below occurs:
ERROR 1136 (21S01) at line 50929: Column count doesn't match value count
at row 1
Signed-off-by: Shinya Yamaoka <contact@mail.libmacro.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Package conflicts, provides and replaces are now stored in the new
PackageRelations table. The gendummydata script generates test entries
for these relations.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
In addition to parsing and storing dependencies of packages, store
makedepends, checkdepends and optdepends. Every dependency (of any type)
is displayed on the package details page.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Move comments from the Packages table to PackageBases. Sharing comments
makes sense since they almost always refer to a source package.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This adds a PackageBases table to the database schema and moves the
following fields from the Packages table to PackageBases:
* CategoryID
* NumVotes
* OutOfDateTS
* SubmittedTS
* ModifiedTS
* SubmitterUID
* MaintainerUID
It also fixes all database accesses to comply with the new layout.
Having a separate PackageBases table is the first step to split package
support. By now, we create one PackageBases entry per package (where the
package base has the same name as the corresponding package). When
adding full support for split packages later, the package base name will
be derived from the pkgbase variable and a single package base will be
shared amongst all packages built from one source package.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
There aren't any other subdirectories in support/. Reduce the nesting
depth by moving schema/ to the top-level source directory.
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
2014-02-06 19:11:25 +01:00
Renamed from support/schema/gendummydata.py (Browse further)