import sys
from PyQt5.QtWidgets import QApplication
from PyQt5.QtCore import QUrl
from PyQt5.QtWebEngineWidgets import QWebEngineView
PDFJS = f"file:///pdfjs-2.12.313-dist/web/viewer.html"
print(PDFJS)
PDF = f'file:///file:///blank-f-119.pdf'
print("loading PDF:", PDF)
class Window(QWebEngineView):
def __init__(self):
super(Window, self).__init__()
self.load(QUrl.fromUserInput(f'{PDFJS}?file={PDF}'))
if __name__ == '__main__':
app = QApplication(sys.argv)
window = Window()
window.showMaximized()
sys.exit(app.exec_())
import requests
import csv
link = 'https://dsa.court.gov.ua/open_data_json.php?json=532'
response = requests.get(link).json()
urls = []
for item in response['Файли']:
urls.append(list(item.values())[0])
for url in urls:
with requests.get(url, stream=True) as response:
response.raise_for_status()
with open('121.csv', "a") as file:
writer = csv.writer(file)
writer.writerow(response)
спасибо все получилось) я пробовал но в первый раз было мимо
заменил JSONObject на JSONArray и все пошло по маслу)
спс