{"id":45474,"date":"2023-05-11T06:18:29","date_gmt":"2023-10-24T10:05:53","guid":{"rendered":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/"},"modified":"2024-04-30T03:33:57","modified_gmt":"2024-04-29T19:33:57","slug":"45474-2","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/","title":{"rendered":""},"content":{"rendered":"<p>macOS\u306bselenium\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3088\u3046\u3068\u3057\u305f\u3089\u4f55\u3084\u3089\u30a8\u30e9\u30fc\u304c\u51fa\u307e\u3057\u305f\u3002<\/p>\n<p>\u7d50\u8ad6\u304b\u3089\u8a00\u3046\u3068pip\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3057\u305f\u3089\u30a8\u30e9\u30fc\u304c\u89e3\u6d88\u3057\u3066selenium\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u304c\u3067\u304d\u307e\u3057\u305f?<\/p>\n<h2>\u3053\u3093\u306a\u65b9\u306b\u30aa\u30b9\u30b9\u30e1<\/h2>\n<ul class=\"post-ul\">pip\u30b3\u30de\u30f3\u30c9\u3067\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3057\u3066\u89e3\u6c7a\u7b56\u3092\u77e5\u308a\u305f\u3044\u65b9<\/ul>\n<pre class=\"post-pre\"><code>ERROR: Failed building wheel for cryptography\r\nERROR: Could not build wheels for cryptography which use PEP 517 and cannot be installed directly\r\n<\/code><\/pre>\n<h2>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u5931\u6557\u6642\u306e\u30a8\u30e9\u30fc\u5185\u5bb9<\/h2>\n<pre class=\"post-pre\"><code>% pip3 <span class=\"nb\">install <\/span>selenium\r\nDefaulting to user installation because normal site-packages is not writeable\r\nCollecting selenium\r\n\u30fb\u30fb\u30fb\uff08\u7701\u7565\uff09\r\nerror: can<span class=\"s1\">'t find Rust compiler\r\n If you are using an outdated pip version, it is possible a prebuilt wheel is available for this package but pip is not able to install from it. Installing from the wheel would avoid the need for a Rust compiler.\r\n To update pip, run:\r\n     pip install --upgrade pip\r\n and then retry package installation.\r\n If you did intend to build this package from source, try installing a Rust compiler from your system package manager and ensure it is on the PATH during installation. Alternatively, rustup (available at https:\/\/rustup.rs) is the recommended way to download and update the Rust compiler toolchain.\r\n This package requires Rust &gt;=1.41.0.\r\n ----------------------------------------\r\nERROR: Failed building wheel for cryptography\r\n\u30fb\u30fb\u30fb\uff08\u7701\u7565\uff09\r\nERROR: Could not build wheels for cryptography which use PEP 517 and cannot be installed directly\r\nWARNING: You are using pip version 20.2.3; however, version 21.3.1 is available.\r\nYou should consider upgrading via the '<\/span>\/Library\/Developer\/CommandLineTools\/usr\/bin\/python3 <span class=\"nt\">-m<\/span> pip <span class=\"nb\">install<\/span> <span class=\"nt\">--upgrade<\/span> pip<span class=\"s1\">' command.\r\n<\/span><\/code><\/pre>\n<h2>\u539f\u56e0<\/h2>\n<p>\u6b63\u76f4\u771f\u56e0\u306f\u308f\u304b\u3063\u3066\u3044\u306a\u3044\u3067\u3059\u304c\u3001\u3061\u3087\u3063\u3068\u8abf\u3079\u305f\u9650\u308a\u3001cryptography\u306e\u30d3\u30eb\u30c9\u306bRust compiler\u3092\u4f7f\u3046\u3051\u3069\u3001Rust compiler\u304c\u898b\u5f53\u305f\u3089\u306a\u3044\u305f\u3081\u51fa\u3066\u3044\u308b\u30a8\u30e9\u30fc\u3068\u60f3\u5b9a\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>error: can<span class=\"s1\">'t find Rust compiler\r\n\u30fb\u30fb\u30fb\uff08\u7701\u7565\uff09\r\nERROR: Failed building wheel for cryptography\r\n\u30fb\u30fb\u30fb\uff08\u7701\u7565\uff09\r\nERROR: Could not build wheels for cryptography which use PEP 517 and cannot be installed directly\r\n<\/span><\/code><\/pre>\n<h2>\u3084\u3063\u305f\u3053\u3068<\/h2>\n<p>stackoverflow\u3092\u898b\u305f\u3089\u3001Rust compiler\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b\u304b\u3001pip\u3092\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3059\u308b\u304b\u3092\u691c\u8a0e\u3057\u3066\u307f\u3066\u3002<\/p>\n<p>\u3068\u66f8\u3044\u3066\u3042\u3063\u305f\u3057\u3001\u30a8\u30e9\u30fc\u5185\u5bb9\u306e\u6700\u5f8c\u306b\u3054\u4e01\u5be7\u306bpip\u306e\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3092\u691c\u8a0e\u3057\u3066\u304f\u3060\u3055\u3044\u3068\u66f8\u3044\u3066\u304f\u308c\u3066\u3044\u305f\u306e\u3067\u3001\u307e\u305a\u306f\u7c21\u5358\u305d\u3046\u306apip\u3092\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<pre class=\"post-pre\"><code>% pip3 <span class=\"nb\">install<\/span> <span class=\"nt\">--upgrade<\/span> pip\r\nDefaulting to user installation because normal site-packages is not writeable\r\nCollecting pip\r\n Downloading pip-21.3.1-py3-none-any.whl <span class=\"o\">(<\/span>1.7 MB<span class=\"o\">)<\/span>\r\n    |\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588| 1.7 MB 1.0 MB\/s \r\nInstalling collected packages: pip\r\n WARNING: The scripts pip, pip3 and pip3.8 are installed <span class=\"k\">in<\/span> <span class=\"s1\">'\/Users\/xxxx\/Library\/Python\/3.8\/bin'<\/span> which is not on PATH.\r\n Consider adding this directory to PATH or, <span class=\"k\">if <\/span>you prefer to suppress this warning, use <span class=\"nt\">--no-warn-script-location<\/span><span class=\"nb\">.<\/span>\r\nSuccessfully installed pip-21.3.1\r\n<\/code><\/pre>\n<p>\u306a\u3093\u304b\u307e\u3060WARNING\u51fa\u3066\u307e\u3059\u3051\u3069\u3001\u305d\u308c\u306f\u7f6e\u3044\u3066\u304a\u3044\u3066\u3001\u7121\u4e8bpip\u306e\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u304c\u5b8c\u4e86\u3057\u307e\u3057\u305f\uff01<\/p>\n<p>\u5ff5\u306e\u305f\u3081\u3001\u30d0\u30fc\u30b8\u30e7\u30f3\u78ba\u8a8d\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<pre class=\"post-pre\"><code>% pip3 <span class=\"nt\">-V<\/span>\r\npip 21.3.1 from \/opt\/homebrew\/lib\/python3.9\/site-packages\/pip <span class=\"o\">(<\/span>python 3.9<span class=\"o\">)<\/span>\r\n<\/code><\/pre>\n<p>\u6700\u521d\u306b\u5931\u6557\u3057\u305fselenium\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3092\u3084\u3063\u3066\u307f\u307e\u3059\uff01<\/p>\n<pre class=\"post-pre\"><code>% pip3 <span class=\"nb\">install <\/span>selenium     \r\nDefaulting to user installation because normal site-packages is not writeable\r\nCollecting selenium\r\n\u30fb\u30fb\u30fb\uff08\u7701\u7565\uff09\r\nInstalling collected packages: pycparser, cffi, attrs, sortedcontainers, sniffio, outcome, idna, h11, cryptography, async-generator, wsproto, urllib3, trio, pyOpenSSL, certifi, trio-websocket, selenium\r\nSuccessfully installed async-generator-1.10 attrs-21.4.0 certifi-2021.10.8 cffi-1.15.0 cryptography-36.0.1 h11-0.13.0 idna-3.3 outcome-1.1.0 pyOpenSSL-21.0.0 pycparser-2.21 selenium-4.1.0 sniffio-1.2.0 sortedcontainers-2.4.0 trio-0.19.0 trio-websocket-0.9.2 urllib3-1.26.8 wsproto-1.0.0\r\n<\/code><\/pre>\n<p>\u3059\u308b\u3068\u3001Successfully installed\u304c\u51fa\u305f\u306e\u3067\u6210\u529f\u3057\u307e\u3057\u305f\uff01\u3084\u3063\u305f\u301c?<\/p>\n<p>pip20.2.3\u304b\u308921.3.1\u306b\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3059\u308b\u306b\u3042\u305f\u3063\u3066\u3001Rust compiler\u304c\u542b\u307e\u308c\u308b\u3088\u3046\u306b\u306a\u3063\u305f\u3068\u3044\u3046\u3053\u3068\u306a\u3093\u3067\u3059\u304b\u306d?<\/p>\n<p>pip\u306eChangelog\u306b\u306f\u305d\u308c\u3089\u3057\u3044\u3082\u306e\u304c\u306a\u3044\u6c17\u304c\u3057\u307e\u3059\u304c\u30fb\u30fb<\/p>\n<p>&nbsp;<\/p>\n<p>\u306a\u3093\u306b\u305b\u3088\u3001\u76ee\u7684\u306f\u9054\u6210\u3067\u304d\u305f\u306e\u3067\u826f\u3057\u3068\u3057\u307e\u3059\uff01<\/p>\n<p>\u306a\u306b\u304b\u771f\u56e0\u304c\u308f\u304b\u308b\u65b9\u3044\u3089\u3063\u3057\u3083\u3044\u307e\u3057\u305f\u3089\u3001\u662f\u975e\u6559\u3048\u3066\u304f\u3060\u3055\u3044\u301c\uff01<\/p>\n<h2>\u4e0a\u8a18\u89e3\u6c7a\u3057\u307e\u3057\u305f\uff01<\/h2>\n<p>\u300cpip\u300d\u3067\u306f\u306a\u304f\u300ccryptography\u300d\u5074\u306e\u554f\u984c\u3067\u3001pip\u3092\u30a2\u30c3\u30d7\u30b0\u30ec\u30fc\u30c9\u3059\u308b\u3053\u3068\u3067\u300cRust\u3067\u30b3\u30f3\u30d1\u30a4\u30eb\u6e08\u307f\u300d\u306e\u300c\u30d1\u30c3\u30b1\u30fc\u30b8\uff08cryptography wheel\uff09\u300d\u3092\u53d6\u3063\u3066\u6765\u3066\u3044\u305f\u3001\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u306d\uff01<\/p>\n<p>&nbsp;<\/p>\n<p>\u4e0a\u8a18\u306e\u3010Installing cryptography fails with error: Can not find Rust compiler\u3011\u3088\u308a\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>macOS\u306bselenium\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3088\u3046\u3068\u3057\u305f\u3089\u4f55\u3084\u3089\u30a8\u30e9\u30fc\u304c\u51fa\u307e\u3057\u305f\u3002 \u7d50\u8ad6\u304b\u3089\u8a00\u3046\u3068pip\u30a2\u30c3\u30d7\u30b0 [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-45474","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>- Blog - Silicon Cloud<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:description\" content=\"macOS\u306bselenium\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3088\u3046\u3068\u3057\u305f\u3089\u4f55\u3084\u3089\u30a8\u30e9\u30fc\u304c\u51fa\u307e\u3057\u305f\u3002 \u7d50\u8ad6\u304b\u3089\u8a00\u3046\u3068pip\u30a2\u30c3\u30d7\u30b0 [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2023-10-24T10:05:53+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-04-29T19:33:57+00:00\" \/>\n<meta name=\"author\" content=\"\u6e05, \u626c\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u6e05, \u626c\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/\",\"name\":\"- Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\"},\"datePublished\":\"2023-10-24T10:05:53+00:00\",\"dateModified\":\"2024-04-29T19:33:57+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/\"]}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461\",\"name\":\"\u6e05, \u626c\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g\",\"caption\":\"\u6e05, \u626c\"},\"url\":\"https:\/\/www.silicloud.com\/zh\/blog\/author\/qingyang\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"- Blog - Silicon Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/","og_locale":"zh_CN","og_type":"article","og_description":"macOS\u306bselenium\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3088\u3046\u3068\u3057\u305f\u3089\u4f55\u3084\u3089\u30a8\u30e9\u30fc\u304c\u51fa\u307e\u3057\u305f\u3002 \u7d50\u8ad6\u304b\u3089\u8a00\u3046\u3068pip\u30a2\u30c3\u30d7\u30b0 [&hellip;]","og_url":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2023-10-24T10:05:53+00:00","article_modified_time":"2024-04-29T19:33:57+00:00","author":"\u6e05, \u626c","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"\u6e05, \u626c","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"2 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/","url":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/","name":"- Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website"},"datePublished":"2023-10-24T10:05:53+00:00","dateModified":"2024-04-29T19:33:57+00:00","author":{"@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/"]}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#website","url":"https:\/\/www.silicloud.com\/zh\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/cb5556d2501da73d864cac945e8d9461","name":"\u6e05, \u626c","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/32a4239de8ff29adace466261d309424a1e5fe9f7e3036bf89fe03f2e3dbe717?s=96&d=mm&r=g","caption":"\u6e05, \u626c"},"url":"https:\/\/www.silicloud.com\/zh\/blog\/author\/qingyang\/"},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.silicloud.com\/zh\/blog\/45474-2\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45474","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/comments?post=45474"}],"version-history":[{"count":2,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45474\/revisions"}],"predecessor-version":[{"id":89432,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/posts\/45474\/revisions\/89432"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/media?parent=45474"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/categories?post=45474"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/zh\/blog\/wp-json\/wp\/v2\/tags?post=45474"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}