réorganisation des dossiers

This commit is contained in:
SebF 2021-12-29 22:17:34 +01:00
parent 1c0421f87d
commit e795acb5a8
6 changed files with 8 additions and 6 deletions

View File

@ -31,8 +31,8 @@ import os
import argparse
import logging
import sys
from osm_vc63 import errors
from osm_vc63.utils import Utils
from rdoopy import errors
from rdoopy.utils import Utils
OVERPASS_URL = "http://overpass-api.de/api/interpreter"
GEO_API_URL = "https://api-adresse.data.gouv.fr"

View File

@ -29,7 +29,7 @@ import csv
from collections import OrderedDict
import requests
from pyexcel_ods3 import save_data
from osm_vc63 import errors
from rdoopy import errors
class Utils:
@ -44,7 +44,7 @@ class Utils:
self.geo_api_url = geo_api_url
self.dossier_resultats = dossier_resultats
with open("traductions.json", encoding="utf-8") as trads:
with open("configuration/traductions.json", encoding="utf-8") as trads:
self.traductions = json.load(trads)
self.lecture_requetes()
@ -271,10 +271,12 @@ class Utils:
def lecture_requetes(self):
"""Lecture des requêtes dans les fichiers de configuration"""
with open("requetes.json", encoding="utf-8") as reqs:
with open("configuration/requetes.json", encoding="utf-8") as reqs:
self.json_reqs = json.load(reqs)
with open("champs_generiques.json", encoding="utf-8") as champs_generiques:
with open(
"configuration/champs_generiques.json", encoding="utf-8"
) as champs_generiques:
self.json_champs_generiques = json.load(champs_generiques)
for req in self.json_reqs: