From cfe3cff77caae09d55619fc2d552c022cd2b1415 Mon Sep 17 00:00:00 2001 From: hsafaei Date: Tue, 2 Sep 2025 11:59:08 +0330 Subject: [PATCH] refactor --- 1_errors.txt | 200 ------------------ SqlToElasticMajles | 1 - sql_helper.py => common/sql_helper.py | 0 import_elastic_async.py | 2 +- temps/__pycache__/general.cpython-311.pyc | Bin 1355 -> 0 bytes {_back => temps/_back}/1_LWTopic1_error.py | 0 {_back => temps/_back}/5_opopinion_error.py | 0 {_back => temps/_back}/_two_line.py | 0 .../_queryies}/Mashrouh Query1.sql | 0 {_queryies => temps/_queryies}/SQLQuery20.sql | 0 {_queryies => temps/_queryies}/SQLQuery25.sql | 0 {_queryies => temps/_queryies}/SQLQuery33.sql | 0 {_queryies => temps/_queryies}/SQLQuery45.sql | 0 {_queryies => temps/_queryies}/amar.sql | 0 {_queryies => temps/_queryies}/lwlaw_full.sql | 0 .../_queryies}/mashrouh1111.sql | 0 .../_queryies}/qavanin_lwlaw_full.sql | 0 17 files changed, 1 insertion(+), 202 deletions(-) delete mode 100644 1_errors.txt delete mode 160000 SqlToElasticMajles rename sql_helper.py => common/sql_helper.py (100%) delete mode 100644 temps/__pycache__/general.cpython-311.pyc rename {_back => temps/_back}/1_LWTopic1_error.py (100%) rename {_back => temps/_back}/5_opopinion_error.py (100%) rename {_back => temps/_back}/_two_line.py (100%) rename {_queryies => temps/_queryies}/Mashrouh Query1.sql (100%) rename {_queryies => temps/_queryies}/SQLQuery20.sql (100%) rename {_queryies => temps/_queryies}/SQLQuery25.sql (100%) rename {_queryies => temps/_queryies}/SQLQuery33.sql (100%) rename {_queryies => temps/_queryies}/SQLQuery45.sql (100%) rename {_queryies => temps/_queryies}/amar.sql (100%) rename {_queryies => temps/_queryies}/lwlaw_full.sql (100%) rename {_queryies => temps/_queryies}/mashrouh1111.sql (100%) rename {_queryies => temps/_queryies}/qavanin_lwlaw_full.sql (100%) diff --git a/1_errors.txt b/1_errors.txt deleted file mode 100644 index 38445ce..0000000 --- a/1_errors.txt +++ /dev/null @@ -1,200 +0,0 @@ - - id : 7146684233a18337 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.072893 - -************************************************** - - id : 5786684233a599bb - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.091862 - -************************************************** - - id : 6296684233a65bf6 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.105075 - -************************************************** - - id : 1846684233a1833d - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.117742 - -************************************************** - - id : 4236684233a1833c - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.126099 - -************************************************** - - id : 8996684233a65bf4 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.138489 - -************************************************** - - id : 1336684233a32c6b - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.157003 - -************************************************** - - id : 2606684233a25dda - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.179001 - -************************************************** - - id : 6076684233a4dc06 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.189007 - -************************************************** - - id : 5926684233a599c5 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.200010 - -************************************************** - - id : 1996684233a65bf7 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.208003 - -************************************************** - - id : 4906684233a7f0bb - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.216003 - -************************************************** - - id : 5526684233a599c3 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.223002 - -************************************************** - - id : 8126684233a599c2 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.232022 - -************************************************** - - id : 3436684233a599c1 - filename : G:\Project2\NLP\SqlToElasticMajles\.env\Lib\site-packages\elasticsearch\_sync\client\_base.py - function : _perform_request - err line no : 352 - err line : raise HTTP_EXCEPTIONS.get(meta.status, ApiError)( - err message : BadRequestError(400, 'illegal_argument_exception', 'mapper [result_objects.values.score] cannot be changed from type [text] to [long]') - err date : 2025-02-15 19:58:40.240002 - -************************************************** - - id : 192.168.23.28 - filename : g:\Project2\NLP\SqlToElasticMajles\log_search_repair.py - function : refactorLogSearch - err line no : 86 - err line : values.push(value) - err message : 'list' object has no attribute 'push' - err date : 2025-02-24 16:42:17.118143 - -************************************************** - - id : 192.168.23.28 - filename : g:\Project2\NLP\SqlToElasticMajles\log_search_repair.py - function : refactorLogSearch - err line no : 86 - err line : values.push(value) - err message : 'list' object has no attribute 'push' - err date : 2025-02-24 16:43:43.295280 - -************************************************** - - id : 192.168.23.28 - filename : g:\Project2\NLP\SqlToElasticMajles\log_search_repair.py - function : refactorLogSearch - err line no : 103 - err line : values = prev_data["values"] - err message : list indices must be integers or slices, not str - err date : 2025-02-24 16:48:22.761145 - -************************************************** - - id : 192.168.23.28 - filename : g:\Project2\NLP\SqlToElasticMajles\log_search_repair.py - function : refactorLogSearch - err line no : 103 - err line : values = prev_data["values"] - err message : list indices must be integers or slices, not str - err date : 2025-02-24 16:50:51.999686 - -************************************************** - - id : 192.168.23.28 - filename : g:\Project2\NLP\SqlToElasticMajles\log_search_repair.py - function : refactorLogSearch - err line no : 105 - err line : values = prev_data["values"] - err message : list indices must be integers or slices, not str - err date : 2025-02-24 16:58:15.153052 - -************************************************** diff --git a/SqlToElasticMajles b/SqlToElasticMajles deleted file mode 160000 index 43f46a1..0000000 --- a/SqlToElasticMajles +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 43f46a17a3c0cd254cc0c2ab6a7c1d33a543f4b0 diff --git a/sql_helper.py b/common/sql_helper.py similarity index 100% rename from sql_helper.py rename to common/sql_helper.py diff --git a/import_elastic_async.py b/import_elastic_async.py index 3d29532..2fbd136 100644 --- a/import_elastic_async.py +++ b/import_elastic_async.py @@ -3,7 +3,7 @@ import sys from dotenv import load_dotenv from elastic_helper_async import elastic_helper_async import asyncio -from sql_helper import sql_helper +from common.sql_helper import sql_helper from time import sleep # from docker import docker_import # from version_util import VersionUtil diff --git a/temps/__pycache__/general.cpython-311.pyc b/temps/__pycache__/general.cpython-311.pyc deleted file mode 100644 index 65c827e833d9766aaa4553d8bf2e2c5101882f51..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1355 zcmZuvOK;;;6u!>GiIZkJO{ES}N26f@QWlgtZOVkwk=)p6oQa+0op?H`9NRQ@{F3c7 zjcKF^u>p+)J2os>4WRiStXW20jl_ywq5_MNkhpdq0>QQQopV2*bM86U-w&x&0>CBw z^{4oA1b|=t&Fu=`I9KmO=UX5G5m5mL#1MywVJ;*gQb>$^7vjQV^b5d6M5F;S=x=@! z%P$cCq)B;O>JoBQEH|RZD;mA70WLwJNE>|36d)ou1(YuL z^QHQ>P-6DFg}hM7vg3+281y^bfIq^`il$EdSgt!5!`KT}8RCpW>@qH~>o+NOU_Wx% z5KHy3;F>}OAD{Pjh!KBObU3YO^gF{5-=+P5hP`fmKr7})w5ASWtqJ5bzFT(1Vt&-? z;HuwCx6~T5N_lu~Yj|KaR=MFdznA_|@qcod>sY0BaUDzV{3{pM2uRcz(+^ zNF(n&DLS&w@LH8s<@0j!h-%j>rK+PGR?l*0u9M5v+U}WqpEpfa7I;TC^bZx=&@&+~ zMU0$*Vaaa5dMF_XlIaLH+6oL59`MC>^$i3lG-L`zHiaUaLV-=g4%E`^Qto^)dI?-e zi>Qy6NZ`i;KNR@!zz_TQ3TC~&%bZ3oBj1N^EB@2If}7WO#58&tg_6ctca@|X&zjZa z4=A=>pr7Qt1VJBH_%T_an;yy-pUUEn7sazXyE%80tkZ3(e(+hNR(afztaHhl?l-8q z&$)?xl4uf#M1wkTAMQ7;k?lz0X~EESN$@Z2U?SQ3Et))Vqx;7l@*orTP;+94eZh+f z*HIoSj4a!*GN^~zL3uAO@($nUZOMy|Af@vf^i1Bi$A%?(5kbGutt1@FMj<>7*4sx% zAD^6RyrN3>i8+CPNI$_(&Lmy3cy-I1cqze>ct<+DKFmtP%$Q%|a|kmqPd%Cy=c}8u z(tP!S4;!=6A1GK!zkE86zc)|ZUxpEE?M-5184Y0%7AQ!rFJobBeGv!A%o2-WnMK0q zl2OR5fMj}^Lb3GXp3kkuu=QmaTS0#Z5N70J1Kdl0{rs!vU%q(x0-l;&n=x0g3y_Ig z7&KnAS$#&aP+5fnb=>q~C5j-adL!uhCt$6^7;6o}+xRD%A&yk(sr3%r`g*Vl2#YX+ rAajtK1$C===|ZkKem5K?80{zTSV58^aA`Bf+PM0=1qg> diff --git a/_back/1_LWTopic1_error.py b/temps/_back/1_LWTopic1_error.py similarity index 100% rename from _back/1_LWTopic1_error.py rename to temps/_back/1_LWTopic1_error.py diff --git a/_back/5_opopinion_error.py b/temps/_back/5_opopinion_error.py similarity index 100% rename from _back/5_opopinion_error.py rename to temps/_back/5_opopinion_error.py diff --git a/_back/_two_line.py b/temps/_back/_two_line.py similarity index 100% rename from _back/_two_line.py rename to temps/_back/_two_line.py diff --git a/_queryies/Mashrouh Query1.sql b/temps/_queryies/Mashrouh Query1.sql similarity index 100% rename from _queryies/Mashrouh Query1.sql rename to temps/_queryies/Mashrouh Query1.sql diff --git a/_queryies/SQLQuery20.sql b/temps/_queryies/SQLQuery20.sql similarity index 100% rename from _queryies/SQLQuery20.sql rename to temps/_queryies/SQLQuery20.sql diff --git a/_queryies/SQLQuery25.sql b/temps/_queryies/SQLQuery25.sql similarity index 100% rename from _queryies/SQLQuery25.sql rename to temps/_queryies/SQLQuery25.sql diff --git a/_queryies/SQLQuery33.sql b/temps/_queryies/SQLQuery33.sql similarity index 100% rename from _queryies/SQLQuery33.sql rename to temps/_queryies/SQLQuery33.sql diff --git a/_queryies/SQLQuery45.sql b/temps/_queryies/SQLQuery45.sql similarity index 100% rename from _queryies/SQLQuery45.sql rename to temps/_queryies/SQLQuery45.sql diff --git a/_queryies/amar.sql b/temps/_queryies/amar.sql similarity index 100% rename from _queryies/amar.sql rename to temps/_queryies/amar.sql diff --git a/_queryies/lwlaw_full.sql b/temps/_queryies/lwlaw_full.sql similarity index 100% rename from _queryies/lwlaw_full.sql rename to temps/_queryies/lwlaw_full.sql diff --git a/_queryies/mashrouh1111.sql b/temps/_queryies/mashrouh1111.sql similarity index 100% rename from _queryies/mashrouh1111.sql rename to temps/_queryies/mashrouh1111.sql diff --git a/_queryies/qavanin_lwlaw_full.sql b/temps/_queryies/qavanin_lwlaw_full.sql similarity index 100% rename from _queryies/qavanin_lwlaw_full.sql rename to temps/_queryies/qavanin_lwlaw_full.sql