Project

General

Profile

Bug #30055

Améliorer le contrôle de doublon lors de la création d'une nouvelle catégorie de formulaire

Added by Victor Claudet 3 months ago. Updated 3 months ago.

Status:
Nouveau
Priority:
Normal
Assignee:
-
Start date:
24 Jan 2019
Due date:
% Done:

0%

Patch proposed:
No
Planning:
No

Description

Si on créé deux catégories avec le même nom mais casse différente, w.c.s l'accepte et créé a priori les deux catégories avec le même slug.
Ce la provoque ensuite une erreur lorsque l'on essaie de rattacher un formulaire à l'une des deux catégorie en doublon.

testé sur la démo de prod :

Message alors généré :

Exception:
  type = '<class 'psycopg2.ProgrammingError'>', value = 'relation "wcs_category_aides" already exists
'

Stack trace (most recent call first):
  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 877, in do_global_views
   875         name = get_name_as_sql_identifier(category.url_name)[:40]
   876         cur.execute('''CREATE VIEW wcs_category_%s AS SELECT * from wcs_all_forms
>  877                         WHERE category_id = %s''' % (name, category.id))
   878 
   879 

  locals: 
     FormDef = <class 'wcs.formdef.FormDef'>
     category = <Category 'aides' id:45>
     common_fields = [("int '0'", 'category_id'), ("int '0'", 'formdef_id'), ('id', 'id'), ('user_id', 'user_id'), ('receipt_time', 'receipt_time'), ('status', 'status'), ('id_display', 'id_display'), ('submission_channel', 'submission_channel'), ('backoffice_submission', 'backoffice_submission'), ('last_update_time', 'last_update_time'), ('digest', 'digest'), ('concerned_roles_array', 'concerned_roles_array'), ('actions_roles_array', 'actions_roles_array'), ('fts', 'fts'), ('is_at_endpoint', 'is_at_endpoint'), ('formdef_name', 'formdef_name'), ('user_name', 'user_name'), ('criticality_level', 'criticality_level'), ('geoloc_base_x', 'geoloc_base_x'), ('geoloc_base_y', 'geoloc_base_y')]
     conn = <connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>
     cur = <cursor object at 0x7ff69c3bece8; closed: 0>
     existing_views = set([u'wcs_view_322_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_155_renoncer_a_l_assistance_d_un_interprete', u'wcs_view_17_urgence_et_depannage', u'wcs_view_56_demande_de_subvention', u'wcs_view_116_signaler_un_probleme_de_tag', u'wcs_view_232_demande_d_abonnement_au_service_de_telea', u'wcs_view_1_copie_d_acte_de_naissance', u'wcs_view_332_preinscription_au_centre_de_loisirs_2', u'wcs_view_341_estimation_financiere_interne', u'wcs_view_262_test_formulaire_simplissime', u'wcs_view_73_candidature_a_un_emploi_saisonnier', u'wcs_view_338_test_pierre', u'wcs_view_337_preinscription_au_centre_de_loisirs_3', u'wcs_view_110_inscription_au_kiosk_numerique', u'wcs_view_276_pcros', u'wcs_view_317_gestion_de_projet_gru_quelle_organisatio', u'wcs_view_214_demande_d_occupation_du_domaine_public_p', u'wcs_view_22_votre_avis_sur_le_site_1', u'wcs_view_299_signalement_sur_l_espace_public_a_fonten', u'wcs_view_282_signaler_un_incident_de_voirie_demo_sl', u'wcs_view_4_debit_de_boissons_temporaire_buvette', u'wcs_view_298_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_242_demande_de_consommables_informatiques', u'wcs_view_126_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_300_demande_relative_a_l_eclairage', u'wcs_view_53_inscription_sur_les_listes_electorales_1', u'wcs_view_137_demande_d_abonnement_au_service_de_telea', u'wcs_view_34_inscription_plan_canicule_1', u'wcs_view_171_demande_d_acces_aux_archives', u'wcs_view_112_demande_de_bac_de_collecte_des_ordures_m', u'wcs_view_342_demande_de_reboisement', u'wcs_view_267_test_cd44', u'wcs_view_197_nous_contacter_off', u'wcs_view_189_21_au_23_juillet_sejours_a_eguzon_13_16_', u'wcs_view_79_signaler_un_probleme_de_proprete_1', u'wcs_view_12_annonce_1', u'wcs_view_289_copie_d_acte_de_mariage_1', u'wcs_view_109_premiere_demande_d_apa_en_etablissement', u'wcs_view_236_plainte_moteur_de_recherche', u'wcs_view_150_demande_d_information', u'wcs_view_340_demande_de_subvention_pour_l_adaption_de', u'wcs_view_264_demande_d_ouverture_tardive_exceptionnel', u'wcs_view_19_inscription_journee_nouvel_habitant_1', u'wcs_view_258_creation_du_dossier_dinscription_annuell', u'wcs_view_76_candidature_a_une_offre_d_emploi', u'wcs_view_138_demande_de_conteneurs_ou_bacs_roulants_1', u'wcs_view_15_report_d_alarme', u'wcs_view_284_creation_du_dossier_dinscription_annuell', u'wcs_view_286_demande_d_emplacement_sur_le_marche_hebd', u'wcs_view_315_demande_d_admission_en_creche_1', u'wcs_view_307_inscription_ateliers_boutic_avril_a_juin', u'wcs_view_305_test_fred', u'wcs_view_187_7_au_10_juillet_sejours_a_meschers_sur_g', u'wcs_view_92_declaration_de_phobie_administrative_3_1', u'wcs_view_101_demande_de_prise_de_vue', u'wcs_view_269_inscription_operation_tranquillite_vacan', u'wcs_view_136_demande_d_informations_telealarme', u'wcs_view_98_signaler_la_deterioration_d_un_arret_de_', u'wcs_view_7_enlevement_de_graffiti', u'wcs_view_285_soudage', u'wcs_view_329_test_debug_laurent', u'wcs_view_339_aide_a_la_mobilite_jeune_permis_de_condu', u'wcs_view_120_pre_inscription_famille_1', u'wcs_view_75_candidature_a_un_stage', u'wcs_view_314_rendez_vous_passeport_et_carte_d_identit', u'wcs_view_135_demande_de_modification_ou_de_resiliatio', u'wcs_view_238_notification_de_violation_de_donnees_a_c', u'wcs_view_145_demande_de_subvention_sport', u'wcs_view_257_hippocad', u'wcs_view_210_pse', u'wcs_view_191_fiche_d_inscription', u'wcs_view_227_test_envoi_rst', u'wcs_view_143_demande_d_occupation_de_creneaux_pour_le', u'wcs_view_311_signaler_une_anomalie_sur_la_voirie', u'wcs_view_177_inscription_aux_newsletters', u'wcs_view_306_programme_ateliers_du_reseau_des_espaces', u'wcs_view_154_renoncer_a_une_demande_d_asile', u'wcs_view_279_test_envoi_de_fichier_joint', u'wcs_view_313_signaler_un_incident_de_voirie_mauguio', u'wcs_view_66_inscription_au_repas_des_anciens_1', u'wcs_view_144_enregistrer_son_association_sportive', u'wcs_view_301_test_victor', u'wcs_view_182_demande_de_conges_2', u'wcs_view_51_demande_d_autorisation_d_afficher_sur_la', u'wcs_view_302_prise_de_rendez_vous_passeport_et_carte_', u'wcs_view_250_donner_une_note', u'wcs_view_24_demande_de_formation_1', u'wcs_view_319_test_ben', u'wcs_view_107_simulateur_de_demande', u'wcs_view_194_demande_de_carte_nationale_d_identite', u'wcs_view_129_reservation_d_un_mini_bus_1', u'wcs_view_293_demande_de_rendez_vous_avec_un_elu_3', u'wcs_view_252_creation_du_dossier_dinscription_annuell', u'wcs_view_28_inscription_operation_tranquillite_vacan', u'wcs_view_330_demande_d_autorisation_pour_lorganisatio', u'wcs_view_202_mon_titre', u'wcs_view_203_livret_de_famille', u'wcs_view_5_fermeture_tardive_ou_ouverture_precoce_p', u'wcs_view_240_demande_de_demenagement', u'wcs_view_64_contacter_entr_ouvert', u'wcs_view_127_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_247_declaration_d_un_objet_perdu', u'wcs_view_44_inscription_aux_ateliers_multimedia_de_l', u'wcs_view_121_demande_de_rendez_vous_avec_un_elu', u'wcs_view_221_demande_de_documentation_touristique', u'wcs_view_212_aide_au_logement', u'wcs_view_223_postuler_a_une_offre_d_emploi', u'wcs_view_16_travaux_d_investissement', u'wcs_view_2_copie_d_acte_de_deces', u'wcs_view_334_inscription_a_la_reunion_du_club_utilisa', u'wcs_view_206_test_multi_none', u'wcs_view_294_declaration_d_ouverture_de_chantier_doc', u'wcs_view_90_don_d_organe', u'wcs_view_273_declaration_de_detention_d_un_appareil_d', u'wcs_view_14_petits_travaux_neufs', u'wcs_view_111_inscription_des_hebergements_touristique', u'wcs_view_84_demonstration_connecteur_pastell_1', u'wcs_view_215_titre', u'wcs_view_336_reservation_de_salle', u'wcs_view_188_fiche_sanitaire_de_liaison', u'wcs_view_303_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_174_demande_de_formation', u'wcs_view_233_prise_de_rendez_vous_passeport', u'wcs_view_32_vos_impressions_sur_la_fete_de_la_musiqu', u'wcs_view_228_test_demande_confirmation', u'wcs_view_256_demande_d_emplacement_sur_le_marche_hebd', u'wcs_view_21_preinscription_a_l_ecole_1', u'wcs_view_148_declaration_d_intention_de_commencement_', u'wcs_view_100_connaitre_les_regles_de_communicabilite_', u'wcs_view_280_signaler_un_incident_de_voirie_a_l_hay_l', u'wcs_view_281_creation_du_dossier_dinscription_annuell', u'wcs_view_320_demande_d_information_apa_copie', u'wcs_view_42_suggestions_d_achats_pour_la_mediatheque', u'wcs_view_272_bloc_adresse', u'wcs_view_86_declaration_de_phobie_administrative', u'wcs_view_59_inscription_stage_theatre_1', u'wcs_view_316_lille_test', u'wcs_view_268_reservation_aquabike', u'wcs_view_74_candidature_spontanee_1', u'wcs_view_217_demande_d_information_apa', u'wcs_view_181_demande_d_autorisation_de_stationnement_', u'wcs_view_162_inscription_a_la_chasse_aux_oeufs_de_paq', u'wcs_view_153_declaration_d_une_personne_de_confiance', u'wcs_view_220_declarer_un_changement_de_coordonnees_ad', u'wcs_view_266_demande_d_inscription_a_l_accueil_de_loi', u'wcs_view_245_coordonnees_min_cult', u'wcs_view_265_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_105_reservation_de_mobilier_municipal_1', u'wcs_view_249_demande_de_place_en_creche', u'wcs_view_209_assainissement_demande_de_raccordement_a', u'wcs_view_68_demande_de_livret_de_famille', u'wcs_view_46_contactez_l_agence_de_developpement_econ', u'wcs_view_140_demande_d_enlevement_d_encombrant', u'wcs_view_193_changement_de_situation_pour_les_listes_', u'wcs_view_29_demande_d_occupation_du_domaine_public', u'wcs_view_151_inscription_a_la_soiree_des_voeux_du_mai', u'wcs_view_207_inscription_a_la_deuxieme_reunion_du_clu', u'wcs_view_277_inscription_a_la_reunion_du_club_utilisa', u'wcs_view_312_contacter_mauguio', u'wcs_view_259_couches_lavables_profitez_de_l_offre_d_e', u'wcs_view_30_demande_de_rendez_vous_avec_un_elu_5', u'wcs_view_186_demande_d_enlevement_de_tags_d_affiches_', u'wcs_view_211_aide_financiere', u'wcs_view_142_enregistrer_son_association_culturelle', u'wcs_view_231_recia', u'wcs_view_239_preinscription_au_centre_de_loisirs_1', u'wcs_view_67_demande_de_programme_culturel', u'wcs_view_321_test_affichage_liste_a_choix_multiples_v', u'wcs_view_190_28_au_30_juillet_sejours_a_rocamadour_8_', u'wcs_view_6_intervention_du_service_hygiene_salubrit', u'wcs_view_248_reservation_d_un_mini_bus', u'wcs_view_333_test_pcros', u'wcs_view_327_prise_de_rendez_vous_passeport_et_carte_', u'wcs_view_157_declarer_un_changement_de_domicile_elu', u'wcs_view_94_demande_de_documentation_touristique_1', u'wcs_view_335_demande_d_emplacement_sur_le_marche_hebd', u'wcs_view_63_declaration_de_chien_dangereux', u'wcs_view_241_demande_d_enveloppes', u'wcs_view_152_demande_d_asile', u'wcs_view_80_demande_de_renseignements_urbanistiques', u'wcs_view_222_contacter_entr_ouvert_mc', u'wcs_view_297_test_vic', u'wcs_view_156_demander_une_copie_de_documents_administ', u'wcs_view_304_mon_titre_de_formulaire', u'wcs_view_27_demande_de_bac_de_collecte_des_ordures_m', u'wcs_view_278_test_envoi_pj_dans_courriel_brice', u'wcs_view_139_renseignement_sur_la_collecte_des_dechet', u'wcs_view_65_inscription_au_centre_culturel_1', u'wcs_view_8_autorisation_de_stationnement_pour_demen', u'wcs_view_230_reservation_de_mobilier_municipal', u'wcs_view_310_test_test', u'wcs_view_141_demande_de_subvention_culture', u'wcs_view_254_test_formation_sl', u'wcs_view_102_contact_general', u'wcs_view_251_signaler_un_incident_de_voirie', u'wcs_view_168_demande_de_rendez_vous_avec_un_elu_2', u'wcs_view_108_premiere_demande_d_apa_a_domicile', u'wcs_view_218_demander_mon_code_dossier_apa', u'wcs_view_325_reservation_d_une_imprimante_3d', u'wcs_view_288_inscription_publik_light', u'wcs_view_216_simulateur_de_demande_1', u'wcs_view_114_signaler_un_probleme_de_proprete', u'wcs_view_96_demonstrateur_geolocalisation_et_photo', u'wcs_view_244_demande_de_tampons', u'wcs_view_36_preinscription_au_centre_de_loisirs', u'wcs_view_263_test_thomas', u'wcs_view_146_demande_de_vehicule', u'wcs_view_175_demonstration_paiement', u'wcs_view_274_debit_de_boissons_temporaire_buvette_1', u'wcs_view_173_inscription_a [...]
     fake_formdef = <FormDef None id:None>
     name = 'aides'
     row = None
     union = 'SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_322_inscription_a_la_soiree_des_voeux_du_mai UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_155_renoncer_a_l_assistance_d_un_interprete UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_4_debit_de_boissons_temporaire_buvette UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_56_demande_de_subvention UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_116_signaler_un_probleme_de_tag UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_232_demande_d_abonnement_au_service_de_telea UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_1_copie_d_acte_de_naissance UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_332_preinscription_au_centre_de_loisirs_2 UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_339_aide_a_la_mobilite_jeune_permis_de_condu UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_38_programmation_culturelle_1 UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_73_candidature_a_un_emploi_saisonnier UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_302_prise_de_rendez_vous_passeport_et_carte_ UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_110_inscription_au_kiosk_numerique UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_317_gestion_de_projet_gru_quelle_organisatio UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_214_demande_d_occupation_du_domaine_public_p UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_22_votre_avis_sur_le_site_1 UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_299_signalement_sur_l_espace_public_a_fonten UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_282_signaler_un_incident_de_voirie_demo_sl UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_17_urgence_et_depannage UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_298_inscription_a_la_soiree_des_voeux_du_mai UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_242_demande_de_consommables_informatiques UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_126_inscription_a_la_soiree_des_voeux_du_mai UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_300_demande_relative_a_l_eclairage UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_174_demande_de_formation UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_53_inscription_sur_les_listes_electorales_1 UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_137_demande_d_abonnement_au_service_de_telea UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_34_inscription_plan_canicule_1 UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_171_demande_d_acces_aux_archives UNION SELECT category_id, formdef_id, id, user_id, receipt_time, status, id_display, submission_channel, backoffice_submission, last_update_time, digest, concerned_roles_array, actions_roles_array, fts, is_at_endpoint, formdef_name, user_name, criticality_level, geoloc_base_x, geoloc_base_y FROM wcs_view_330_demande_d_autorisation_pour_lorganisatio UNION SELECT categ [...]
     view_names = set(['wcs_view_322_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_155_renoncer_a_l_assistance_d_un_interprete', 'wcs_view_4_debit_de_boissons_temporaire_buvette', 'wcs_view_56_demande_de_subvention', 'wcs_view_116_signaler_un_probleme_de_tag', 'wcs_view_232_demande_d_abonnement_au_service_de_telea', 'wcs_view_1_copie_d_acte_de_naissance', 'wcs_view_332_preinscription_au_centre_de_loisirs_2', 'wcs_view_339_aide_a_la_mobilite_jeune_permis_de_condu', 'wcs_view_38_programmation_culturelle_1', 'wcs_view_73_candidature_a_un_emploi_saisonnier', 'wcs_view_302_prise_de_rendez_vous_passeport_et_carte_', 'wcs_view_110_inscription_au_kiosk_numerique', 'wcs_view_317_gestion_de_projet_gru_quelle_organisatio', 'wcs_view_214_demande_d_occupation_du_domaine_public_p', 'wcs_view_22_votre_avis_sur_le_site_1', 'wcs_view_299_signalement_sur_l_espace_public_a_fonten', 'wcs_view_282_signaler_un_incident_de_voirie_demo_sl', 'wcs_view_17_urgence_et_depannage', 'wcs_view_298_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_242_demande_de_consommables_informatiques', 'wcs_view_126_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_300_demande_relative_a_l_eclairage', 'wcs_view_174_demande_de_formation', 'wcs_view_53_inscription_sur_les_listes_electorales_1', 'wcs_view_137_demande_d_abonnement_au_service_de_telea', 'wcs_view_34_inscription_plan_canicule_1', 'wcs_view_171_demande_d_acces_aux_archives', 'wcs_view_330_demande_d_autorisation_pour_lorganisatio', 'wcs_view_112_demande_de_bac_de_collecte_des_ordures_m', 'wcs_view_27_demande_de_bac_de_collecte_des_ordures_m', 'wcs_view_267_test_cd44', 'wcs_view_98_signaler_la_deterioration_d_un_arret_de_', 'wcs_view_189_21_au_23_juillet_sejours_a_eguzon_13_16_', 'wcs_view_79_signaler_un_probleme_de_proprete_1', 'wcs_view_288_inscription_publik_light', 'wcs_view_109_premiere_demande_d_apa_en_etablissement', 'wcs_view_236_plainte_moteur_de_recherche', 'wcs_view_150_demande_d_information', 'wcs_view_340_demande_de_subvention_pour_l_adaption_de', 'wcs_view_257_hippocad', 'wcs_view_326_demande_d_autorisation_douverture_tardiv', 'wcs_view_19_inscription_journee_nouvel_habitant_1', 'wcs_view_258_creation_du_dossier_dinscription_annuell', 'wcs_view_76_candidature_a_une_offre_d_emploi', 'wcs_view_138_demande_de_conteneurs_ou_bacs_roulants_1', 'wcs_view_15_report_d_alarme', 'wcs_view_284_creation_du_dossier_dinscription_annuell', 'wcs_view_286_demande_d_emplacement_sur_le_marche_hebd', 'wcs_view_307_inscription_ateliers_boutic_avril_a_juin', 'wcs_view_187_7_au_10_juillet_sejours_a_meschers_sur_g', 'wcs_view_101_demande_de_prise_de_vue', 'wcs_view_269_inscription_operation_tranquillite_vacan', 'wcs_view_136_demande_d_informations_telealarme', 'wcs_view_7_enlevement_de_graffiti', 'wcs_view_341_estimation_financiere_interne', 'wcs_view_120_pre_inscription_famille_1', 'wcs_view_75_candidature_a_un_stage', 'wcs_view_135_demande_de_modification_ou_de_resiliatio', 'wcs_view_238_notification_de_violation_de_donnees_a_c', 'wcs_view_145_demande_de_subvention_sport', 'wcs_view_92_declaration_de_phobie_administrative_3_1', 'wcs_view_210_pse', 'wcs_view_181_demande_d_autorisation_de_stationnement_', 'wcs_view_3_copie_d_acte_de_mariage', 'wcs_view_143_demande_d_occupation_de_creneaux_pour_le', 'wcs_view_311_signaler_une_anomalie_sur_la_voirie', 'wcs_view_193_changement_de_situation_pour_les_listes_', 'wcs_view_306_programme_ateliers_du_reseau_des_espaces', 'wcs_view_154_renoncer_a_une_demande_d_asile', 'wcs_view_313_signaler_un_incident_de_voirie_mauguio', 'wcs_view_66_inscription_au_repas_des_anciens_1', 'wcs_view_324_test_laurent', 'wcs_view_230_reservation_de_mobilier_municipal', 'wcs_view_182_demande_de_conges_2', 'wcs_view_250_donner_une_note', 'wcs_view_192_inscription_a_la_soiree_club_utilisateur', 'wcs_view_319_test_ben', 'wcs_view_107_simulateur_de_demande', 'wcs_view_194_demande_de_carte_nationale_d_identite', 'wcs_view_217_demande_d_information_apa', 'wcs_view_129_reservation_d_un_mini_bus_1', 'wcs_view_293_demande_de_rendez_vous_avec_un_elu_3', 'wcs_view_252_creation_du_dossier_dinscription_annuell', 'wcs_view_28_inscription_operation_tranquillite_vacan', 'wcs_view_51_demande_d_autorisation_d_afficher_sur_la', 'wcs_view_202_mon_titre', 'wcs_view_203_livret_de_famille', 'wcs_view_5_fermeture_tardive_ou_ouverture_precoce_p', 'wcs_view_240_demande_de_demenagement', 'wcs_view_64_contacter_entr_ouvert', 'wcs_view_127_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_247_declaration_d_un_objet_perdu', 'wcs_view_44_inscription_aux_ateliers_multimedia_de_l', 'wcs_view_121_demande_de_rendez_vous_avec_un_elu', 'wcs_view_221_demande_de_documentation_touristique', 'wcs_view_212_aide_au_logement', 'wcs_view_223_postuler_a_une_offre_d_emploi', 'wcs_view_16_travaux_d_investissement', 'wcs_view_2_copie_d_acte_de_deces', 'wcs_view_334_inscription_a_la_reunion_du_club_utilisa', 'wcs_view_294_declaration_d_ouverture_de_chantier_doc', 'wcs_view_90_don_d_organe', 'wcs_view_273_declaration_de_detention_d_un_appareil_d', 'wcs_view_253_garges', 'wcs_view_111_inscription_des_hebergements_touristique', 'wcs_view_14_petits_travaux_neufs', 'wcs_view_336_reservation_de_salle', 'wcs_view_188_fiche_sanitaire_de_liaison', 'wcs_view_303_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_114_signaler_un_probleme_de_proprete', 'wcs_view_285_soudage', 'wcs_view_32_vos_impressions_sur_la_fete_de_la_musiqu', 'wcs_view_47_contactez_la_mairie_1', 'wcs_view_256_demande_d_emplacement_sur_le_marche_hebd', 'wcs_view_21_preinscription_a_l_ecole_1', 'wcs_view_148_declaration_d_intention_de_commencement_', 'wcs_view_295_nous_contacter_1', 'wcs_view_280_signaler_un_incident_de_voirie_a_l_hay_l', 'wcs_view_320_demande_d_information_apa_copie', 'wcs_view_42_suggestions_d_achats_pour_la_mediatheque', 'wcs_view_272_bloc_adresse', 'wcs_view_86_declaration_de_phobie_administrative', 'wcs_view_41_demande_de_vehicule_1', 'wcs_view_268_reservation_aquabike', 'wcs_view_68_demande_de_livret_de_famille', 'wcs_view_96_demonstrateur_geolocalisation_et_photo', 'wcs_view_191_fiche_d_inscription', 'wcs_view_162_inscription_a_la_chasse_aux_oeufs_de_paq', 'wcs_view_289_copie_d_acte_de_mariage_1', 'wcs_view_84_demonstration_connecteur_pastell_1', 'wcs_view_266_demande_d_inscription_a_l_accueil_de_loi', 'wcs_view_277_inscription_a_la_reunion_du_club_utilisa', 'wcs_view_265_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_105_reservation_de_mobilier_municipal_1', 'wcs_view_249_demande_de_place_en_creche', 'wcs_view_209_assainissement_demande_de_raccordement_a', 'wcs_view_74_candidature_spontanee_1', 'wcs_view_46_contactez_l_agence_de_developpement_econ', 'wcs_view_140_demande_d_enlevement_d_encombrant', 'wcs_view_177_inscription_aux_newsletters', 'wcs_view_36_preinscription_au_centre_de_loisirs', 'wcs_view_312_contacter_mauguio', 'wcs_view_220_declarer_un_changement_de_coordonnees_ad', 'wcs_view_207_inscription_a_la_deuxieme_reunion_du_clu', 'wcs_view_291_copie_d_acte_de_deces_1', 'wcs_view_108_premiere_demande_d_apa_a_domicile', 'wcs_view_151_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_259_couches_lavables_profitez_de_l_offre_d_e', 'wcs_view_63_declaration_de_chien_dangereux', 'wcs_view_186_demande_d_enlevement_de_tags_d_affiches_', 'wcs_view_211_aide_financiere', 'wcs_view_142_enregistrer_son_association_culturelle', 'wcs_view_231_recia', 'wcs_view_239_preinscription_au_centre_de_loisirs_1', 'wcs_view_67_demande_de_programme_culturel', 'wcs_view_321_test_affichage_liste_a_choix_multiples_v', 'wcs_view_190_28_au_30_juillet_sejours_a_rocamadour_8_', 'wcs_view_6_intervention_du_service_hygiene_salubrit', 'wcs_view_248_reservation_d_un_mini_bus', 'wcs_view_327_prise_de_rendez_vous_passeport_et_carte_', 'wcs_view_157_declarer_un_changement_de_domicile_elu', 'wcs_view_94_demande_de_documentation_touristique_1', 'wcs_view_335_demande_d_emplacement_sur_le_marche_hebd', 'wcs_view_153_declaration_d_une_personne_de_confiance', 'wcs_view_30_demande_de_rendez_vous_avec_un_elu_5', 'wcs_view_241_demande_d_enveloppes', 'wcs_view_152_demande_d_asile', 'wcs_view_80_demande_de_renseignements_urbanistiques', 'wcs_view_222_contacter_entr_ouvert_mc', 'wcs_view_156_demander_une_copie_de_documents_administ', 'wcs_view_304_mon_titre_de_formulaire', 'wcs_view_342_demande_de_reboisement', 'wcs_view_278_test_envoi_pj_dans_courriel_brice', 'wcs_view_245_coordonnees_min_cult', 'wcs_view_65_inscription_au_centre_culturel_1', 'wcs_view_8_autorisation_de_stationnement_pour_demen', 'wcs_view_301_test_victor', 'wcs_view_197_nous_contacter_off', 'wcs_view_141_demande_de_subvention_culture', 'wcs_view_102_contact_general', 'wcs_view_144_enregistrer_son_association_sportive', 'wcs_view_251_signaler_un_incident_de_voirie', 'wcs_view_168_demande_de_rendez_vous_avec_un_elu_2', 'wcs_view_314_rendez_vous_passeport_et_carte_d_identit', 'wcs_view_218_demander_mon_code_dossier_apa', 'wcs_view_325_reservation_d_une_imprimante_3d', 'wcs_view_12_annonce_1', 'wcs_view_216_simulateur_de_demande_1', 'wcs_view_246_estimation_financiere_gestion_de_la_rela', 'wcs_view_244_demande_de_tampons', 'wcs_view_146_demande_de_vehicule', 'wcs_view_233_prise_de_rendez_vous_passeport', 'wcs_view_175_demonstration_paiement', 'wcs_view_274_debit_de_boissons_temporaire_buvette_1', 'wcs_view_173_inscription_a_la_soiree_des_voeux_du_mai', 'wcs_view_91_demande_d_admission_en_creche_2', 'wcs_view_219_declarer_un_changement_de_situation_fami', 'wcs_view_23_demande_de_conges', 'wcs_view_264_demande_d_ouverture_tardive_exceptionnel', 'wcs_view_281_creation_du_dossier_dinscription_annuell', 'wcs_view_134_demande_de_rendez_vous_avec_un_elu_1', 'wcs_view_201_demande_de_stage', 'wcs_view_77_situation_matrimoniale', 'wcs_view_213_aide_energie', 'wcs_view_24_demande_de_formation_1', 'wcs_view_309_tenue_d_un_club_utilisateur_a_strasbourg', 'wcs_view_29_demande_d_occupation_du_domaine_public', 'wcs_view_18_demande_d_admission_en_creche', 'wcs_view_323_demande_de_documentation_touristique_3', 'wcs_view_39_prolongation_de_pret_a [...]
     x = 'wcs_view_331_copie_d_acte_de_mariage_2'
     y = ('geoloc_base_y', 'geoloc_base_y')

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 813, in do_views
   811 
   812     if rebuild_global_views:
>  813         do_global_views(conn, cur) # recreate global views
   814 
   815 

  locals: 
     column_names = {'f_date': 1, 'f_prenom': 1, 'fbo1_contenu': 1, 'f_nom': 1, 'fbo2_courrier': 1, 'f_courriel': 1, 'f6_justificatif': 1}
     conn = <connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>
     cur = <cursor object at 0x7ff69c3bece8; closed: 0>
     endpoint_status = []
     field = <wcs.fields.FileField object at 0x7ff69715b5d0>
     field_key = 'fbo2'
     field_name = 'fbo2_courrier'
     fields_list = "int '46' AS category_id, int '301' AS formdef_id, id AS id, user_id AS user_id, receipt_time AS receipt_time, status AS status, id_display AS id_display, submission_channel AS submission_channel, backoffice_submission AS backoffice_submission, last_update_time AS last_update_time, digest AS digest, f2 AS f_nom, f3 AS f_prenom, f4 AS f_courriel, f5 AS f_date, f6 AS f6_justificatif, fbo1 AS fbo1_contenu, fbo2 AS fbo2_courrier, ARRAY(SELECT status FROM formdata_301_test_victor_evolutions       WHERE formdata_301_test_victor.id = formdata_301_test_victor_evolutions.formdata_id      ORDER BY formdata_301_test_victor_evolutions.time) AS status_history, (SELECT status = ANY(ARRAY[[]]::text[])) AS is_at_endpoint, (criticality_level - 3) AS criticality_level, (SELECT text 'test victor') AS formdef_name, (SELECT name FROM users\n                             WHERE users.id = CAST(user_id AS INTEGER)) AS user_name, concerned_roles_array AS concerned_roles_array, actions_roles_array AS actions_roles_array, fts AS fts, NULL::real AS geoloc_base_x, NULL::real AS geoloc_base_y" 
     formdef = <FormDef 'test victor' id:301>
     levels = 3
     rebuild_global_views = True
     table_name = 'formdata_301_test_victor'
     view_fields = [("int '46'", 'category_id'), ("int '301'", 'formdef_id'), ('id', 'id'), ('user_id', 'user_id'), ('receipt_time', 'receipt_time'), ('status', 'status'), ('id_display', 'id_display'), ('submission_channel', 'submission_channel'), ('backoffice_submission', 'backoffice_submission'), ('last_update_time', 'last_update_time'), ('digest', 'digest'), ('f2', 'f_nom'), ('f3', 'f_prenom'), ('f4', 'f_courriel'), ('f5', 'f_date'), ('f6', 'f6_justificatif'), ('fbo1', 'fbo1_contenu'), ('fbo2', 'fbo2_courrier'), ('ARRAY(SELECT status FROM formdata_301_test_victor_evolutions       WHERE formdata_301_test_victor.id = formdata_301_test_victor_evolutions.formdata_id      ORDER BY formdata_301_test_victor_evolutions.time)', 'status_history'), ('(SELECT status = ANY(ARRAY[[]]::text[]))', 'is_at_endpoint'), ('(criticality_level - 3)', 'criticality_level'), ("(SELECT text 'test victor')", 'formdef_name'), ('(SELECT name FROM users\n                             WHERE users.id = CAST(user_id AS INTEGER))', 'user_name'), ('concerned_roles_array', 'concerned_roles_array'), ('actions_roles_array', 'actions_roles_array'), ('fts', 'fts'), ('NULL::real', 'geoloc_base_x'), ('NULL::real', 'geoloc_base_y')]
     view_name = 'wcs_view_301_test_victor'
     x = ('NULL::real', 'geoloc_base_y')

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 348, in f
   346         except psycopg2.Error:
   347             get_connection().rollback()
>  348             raise
   349     return f
   350 

  locals: 
     args = (<FormDef 'test victor' id:301>, <connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>, <cursor object at 0x7ff69c3bece8; closed: 0>)
     func = <function do_views at 0x7ff69c440938>
     kwargs = {'rebuild_global_views': True}

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 698, in redo_views
   696 
   697     drop_views(formdef, conn, cur)
>  698     do_views(formdef, conn, cur, rebuild_global_views=rebuild_global_views)
   699 
   700 @guard_postgres

  locals: 
     conn = <connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>
     cur = <cursor object at 0x7ff69c3bece8; closed: 0>
     formdef = <FormDef 'test victor' id:301>
     rebuild_global_views = True

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 348, in f
   346         except psycopg2.Error:
   347             get_connection().rollback()
>  348             raise
   349     return f
   350 

  locals: 
     args = (<connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>, <cursor object at 0x7ff69c3bece8; closed: 0>, <FormDef 'test victor' id:301>)
     func = <function redo_views at 0x7ff69c4406e0>
     kwargs = {'rebuild_global_views': True}

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 493, in do_formdef_tables
   491         # views may have been dropped when dropping columns, so we recreate
   492         # them even if not asked to.
>  493         redo_views(conn, cur, formdef, rebuild_global_views=rebuild_global_views)
   494 
   495     if own_conn:

  locals: 
     conn = <connection object at 0x7ff6972166e0; dsn: 'dbname=wcs_demarches_publik_entrouvert_com user=wcs password=xxxxxxxxxxxxxxxx host=10.0.0.10 port=5433', closed: 0>
     cur = <cursor object at 0x7ff69c3bece8; closed: 0>
     evo_existing_fields = set([u'status', u'comment', u'last_jump_datetime', u'formdata_id', u'who', u'parts', u'time', u'id'])
     existing_fields = set([u'last_update_time', u'f2', u'f3', u'f4', u'f5', u'concerned_roles_array', u'tracking_code', u'id', u'digest', u'fts', u'workflow_roles', u'user_id', u'f6', u'fbo1', u'submission_context', u'fbo2', u'receipt_time', u'id_display', u'actions_roles_array', u'status', u'workflow_roles_array', u'workflow_data', u'anonymised', u'backoffice_submission', u'criticality_level', u'submission_channel', u'page_no'])
     field = <wcs.fields.FileField object at 0x7ff69715b5d0>
     formdef = <FormDef 'test victor' id:301>
     needed_fields = set(['last_update_time', 'f2', 'f3', 'f4', 'f5', 'concerned_roles_array', 'tracking_code', 'id', 'digest', 'fts', 'workflow_roles', 'user_id', 'f6', 'fbo1', 'submission_context', 'fbo2', 'receipt_time', 'id_display', 'actions_roles_array', 'status', 'workflow_roles_array', 'workflow_data', 'anonymised', 'backoffice_submission', 'criticality_level', 'submission_channel', 'page_no'])
     own_conn = True
     rebuild_global_views = True
     rebuild_views = True
     sql_type = 'bytea'
     table_name = 'formdata_301_test_victor'
     x = (u'last_jump_datetime',)

  File "/usr/lib/python2.7/dist-packages/wcs/sql.py", line 348, in f
   346         except psycopg2.Error:
   347             get_connection().rollback()
>  348             raise
   349     return f
   350 

  locals: 
     args = (<FormDef 'test victor' id:301>,)
     func = <function do_formdef_tables at 0x7ff69c4402a8>
     kwargs = {'rebuild_global_views': True, 'rebuild_views': True}

  File "/usr/lib/python2.7/dist-packages/wcs/formdef.py", line 362, in store
   360             import sql
   361             sql.do_formdef_tables(self, rebuild_views=True,
>  362                     rebuild_global_views=True)
   363         return t
   364 

  locals: 
     new_internal_identifier = 'test-victor'
     self = <FormDef 'test victor' id:301>
     sql = <module 'wcs.sql' from '/usr/lib/python2.7/dist-packages/wcs/sql.pyc'>
     t = None

  File "/usr/lib/python2.7/dist-packages/wcs/admin/forms.py", line 292, in handle
   290                             self.changed = True
   291                             setattr(self.formdef, attr, new_value)
>  292             self.formdef.store()
   293             return redirect('..')
   294 

  locals: 
     attr = 'digest_template'
     attrs = ['confirmation', 'only_allow_one', 'disabled', 'enable_tracking_codes', 'private_status_and_history', 'always_advertise', 'disabled_redirection', 'publication_date', 'expiration_date', 'has_captcha', 'description', 'keywords', 'category_id', 'skip_from_360_view', 'geoloc_label', 'appearance_keywords', 'digest_template']
     form = <qommon.form.Form object at 0x7ff6973470d0>
     new_value = '46'
     self = <wcs.admin.forms.OptionsDirectory object at 0x7ff697de8190>
     title = 'Cat\xc3\xa9gorie'
     widget = None

  File "/usr/lib/python2.7/dist-packages/wcs/admin/forms.py", line 233, in category
   231                value=self.formdef.category_id,
   232                options=[(None, '---', '')] + categories)
>  233         return self.handle(form, _('Category'))
   234 
   235     def geolocations(self):

  locals: 
     categories = [('35', 'Accueil de loisirs', '35'), ('21', 'Aide aux personnes \xc3\xa2g\xc3\xa9es', '21'), ('44', 'Aides', '44'), ('45', 'aides', '45'), ('46', 'AIDES', '46'), ('40', "Allocation Personnalis\xc3\xa9e d'Autonomie", '40'), ('22', 'biblioth\xc3\xa8ques d\xc3\xa9partementales', '22'), ('42', 'CNIL - Internet', '42'), ('5', 'Consultations', '5'), ('20', 'Contactez-nous', '20'), ('12', 'Culture et loisirs', '12'), ('32', 'D\xc3\xa9marches en ligne', '32'), ('34', 'Dossier enfance', '34'), ('14', "Entr'ouvert", '14'), ('1', '\xc3\x89tat civil', '1'), ('9', 'Famille', '9'), ('26', 'Formalit\xc3\xa9s pour les associations', '26'), ('11', 'Formalit\xc3\xa9s pour les entreprises', '11'), ('13', 'Formulaires agents', '13'), ('43', 'Fournitures', '43'), ('2', 'Hygi\xc3\xa8ne - salubrit\xc3\xa9 - environnement', '2'), ('39', "Implicit - Demandes d'aide", '39'), ('7', "Liaison entre gestionnaire d'un b\xc3\xa2timent et services techniques", '7'), ('37', 'Logement', '37'), ('28', 'Migrations', '28'), ('33', 'Mini-camps ', '33'), ('18', 'Mission des archives', '18'), ('6', 'Papiers - Citoyennet\xc3\xa9', '6'), ('19', 'Patrimoine', '19'), ('25', 'Propret\xc3\xa9', '25'), ('10', 'Sant\xc3\xa9', '10'), ('38', 'S\xc3\xa9curit\xc3\xa9', '38'), ('23', 'Signalements - Sollicitations', '23'), ('41', 'Situation personnelle', '41'), ('24', 'T\xc3\xa9l\xc3\xa9alarme', '24'), ('36', 'Transports', '36'), ('15', 'Travail', '15'), ('16', 'Urbanisme', '16'), ('8', 'Vie pratique', '8')]
     form = <qommon.form.Form object at 0x7ff6973470d0>
     self = <wcs.admin.forms.OptionsDirectory object at 0x7ff697de8190>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 67, in _q_traverse
    65                 raise TraversalError
    66         elif hasattr(obj, '__call__'):
>   67             return obj()
    68         else:
    69             return obj

  locals: 
     component = 'category'
     name = 'category'
     obj = <bound method OptionsDirectory.category of <wcs.admin.forms.OptionsDirectory object at 0x7ff697de8190>>
     path = []
     self = <wcs.admin.forms.OptionsDirectory object at 0x7ff697de8190>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 63, in _q_traverse
    61         if path:
    62             if hasattr(obj, '_q_traverse'):
>   63                 return obj._q_traverse(path)
    64             else:
    65                 raise TraversalError

  locals: 
     component = 'options'
     name = 'options'
     obj = <wcs.admin.forms.OptionsDirectory object at 0x7ff697de8190>
     path = ['category']
     self = <wcs.admin.forms.FormDefPage object at 0x7ff697281290>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 63, in _q_traverse
    61         if path:
    62             if hasattr(obj, '_q_traverse'):
>   63                 return obj._q_traverse(path)
    64             else:
    65                 raise TraversalError

  locals: 
     component = '301'
     name = None
     obj = <wcs.admin.forms.FormDefPage object at 0x7ff697281290>
     path = ['options', 'category']
     self = <wcs.admin.forms.FormsDirectory object at 0x7ff6a19a04d0>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 91, in _q_traverse
    89     def _q_traverse(self, path):
    90         self._q_access()
>   91         return super(AccessControlled, self)._q_traverse(path)
    92 
    93 

  locals: 
     path = ['301', 'options', 'category']
     self = <wcs.admin.forms.FormsDirectory object at 0x7ff6a19a04d0>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 63, in _q_traverse
    61         if path:
    62             if hasattr(obj, '_q_traverse'):
>   63                 return obj._q_traverse(path)
    64             else:
    65                 raise TraversalError

  locals: 
     component = 'forms'
     name = None
     obj = <wcs.admin.forms.FormsDirectory object at 0x7ff6a19a04d0>
     path = ['301', 'options', 'category']
     self = <auquotidien.modules.backoffice.BackofficeRootDirectory object at 0x7ff69c300f10>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 91, in _q_traverse
    89     def _q_traverse(self, path):
    90         self._q_access()
>   91         return super(AccessControlled, self)._q_traverse(path)
    92 
    93 

  locals: 
     path = ['forms', '301', 'options', 'category']
     self = <auquotidien.modules.backoffice.BackofficeRootDirectory object at 0x7ff69c300f10>

  File "/usr/lib/python2.7/dist-packages/wcs/backoffice/root.py", line 79, in _q_traverse
    77                 pass
    78         get_response().add_javascript(['jquery.js', 'qommon.js', 'gadjo.js'])
>   79         return super(RootDirectory, self)._q_traverse(path)
    80 
    81     @classmethod

  locals: 
     path = ['forms', '301', 'options', 'category']
     self = <auquotidien.modules.backoffice.BackofficeRootDirectory object at 0x7ff69c300f10>

  File "/usr/lib/python2.7/dist-packages/quixote/directory.py", line 63, in _q_traverse
    61         if path:
    62             if hasattr(obj, '_q_traverse'):
>   63                 return obj._q_traverse(path)
    64             else:
    65                 raise TraversalError

  locals: 
     component = 'backoffice'
     name = 'backoffice'
     obj = <auquotidien.modules.backoffice.BackofficeRootDirectory object at 0x7ff69c300f10>
     path = ['forms', '301', 'options', 'category']
     self = <auquotidien.modules.root.AlternateRootDirectory object at 0x7ff69fb15dd0>

  File "/usr/lib/python2.7/dist-packages/auquotidien/modules/root.py", line 849, in _q_traverse
   847                     return redirect('%s%s/%s' % (base_url, f.category.url_name, uri_rest))
   848 
>  849             raise e
   850 
   851 

  locals: 
     path = ['backoffice', 'forms', '301', 'options', 'category']
     response = <wcs.qommon.http_response.HTTPResponse instance at 0x7ff69c1e0c20>
     self = <auquotidien.modules.root.AlternateRootDirectory object at 0x7ff69fb15dd0>

  File "/usr/lib/python2.7/dist-packages/quixote/publish.py", line 253, in try_publish
   251                 permanent=True)
   252         components = path[1:].split('/')
>  253         output = self.root_directory._q_traverse(components)
   254         # The callable ran OK, commit any changes to the session
   255         self.finish_successful_request()

  locals: 
     components = ['backoffice', 'forms', '301', 'options', 'category']
     path = '/backoffice/forms/301/options/category'
     request = <wcs.compat.CompatHTTPRequest instance at 0x7ff6972add88>
     self = <wcs.compat.CompatWcsPublisher object at 0x7ff69fb15e10>

  File "/usr/lib/python2.7/dist-packages/wcs/views.py", line 42, in get_context_data
    40                 get_publisher().session_manager.finish_successful_request()
    41             self.quixote_response = get_request().response
>   42             context.update(template.get_decorate_vars(body, get_response(), generate_breadcrumb=True))
    43 
    44         return context

  locals: 
     context = {u'view': <wcs.views.Backoffice object at 0x7ff69689ff90>}
     kwargs = {}
     self = <wcs.views.Backoffice object at 0x7ff69689ff90>

  File "/usr/lib/python2.7/dist-packages/wcs/compat.py", line 56, in get
    54             self.quixote_response = get_request().response
    55         except Exception as exc:
>   56             context = {'body': get_publisher().finish_failed_request()}
    57             self.quixote_response = get_request().response
    58 

  locals: 
     args = ()
     exc = ProgrammingError('relation "wcs_category_aides" already exists\n',)
     kwargs = {}
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <wcs.views.Backoffice object at 0x7ff69689ff90>

  File "/usr/lib/python2.7/dist-packages/wcs/views.py", line 29, in post
    27 
    28     def post(self, request, *args, **kwargs):
>   29         return self.get(request, *args, **kwargs)
    30 
    31     def get_context_data(self, **kwargs):

  locals: 
     args = ()
     kwargs = {}
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <wcs.views.Backoffice object at 0x7ff69689ff90>

  File "/usr/lib/python2.7/dist-packages/django/views/generic/base.py", line 88, in dispatch
    86         else:
    87             handler = self.http_method_not_allowed
>   88         return handler(request, *args, **kwargs)
    89 
    90     def http_method_not_allowed(self, request, *args, **kwargs):

  locals: 
     args = ()
     handler = <bound method Backoffice.post of <wcs.views.Backoffice object at 0x7ff69689ff90>>
     kwargs = {}
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <wcs.views.Backoffice object at 0x7ff69689ff90>

  File "/usr/lib/python2.7/dist-packages/django/views/generic/base.py", line 68, in view
    66             self.args = args
    67             self.kwargs = kwargs
>   68             return self.dispatch(request, *args, **kwargs)
    69         view.view_class = cls
    70         view.view_initkwargs = initkwargs

  locals: 
     args = ()
     cls = <class 'wcs.views.Backoffice'>
     initkwargs = {}
     kwargs = {}
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <wcs.views.Backoffice object at 0x7ff69689ff90>

  File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 185, in _get_response
   183             wrapped_callback = self.make_view_atomic(callback)
   184             try:
>  185                 response = wrapped_callback(request, *callback_args, **callback_kwargs)
   186             except Exception as e:
   187                 response = self.process_exception_by_middleware(e, request)

  locals: 
     callback = <function Backoffice at 0x7ff69c340050>
     callback_args = ()
     callback_kwargs = {}
     middleware_method = <bound method PrometheusStatsMiddleware.process_view of <hobo.middleware.stats.PrometheusStatsMiddleware object at 0x7ff69fae32d0>>
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     resolver = <RegexURLResolver 'wcs.urls' (None:None) ^/>
     resolver_match = ResolverMatch(func=wcs.views.Backoffice, args=(), kwargs={}, url_name=None, app_names=[], namespaces=[])
     response = None
     self = <django.core.handlers.wsgi.WSGIHandler object at 0x7ff6a44c1410>
     wrapped_callback = <function Backoffice at 0x7ff69c340050>

  File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 249, in _legacy_get_response
   247 
   248         if response is None:
>  249             response = self._get_response(request)
   250         return response

  locals: 
     middleware_method = <bound method PrometheusStatsMiddleware.process_request of <hobo.middleware.stats.PrometheusStatsMiddleware object at 0x7ff69fae32d0>>
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     response = None
     self = <django.core.handlers.wsgi.WSGIHandler object at 0x7ff6a44c1410>

  File "/usr/lib/python2.7/dist-packages/django/core/handlers/exception.py", line 41, in inner
    39     def inner(request):
    40         try:
>   41             response = get_response(request)
    42         except Exception as exc:
    43             response = response_for_exception(request, exc)

  locals: 
     get_response = <bound method WSGIHandler._legacy_get_response of <django.core.handlers.wsgi.WSGIHandler object at 0x7ff6a44c1410>>
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>

  File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 124, in get_response
   122         set_urlconf(settings.ROOT_URLCONF)
   123 
>  124         response = self._middleware_chain(request)
   125 
   126         # This block is only needed for legacy MIDDLEWARE_CLASSES; if

  locals: 
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <django.core.handlers.wsgi.WSGIHandler object at 0x7ff6a44c1410>

  File "/usr/lib/python2.7/dist-packages/django/core/handlers/wsgi.py", line 157, in __call__
   155         signals.request_started.send(sender=self.__class__, environ=environ)
   156         request = self.request_class(environ)
>  157         response = self.get_response(request)
   158 
   159         response._handler_class = self.__class__

  locals: 
     environ = {'HTTP_REFERER': 'https://demarches-publik.entrouvert.com/backoffice/forms/301/', 'SERVER_PROTOCOL': 'HTTP/1.0', 'uwsgi.version': '2.0.14-debian', 'SCRIPT_NAME': '', 'REQUEST_METHOD': 'POST', 'PATH_INFO': '/backoffice/forms/301/options/category', 'HTTP_ORIGIN': 'https://demarches-publik.entrouvert.com', 'HTTP_X_FORWARDED_SSL': 'on', 'QUERY_STRING': '', 'HTTP_X_REAL_IP': '80.12.92.47', 'CONTENT_LENGTH': '355', 'HTTP_USER_AGENT': 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.53 Safari/537.36', 'HTTP_CONNECTION': 'close', 'HTTP_COOKIE': 'publik_portal_agent_url=https%3A%2F%2Fportail-agent-publik.entrouvert.com%2F; publik_portal_agent_title=Portail%20agent; A2_OPENED_SESSION=1; wcs-7ef3cb="75f88fda86b1aec3"', 'SERVER_NAME': 'wcs', 'REMOTE_ADDR': '80.12.92.47', 'HTTP_X_FORWARDED_PROTOCOL': 'ssl', 'wsgi.url_scheme': 'https', 'SERVER_PORT': '80', 'HTTP_X_PUBLIK_APPLICATION': 'wcs', 'uwsgi.node': 'wcs', 'HTTP_X_FORWARDED_PROTO': 'https', 'wsgi.input': <uwsgi._Input object at 0x7ff69c067d20>, 'HTTP_HOST': 'demarches-publik.entrouvert.com', 'wsgi.multithread': False, 'HTTP_UPGRADE_INSECURE_REQUESTS': '1', 'HTTP_CACHE_CONTROL': 'max-age=0', 'REQUEST_URI': '/backoffice/forms/301/options/category', 'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8', 'wsgi.version': (1, 0), 'HTTP_X_FORWARDED_FOR': '80.12.92.47, 172.20.0.2, 80.12.92.47', 'wsgi.errors': <open file 'wsgi_errors', mode 'w' at 0x7ff69fd4d390>, 'wsgi.multiprocess': True, 'HTTP_ACCEPT_LANGUAGE': 'en-US,en;q=0.9,fr;q=0.8', 'wsgi.run_once': False, 'CONTENT_TYPE': 'multipart/form-data; boundary=----WebKitFormBoundary64oeIP4vB4OThBkZ', 'wsgi.file_wrapper': <built-in function uwsgi_sendfile>, 'HTTP_ACCEPT_ENCODING': 'gzip, deflate, br'}
     request = <WSGIRequest: POST '/backoffice/forms/301/options/category'>
     self = <django.core.handlers.wsgi.WSGIHandler object at 0x7ff6a44c1410>
     start_response = <built-in function uwsgi_spit>

Form:
_form_id        'b209cc650866d893'
category_id     '46'
submit          'Valider'

Cookies:
A2_OPENED_SESSION '1'
publik_portal_agent_title 'Portail%20agent'
publik_portal_agent_url 'https%3A%2F%2Fportail-agent-publik.entrouvert.com%2F'
wcs-7ef3cb      '75f88fda86b1aec3'

Environment:
CONTENT_LENGTH  '355'
CONTENT_TYPE    'multipart/form-data; boundary=----WebKitFormBoundary64oeIP4vB4OThBkZ'
HTTP_ACCEPT     'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8'
HTTP_ACCEPT_ENCODING 'gzip, deflate, br'
HTTP_ACCEPT_LANGUAGE 'en-US,en;q=0.9,fr;q=0.8'
HTTP_CACHE_CONTROL 'max-age=0'
HTTP_CONNECTION 'close'
HTTP_COOKIE     'publik_portal_agent_url=https%3A%2F%2Fportail-agent-publik.entrouvert.com%2F; publik_portal_agent_title=Portail%20agent; A2_OPENED_SESSION=1; wcs-7ef3cb="75f88fda86b1aec3"'
HTTP_HOST       'demarches-publik.entrouvert.com'
HTTP_ORIGIN     'https://demarches-publik.entrouvert.com'
HTTP_REFERER    'https://demarches-publik.entrouvert.com/backoffice/forms/301/'
HTTP_UPGRADE_INSECURE_REQUESTS '1'
HTTP_USER_AGENT 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.53 Safari/537.36'
HTTP_X_FORWARDED_FOR '80.12.92.47, 172.20.0.2, 80.12.92.47'
HTTP_X_FORWARDED_PROTO 'https'
HTTP_X_FORWARDED_PROTOCOL 'ssl'
HTTP_X_FORWARDED_SSL 'on'
HTTP_X_PUBLIK_APPLICATION 'wcs'
HTTP_X_REAL_IP  '80.12.92.47'
PATH_INFO       '/backoffice/forms/301/options/category'
QUERY_STRING    ''
REMOTE_ADDR     '80.12.92.47'
REMOTE_USER     '13'
REQUEST_METHOD  'POST'
REQUEST_URI     '/backoffice/forms/301/options/category'
SCRIPT_NAME     ''
SERVER_NAME     'wcs'
SERVER_PORT     '80'
SERVER_PROTOCOL 'HTTP/1.0'
uwsgi.node      'wcs'
uwsgi.version   '2.0.14-debian'
wsgi.errors     <open file 'wsgi_errors', mode 'w' at 0x7ff69fd4d390>
wsgi.file_wrapper <built-in function uwsgi_sendfile>
wsgi.input      <uwsgi._Input object at 0x7ff69c067d20>
wsgi.multiprocess True
wsgi.multithread False
wsgi.run_once   False
wsgi.url_scheme 'https'
wsgi.version    (1, 0)

History

#2 Updated by Frédéric Péters 3 months ago

  • Project changed from Publik to w.c.s.

Also available in: Atom PDF