Commit
…lations. The "postgres" user isn't always the superuser.
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,7 @@ def configure(self, config): | |
# Check whether we are running one of the paster commands which means | ||
# that we should ignore the following tests. | ||
import sys | ||
if sys.argv[-1] in ['create-db', 'create-read-only-user']: | ||
if sys.argv[0].split('/')[-1] == 'paster': | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
icmurray
Author
Contributor
|
||
log.warn("Omitting permission checks because you are " | ||
"running paster commands.") | ||
return | ||
|
This is not exactly the same since tests are not only skipped if you run the paster create-db or create-read-only-user commands. It skips the tests even if you run ckan with
paster serve --reload development.ini
. I know the previous solution was a little bit dodgy but the easiest and safest in my opinion.