#author("2025-02-04T16:33:50+09:00","default:irrp","irrp") #author("2025-02-06T23:30:54+09:00","default:irrp","irrp") →自動化 →自動化系エージェント →テストツール →Python関連 #contents *一般 [#ec5391c5] -[[AIの無断学習は絶対許さない──Webクローラーを“出口のない落とし穴”に閉じ込めるプログラム、海外ユーザーが公開 - ITmedia AI+>https://www.itmedia.co.jp/aiplus/articles/2502/06/news079.html]] 2025.2 -[[LLMのためにHTMLの構造解析を頑張ってみた - ABEJA Tech Blog>https://tech-blog.abeja.asia/entry/advent-2024-day07]] 2024.12 -[[TavilyとCustom Search APIを徹底比較!生成AI時代のスクレイピング技術を解説 | WEEL>https://weel.co.jp/media/tavily/]] 2024.11 -[[数行のコードでAIエージェントがブラウザを操作!Python×Sentientを用いたブラウザ制御 #Chrome - Qiita>https://qiita.com/sergicalsix/items/f44d133c699b11d88684]] 2024.10 -[[SUUMOの物件情報を自動取得(スクレイピング)したのでコードを解説する。 #Python - Qiita>https://qiita.com/tomyu/items/a08d3180b7cbe63667c9#:~:text=SUUMO%20%E3%81%A8%E3%81%AF.]] 2022 -[[【プログラミング不要】suumoの物件情報をスプシに一覧化する方法|ハチ>https://note.com/na_mroon5/n/n57fcd6a409a1]] 2024.10 -[[【令和最新版】令和のWebスクレイピング(クロール)【ベストプラクティス】>https://zenn.dev/fp16/articles/42b8047dad3bdc]] 2024.9 cheerioでHTMLを解析 Playwrightなどで要素指定でデータを取得する APIを見つけて叩く(バックエンドとの通信を再現してデータを取得) LLMでサイト構造を解析してデータを取得する Next.jsからのレスポンスに含まれているデータを解析して取得する -[[ウェブスクレイピングの効率化: マルチスレッドとイテレータで実現する最適なデータ収集 #Python - Qiita>https://qiita.com/Tadataka_Takahashi/items/066eedbcbafb8c0a432b]] 2024.9 -[[Reader API>https://jina.ai/reader/]] 2024.5 -[[【Python】Webサイトのスクリーンショットを自動化|分析屋>https://note.com/bunsekiya_tech/n/n7f88e98e4402]] 2023.8 -[[【個人開発】AWSでサーバーレスなWebスクレイピングアプリを作ってみた - Qiita>https://qiita.com/ozzy3/items/b2ef8f5329484de5095f]] 2023.3 --Beautiful Soup -[[【規約】Amazonのスクレイピングは本当に禁止?規約を確認してみた - しらすのStudy blog>https://teshi-learn.com/2020-08/amazon-scraping-regulation/]] 2023.3 --ログインしていなければ規約の強制力はない -[[Web記事の本文をJavaで抽出する - きしだのHatena>https://nowokay.hatenablog.com/entry/2023/02/21/041440]] 2023.2 -[[Python Webスクレイピング テクニック集「取得できない値は無い」JavaScript対応@追記あり6/12 - Qiita>https://qiita.com/Azunyan1111/items/b161b998790b1db2ff7a]] 2018 -[[現場のスクレイピング - Qiita>https://qiita.com/kawagoe6884/items/889f8f2cf816439c026b]] 2022.11 -[[機械学習用の画像を集めるのにicrawlerが便利だった - Qiita>https://qiita.com/tkt989/items/84c6581dfa1d9a42dc2d]] 2018 -[[Web Scraping With Python (An Ultimate Guide) | Scrapingdog>https://www.scrapingdog.com/blog/web-scraping-with-python/]] 2022.9 -[[Pythonを使ってamazonの口コミの闇を暴いてみた - YouTube>https://www.youtube.com/watch?v=R7rApds4syQ]] 2020.8 -[[Web Scraping and the Art of War: 5 Tools That Will Help Your Bot Win | by Web Data Central | Jul, 2022 | Level Up Coding>https://levelup.gitconnected.com/web-scraping-and-the-art-of-war-5-tools-that-will-help-your-bot-win-c2a3840d8b71]] 2022.7 -[[Web Scraping Google News with Python - DEV Community>https://dev.to/serpapi/web-scraping-google-news-with-python-19el]] 2022.7 -メモ:webbrowser.open() がコマンドラインからなら動くがVSCodeでは動かないとき、こうしたら動いた #! python3 import webbrowser firefoxPath = "C:/Program Files/Mozilla Firefox/firefox.exe %s" webbrowser.get(firefoxPath).open(someURL) -[[スクレイピングのメモ - Qiita>https://qiita.com/kujirahand/items/433eca4976bb57799ad1]] 2022.4 --RequestsとBeautifulSoup4 -[[Pythonでスクレイピングした株価をDBに格納する>https://qiita.com/ku_a_i/items/ab395c1cf4493517a1dd]] 2021.1 -[[年末年始の新幹線をPythonで予約する>https://rfushimi.hatenablog.jp/entry/2018/12/26/234108]] 2018.12 -[[スクレイピング→データ収集→整形→分析までの流れを初心者向けにまとめておく 〜Pythonに関するはてな記事を10年分スクレイピングし、Pythonトレンド分析を実際にやってみた〜 >https://review-of-my-life.blogspot.jp/2017/10/python-web-scraping-data-collection-analysis.html]] 2017.11 -[[日本株式のデータをスクレイピングなしで取得・リストにしたい>http://qiita.com/Kuma_T/items/911b5201c9313717ab50]] 2017.8.4 *Scrapy [#r092e1ae] -[[Scrapy>https://scrapy.org/]] --スクレイピング用フレームワーク -[[Scrapy入門>http://qiita.com/checkpoint/items/038b59b29df8e1e384a2]] -[[Scrapy Tutorial>https://docs.scrapy.org/en/latest/intro/tutorial.html]] *Selenium [#q51564ee] -[[【Python】Seleniumで読み込み待ちができない場合の対処方法 #Python3 - Qiita>https://qiita.com/ShonanFreshShirasu/items/a09cc412a790ad4ecf8f]] 2024.8 -[[【Python】Seleniumによるコンソールログの取得 | ジコログ>https://self-development.info/%e3%80%90python%e3%80%91selenium%e3%81%ab%e3%82%88%e3%82%8b%e3%82%b3%e3%83%b3%e3%82%bd%e3%83%bc%e3%83%ab%e3%83%ad%e3%82%b0%e3%81%ae%e5%8f%96%e5%be%97/]] 2023.10 -[[Seleniumが本当にバレバレなのか試してみた - Qiita>https://qiita.com/Guz9N9KLASTt/items/f62319a0f6ff00066f66]] 2023.8 -初期時に以下のようなエラーが出るのを抑制したい DevTools listening on ws://127.0.0.1:62525/devtools/browser/4d3b2f25-f55c-49e1-b02e-c9e4e83408ff [18588:15692:0718/091702.691:ERROR:edge_auth_errors.cc(486)] EDGE_IDENTITY: Get Default OS Account failed: Error: Primary Error: kImplicitSignInFailure, Secondary Error: kAccountProviderFetchError, Platform error: 0, Error string: --このようにすると良いらしい。参考:[[Selenium Edge Python errors auto close Edge browser after test execution - Stack Overflow>https://stackoverflow.com/questions/69919930/selenium-edge-python-errors-auto-close-edge-browser-after-test-execution]] from selenium.webdriver.edge.options import Options opt: Options = Options() # selenium 4 opt.experimental_options["excludeSwitches"] = ["enable-logging"] -[[Python Selenium でコンソールを非表示にする | クソざこCoding>https://www.zacoding.com/post/python-selenium-hide-console/]] 2021 from subprocess import CREATE_NO_WINDOW svc: Service = Service(driver_path) svc.creationflags = CREATE_NO_WINDOW # コンソールを一瞬表示しないようにする設定 -[[Seleniumでアラートポップアップのボタンを押す方法>https://rabbitfoot.xyz/selenium-alertpush/]] browser.switch_to.alert.accept() //OKの場合 browser.switch_to.alert.dismiss() //NGの場合 -[[Pythonでselenium 要素の存在を判定する方法 - Qiita>https://qiita.com/captainUmaru/items/1d9c1c5e37da986404f1]] 2023.6 --ポイントはdriver.find_element_by_idの代わり、driver.find_elements_by_idを使います。一見同じように見えますが、前者の場合は要素が存在しない時に異常が発生します。後者なら、要素が存在しなくでも異常が発生しない -[[【Python】Selenium(chromeDriver)実行時のコンソールを非表示にする | カメ助のブログ>https://www.kamesuke-blog.com/programming/python-selenium-no-window/]] 2021 -[[【Selenium】ドロップダウン/selectタグ選択,取得方法まとめ - ゆうきのせかい>https://yuki.world/selenium-select/]] 2023.6 -[[SeleniumとPlaywrightで起動済みのブラウザを操作する - Qiita>https://qiita.com/yk109/items/6cab9564d1844d272a8c]] 2023.6 -[[機能と EdgeOptions - Microsoft Edge Development | Microsoft Learn>https://learn.microsoft.com/ja-jp/microsoft-edge/webdriver-chromium/capabilities-edge-options]] 2023.6 -[[Seleniumを使って起動済みのMicrosoft Edgeを制御するPowerShellスクリプト 関連Tweet:https://twitter.com/kinuasa/status/1427151324328562689>https://gist.github.com/kinuasa/b5a183f1b253b4821b47aed0aa6c5054]] 2023.6 -[[Selenium4にアップグレードする方法 | Selenium>https://www.selenium.dev/ja/documentation/webdriver/getting_started/upgrade_to_selenium_4/]] 2023 -[[Selenium4のEdgedriverでデフォルトのダウンロードフォルダを変更する - Qiita>https://qiita.com/pm00/items/1eaf7d76ad68a4dcdf4d]] 2022 -[[PythonのSeleniumのElementClickInterceptedExceptionエラーを無理矢理回避する | my opinion is my own>https://zatoima.github.io/python-selenium-error-elementclickinterceptedexception.html]] 2021 --driver.set_window_size(1500,1500) -[[seleniumにてButtonがクリックできない時の対処法 - Qiita>https://qiita.com/DNA1980/items/528ff6269986b262acdc]] 2017 --画面外にある部品はクリックできないらしい。 --driver.execute_script("window.scrollTo(0, document.body.scrollHeight);") 下までスクロールしてやる -[[PythonとSeleniumを使ったプチ自動化で業務効率UPしてみた - RAKUS Developers Blog | ラクス エンジニアブログ>https://tech-blog.rakus.co.jp/entry/20221222/selenium]] 2022.12 -[[Seleniumレシピまとめ【スクレイピング】【Selenium4】 - Qiita>https://qiita.com/RisaM/items/da3650243005dcc25680]] 2022.12 -[[python - Passthrough is not supported, GL is disabled - Stack Overflow>https://stackoverflow.com/questions/67501093/passthrough-is-not-supported-gl-is-disabled]] 2021 -[[Seleniumでiframeに出入りしてみた - Qiita>https://qiita.com/Tokyo/items/7e61ac57ffd79b5a1085]] 2022.11 -[[Selenium - ページの読み込みが完了するまで待つ(python)>https://codechacha.com/ja/selenium-explicit-implicit-wait/]] 2022.11 -[[SeleniumとEdgeDriverでデフォルトのダウンロードフォルダを変更する(msedge-selenium-tools) - Qiita>https://qiita.com/pm00/items/4ad6edebe5cf2fe94833]] 2022.11 -[[SeleniumでスクレイピングをするためのTips - Qiita>https://qiita.com/Brutus/items/18e5a536dfce1f1b43bd]] 2022.10 -[[Python: Selenium: Dockerで、Chromeブラウザ最新版が動く仮想環境を立てて、24時間自動WEBサーフィンさせる環境の基礎を作る - Qiita>https://qiita.com/yagrush/items/18a39362a52d0d9e663b]] 2022.4 -[[Seleniumを試用 (Firefoxをコードで操作試行) 結果:成功 - Qiita>https://qiita.com/dl_from_scratch/items/b90579bcb35f460e4976]] 2022.4 -[[既に開いているEdgeを、WebDriverで操作する(C#) - Qiita>https://qiita.com/santarou6/items/a24bbbc07c57877eae8a]] 2022.3 -[[PythonのSeleniumを使って、起動済みのブラウザを操作する。 - Qiita>https://qiita.com/mimuro_syunya/items/2464cd2404b67ea5da56]] 2021 -[[BeautifulSoupとSeleniumのあわせ技でスクレイピングする | きいちログ>https://wptech.kiichiro.work/2xch5zq3e9/]] 2022 -[[SeleniumとBeautifulSoupの違いを簡単にまとめてみた>https://zenn.dev/moimoi_prog/articles/30f9e29569d31b]] 2022 -[[Python + Selenium + Chrome でファイル保存まわり - Qiita>https://qiita.com/memakura/items/f80d2e2c59514cfc14c9]] 2018 -[[【Python3】Seleniumを使用してウィンドウとタブの操作を行う方法 | せなブログ>https://senablog.com/python-selenium-window-tab/]] 2021 --全画面表示にするなど -[[[Python]Seleniumで操作するウィンドウを切り替える2つの方法を紹介 | たぬハック>https://tanuhack.com/selenium-change-window/]] 2019 --driver.switch_to.window(driver.window_handles[-1]) -[[Seleniumで指定フォルダにダウンロード + ファイルを指定のフォルダに移動する [Pythonチートシート]>https://life100create.com/selenium_download_move_file/]] 2021 -[[Python + Selenium + Chrome でファイル保存まわり - Qiita>https://qiita.com/memakura/items/f80d2e2c59514cfc14c9]] 2018 -[[SeleniumでEdgeを使うお話 - Qiita>https://qiita.com/uguisuheiankyo/items/e331ab59b881613908f3]] 2019 --[[Microsoft Edge WebDriver - Microsoft Edge Developer>https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/]] 2022.6 --以下のようなエラーが出てEdgeが起動しない場合は、最新のWebDriverを使うようにすると直ることがある。 EDGE_IDENTITY: Get Default OS Account failed: Error: Primary Error: kImplicitSignInFailure, Secondary Error: kAccountProviderFetchError, -[[Seleniumを使用しPythonでWebページのタイトルを取得する | Men of Letters(メン・オブ・レターズ) – 論理的思考/業務改善/プログラミング>https://laboratory.kazuuu.net/get-web-page-titles-in-python-using-selenium/]] 2020.12 --USB: usb_device_handle_win.cc:1020 Failed to read descriptor from node connection: システムに接続されたデバイスが機能していません。 (0x1F) というエラーについて --コンピュータの一部の機能を停止して省電力モードで待機(サスペンド)されているUSBデバイスのプロパティをChromeが読み取ろうとすることによって引き起こされるのが原因(https://stackoverflow.com/questions/65080685/usb-usb-device-handle-win-cc1020-failed-to-read-descriptor-from-node-connectio)。 --これは無視して良い -[[PythonでSeleniumを使ってChromeを操作するための基礎(自動化) | アールエフェクト>https://reffect.co.jp/python/selenium]] 2021.8 --https://chromedriver.chromium.org/downloads -[[Selenium 4で「DeprecationWarning」が出る場合の対策 | ジコログ>https://self-development.info/selenium-4%E3%81%A7%E3%80%8Cdeprecationwarning%E3%80%8D%E3%81%8C%E5%87%BA%E3%82%8B%E5%A0%B4%E5%90%88%E3%81%AE%E5%AF%BE%E7%AD%96/]] 2021 -[[簡単! JavaScriptで自動UIテスト>http://qiita.com/ysks/items/5c703334ef6f9a878c60]] -[[iPhone/Android含むブラウザ自動テストの最終兵器Selenium WebDriverとは>http://www.atmarkit.co.jp/fjava/special/webdriver01/01.html]] 2012.10.5 -[[Selenium>http://www.thinkit.co.jp/free/article/0705/2/1/]] --Webアプリ用テストツール -[[Webブラウザを使ったテストツールSeleniumとは>http://thinkit.co.jp/free/article/0705/2/1/]] -[[WebアプリテストツールSeleniumの紹介>http://journal.mycom.co.jp/articles/2006/09/29/selenium/]] ** VBA版 [#g3005794] -[[【Excel】SeleniumVBAがアドイン化されました - Qiita>https://qiita.com/yaju/items/acc58b2a98a5cfdcd4f0]] 2022.9 -[[VBAのスクレイピングを簡単楽にしてくれるSelenium|VBA技術解説>https://excel-ubara.com/excelvba4/EXCEL_VBA_401.html]] 2020