Docker-in-Docker (DinD) capabilities of public runners deactivated. More info

Commit 15595758 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Update fix_affiliation_keys_0960.

parent eda45ad4
......@@ -8,8 +8,8 @@
A new mechanism was introduced in version in order to
deal with affiliation. It relies on a new database table
affiliation_keys. Preferences inspihep_institure_id and
add_rules_reg_institute are obsolete and have to be removed.
affiliation_keys. Preferences inspirehep_institute_id and
add_rules_reg_institute are obsolete. Remove them.
The aim of this script, is to update existing database.
......@@ -32,12 +32,8 @@ if __name__ == "__main__":
import sys
import os
# protection: exit if the table affiliation_keys exists
if "affiliation_keys" in db.tables:
print "\n\tThe table affiliation_keys already exists. Exit\n"
# create the database table affiliation_keys from SQL statement
# the table is not create if it exist
print "\n\tCreate the table affiliation_keys"
fn = os.path.join(os.getcwd(),
......@@ -47,8 +43,8 @@ if __name__ == "__main__":
with open(fn) as fi:
# remove preferences inspihep_institure_id, add_rules_reg_institute
for pref in ("inspihep_institure_id", "add_rules_reg_institute"):
# remove preferences inspirehep_institute_id, add_rules_reg_institute
for pref in ("inspirehep_institute_id", "add_rules_reg_institute"):
print "\tRemove preference", pref
db( == pref).delete()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment