dbaldzhiev / cad_importer

QGIS CAD plugin
3 stars 2 forks source link

QGIS error #1

Open bitmapbulgaria opened 2 months ago

bitmapbulgaria commented 2 months ago

An error has occurred while executing Python code:

KeyError: 27671297 Traceback (most recent call last): File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cad_importer.py", line 382, in run CCF = utils.ReadCadastralFile(filename) File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 25, in init self.CadasterLayer = CadasterLayer(data, self.Header, self.ControlLayers.ControlCheckLayers[ File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 97, in init self.contourObj = [ContC(contour.groups(), hdr, self.lineObj, LDic, nests, CDic) for contour in contparse] File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 97, in self.contourObj = [ContC(contour.groups(), hdr, self.lineObj, LDic, nests, CDic) for contour in contparse] File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 333, in init self.pgon_pt, self.pgon_bad_flag = self.polygonize([lines[linesdic[i]].get_referenced_point_sequence.copy() for i in self.pgon_ids]) File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 333, in self.pgon_pt, self.pgon_bad_flag = self.polygonize([lines[linesdic[i]].get_referenced_point_sequence.copy() for i in self.pgon_ids]) KeyError: 27671297

Python version: 3.9.5 (tags/v3.9.5:0a7dcbd, May 3 2021, 17:27:52) [MSC v.1928 64 bit (AMD64)] QGIS version: 3.32.2-Lima Lima, c0b8833964

Python Path: C:/PROGRA~1/QGIS 3.32.2/apps/qgis/./python C:/Users/JC/AppData/Roaming/QGIS/QGIS3\profiles\default/python C:/Users/JC/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins C:/PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins C:\PROGRA~1\QGIS 3.32.2\apps\grass\grass83\etc\python C:\Users\JC\Documents C:\Program Files\QGIS 3.32.2\bin\python39.zip C:\PROGRA~1\QGIS 3.32.2\apps\Python39\DLLs C:\PROGRA~1\QGIS 3.32.2\apps\Python39\lib C:\Program Files\QGIS 3.32.2\bin C:\PROGRA~1\QGIS 3.32.2\apps\Python39 C:\PROGRA~1\QGIS 3.32.2\apps\Python39\lib\site-packages C:\PROGRA~1\QGIS 3.32.2\apps\Python39\lib\site-packages\win32 C:\PROGRA~1\QGIS 3.32.2\apps\Python39\lib\site-packages\win32\lib C:\PROGRA~1\QGIS 3.32.2\apps\Python39\lib\site-packages\Pythonwin C:/Users/JC/AppData/Roaming/QGIS/QGIS3\profiles\default/python C:\Users/JC/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\go2streetview C:\Users\JC\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\go2streetview\res

bitmapbulgaria commented 2 months ago

Подкарах го , обаче сега дава друга грешка: 2024-09-04T16:49:32 WARNING Traceback (most recent call last): File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cad_importer.py", line 382, in run CCF = utils.ReadCadastralFile(filename) File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 25, in init self.CadasterLayer = CadasterLayer(data, self.Header, self.ControlLayers.ControlCheckLayers[ File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 97, in init self.contourObj = [ContC(contour.groups(), hdr, self.lineObj, LDic, nests, CDic) for contour in contparse] File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 97, in self.contourObj = [ContC(contour.groups(), hdr, self.lineObj, LDic, nests, CDic) for contour in contparse] File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 333, in init self.pgon_pt, self.pgon_bad_flag = self.polygonize([lines[linesdic[i]].get_referenced_point_sequence.copy() for i in self.pgon_ids]) File "C:\PROGRA~1/QGIS 3.32.2/apps/qgis/./python/plugins\cad_importer\cadutils\utils.py", line 333, in self.pgon_pt, self.pgon_bad_flag = self.polygonize([lines[linesdic[i]].get_referenced_point_sequence.copy() for i in self.pgon_ids]) KeyError: 27671297

dbaldzhiev commented 2 months ago

Изглежда, че грешката е свързана със самия CAD4 файл. Можете ли да потвърдите дали файлът е свален от кадастъра или е създаден с друг софтуер? Можете да го изпратите тук или на support@cadtodxf.com, за да го разгледаме по-подробно. Имайте предвид, че този плъгин не претендира да поддържа всички видове CAD4 файлове. Най-много е тестван върху файлове, свалени директно от сайта на кадастъра. Основният проблем е, че документацията за CAD4 от МРРБ не е много консистентна, както и различните му имплементации в системи като mkad, АксТър и други.