{"id":64448,"date":"2026-01-23T15:40:28","date_gmt":"2026-01-23T07:40:28","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/64448.html"},"modified":"2026-01-23T15:40:28","modified_gmt":"2026-01-23T07:40:28","slug":"python%e7%b3%bb%e5%88%97bug%e4%bf%ae%e5%a4%8d%ef%bd%9c%e5%a6%82%e4%bd%95%e8%a7%a3%e5%86%b3-pip-install-%e5%ae%89%e8%a3%85%e6%8a%a5%e9%94%99-modulenotfounderror-no-module-named-loguru","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/64448.html","title":{"rendered":"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898"},"content":{"rendered":"<h2>\u6458\u8981<\/h2>\n<p>\u4f60\u5728\u4f7f\u7528pip\u5b89\u88c5\/\u8fd0\u884cloguru\u65f6\u9047\u5230ModuleNotFoundError: No module named &#039;loguru&#039;\u62a5\u9519&#xff0c;\u8be5\u95ee\u9898\u6838\u5fc3\u8bf1\u56e0\u662f\u73af\u5883\u4e00\u81f4\u6027\u95ee\u9898&#xff08;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff0c;\u5360\u6bd445%&#xff09;&#043; \u5b89\u88c5\u4e0d\u5b8c\u6574 &#043; \u6743\u9650\u4e0d\u8db3 &#043; \u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b &#043; Python\u7248\u672c\u4e0d\u517c\u5bb9 &#043; \u7f13\u5b58\u635f\u574f&#xff1a;loguru\u662fPython\u6781\u7b80\u4e14\u529f\u80fd\u5f3a\u5927\u7684\u65e5\u5fd7\u5e93&#xff08;\u65e0\u9700\u590d\u6742\u914d\u7f6e\u3001\u652f\u6301\u5f02\u6b65\/\u5f69\u8272\u8f93\u51fa\u3001\u6587\u4ef6\u8f6e\u8f6c&#xff09;&#xff0c;\u5176\u5b89\u88c5\u540d\u3001Python\u5bfc\u5165\u540d\u5b8c\u5168\u4e00\u81f4&#xff08;\u5747\u4e3a\u5168\u5c0f\u5199loguru&#xff09;&#xff0c;\u65e0\u4efb\u4f55\u547d\u540d\u6df7\u6dc6\u9677\u9631&#xff1b;loguru 0.7.x&#xff08;\u6700\u65b0\u7a33\u5b9a\u7248&#xff09;\u652f\u6301Python 3.7~3.13&#xff0c;0.6.x\u652f\u6301Python 3.6~3.11&#xff08;\u5df2\u505c\u6b62\u7ef4\u62a4&#xff09;&#xff0c;Python 3.6\u4ee5\u4e0b\/2.7\u5b8c\u5168\u4e0d\u652f\u6301&#xff1b;\u6743\u9650\u4e0d\u8db3\u3001\u7f51\u7edc\u6ce2\u52a8\u3001\u7f13\u5b58\u635f\u574f\u662f\u5bfc\u81f4\u5b89\u88c5\u5931\u8d25\u7684\u4e3b\u8981\u539f\u56e0&#xff0c;\u65b0\u624b\u56e0\u73af\u5883\u9519\u4f4d&#xff08;\u5982pip\u88c5\u5230Python3\u4f46\u7528Python2\u8c03\u7528&#xff09;\u662f\u89e6\u53d1\u62a5\u9519\u7684\u6700\u6838\u5fc3\u539f\u56e0\u3002\u672c\u6587\u4ece\u73af\u5883\u9002\u914d\u3001\u7248\u672c\u517c\u5bb9\u3001\u5b89\u88c5\u5b8c\u6574\u6027\u89d2\u5ea6\u62c6\u89e3\u62a5\u9519\u6839\u6e90&#xff0c;\u63d0\u4f9b\u5206\u573a\u666f\u89e3\u51b3\u65b9\u6848&#xff0c;\u5e2e\u52a9\u4f60\u5f7b\u5e95\u89e3\u51b3loguru\u6a21\u5757\u627e\u4e0d\u5230\u7684\u95ee\u9898\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/01\/20260123074025-697325e92c106.jpg\" alt=\"\" \/><\/p>\n<\/p>\n<h4>\u6587\u7ae0\u76ee\u5f55<\/h4>\n<ul>\n<li>\u6458\u8981<\/li>\n<li>\u4e00\u3001\u62a5\u9519\u6838\u5fc3\u8ba4\u77e5&#xff1a;\u6838\u5fc3\u662f\u300c\u73af\u5883\u4e00\u81f4&#043;\u7248\u672c\u517c\u5bb9&#043;\u5b89\u88c5\u5b8c\u6574\u300d<\/li>\n<li>\n<ul>\n<li>\u6838\u5fc3\u89c4\u5219<\/li>\n<li>1.1 \u5178\u578b\u62a5\u9519\u8f93\u51fa<\/li>\n<li>\n<ul>\n<li>\u573a\u666f1&#xff1a;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff08;\u6700\u5e38\u89c1&#xff0c;\u5360\u6bd445%&#xff09;<\/li>\n<li>\u573a\u666f2&#xff1a;\u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b\u5bfc\u81f4\u73af\u5883\u9519\u4f4d<\/li>\n<li>\u573a\u666f3&#xff1a;Python\u7248\u672c\u8fc7\u4f4e\u5bfc\u81f4\u5b89\u88c5\/\u8fd0\u884c\u5931\u8d25<\/li>\n<li>\u573a\u666f4&#xff1a;\u6743\u9650\u4e0d\u8db3\u5bfc\u81f4\u5b89\u88c5\u5931\u8d25<\/li>\n<li>\u573a\u666f5&#xff1a;\u5b89\u88c5\u4e0d\u5b8c\u6574\/\u7f13\u5b58\u635f\u574f<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\u4e8c\u3001\u62a5\u9519\u6839\u6e90\u62c6\u89e3&#xff1a;5\u5927\u7c7b\u6838\u5fc3\u8bf1\u56e0<\/li>\n<li>\n<ul>\n<li>2.1 \u6838\u5fc3\u8bf1\u56e01&#xff1a;\u73af\u5883\/\u7248\u672c\u9519\u4f4d&#xff08;\u5360\u6bd445%&#xff09;<\/li>\n<li>2.2 \u6838\u5fc3\u8bf1\u56e02&#xff1a;\u5b89\u88c5\u4e0d\u5b8c\u6574\/\u7f13\u5b58\u635f\u574f&#xff08;\u5360\u6bd420%&#xff09;<\/li>\n<li>2.3 \u6838\u5fc3\u8bf1\u56e03&#xff1a;\u6743\u9650\u4e0d\u8db3&#xff08;\u5360\u6bd415%&#xff09;<\/li>\n<li>2.4 \u6838\u5fc3\u8bf1\u56e04&#xff1a;Python\u7248\u672c\u4e0d\u517c\u5bb9&#xff08;\u5360\u6bd415%&#xff09;<\/li>\n<li>2.5 \u6838\u5fc3\u8bf1\u56e05&#xff1a;\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u65ad&#xff08;\u5360\u6bd45%&#xff09;<\/li>\n<\/ul>\n<\/li>\n<li>\u4e09\u3001\u7cfb\u7edf\u5316\u89e3\u51b3\u6b65\u9aa4&#xff1a;\u5206\u573a\u666f\u9002\u914d<\/li>\n<li>\n<ul>\n<li>3.1 \u524d\u7f6e\u9a8c\u8bc1&#xff1a;5\u5206\u949f\u5feb\u901f\u5b9a\u4f4d\u6839\u6e90<\/li>\n<li>3.2 \u65b9\u68481&#xff1a;\u6838\u5fc3\u4fee\u590d\u2014\u2014\u901a\u7528\u5b89\u88c5&#xff08;\u786e\u4fdd\u73af\u5883\u4e00\u81f4&#xff09;<\/li>\n<li>3.3 \u65b9\u68482&#xff1a;\u7248\u672c\u9002\u914d&#xff08;\u5339\u914dPython\/loguru\u7248\u672c&#xff09;<\/li>\n<li>3.4 \u65b9\u68483&#xff1a;\u865a\u62df\u73af\u5883\u4fee\u590d&#xff08;\u8865\u88c5\u7f3a\u5931\u7684loguru&#xff09;<\/li>\n<li>3.5 \u65b9\u68484&#xff1a;\u6743\u9650\u9002\u914d\u2014\u2014\u65e0\u7ba1\u7406\u5458\u6743\u9650\u5b89\u88c5<\/li>\n<li>3.6 \u65b9\u68485&#xff1a;\u4fee\u590d\u65b9\u6848\u2014\u2014\u91cd\u88c5loguru&#xff08;\u7f13\u5b58\u635f\u574f\/\u5b89\u88c5\u4e0d\u5b8c\u6574&#xff09;<\/li>\n<li>3.7 \u65b9\u68486&#xff1a;\u79bb\u7ebf\u5b89\u88c5&#xff08;\u65e0\u7f51\u7edc\/\u5185\u7f51\u73af\u5883&#xff09;<\/li>\n<li>3.8 \u65b9\u68487&#xff1a;PyCharm\u73af\u5883\u9002\u914d<\/li>\n<li>\n<ul>\n<li>\u5b50\u573a\u666f1&#xff1a;PyCharm\u4e2d\u8fd0\u884cloguru\u62a5\u9519\u7f3a\u5931\u6a21\u5757<\/li>\n<li>\u5b50\u573a\u666f2&#xff1a;PyCharm\u865a\u62df\u73af\u5883\u4e2d\u8bc6\u522b\u4e0d\u5230loguru<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\u56db\u3001\u6392\u969c\u6280\u5de7&#xff1a;\u4fee\u590d\u540e\u4ecd\u63d0\u793a\u6a21\u5757\u627e\u4e0d\u5230<\/li>\n<li>\n<ul>\n<li>4.1 \u5b89\u88c5loguru\u540e\u4ecd\u62a5ModuleNotFoundError: No module named \u2018loguru\u2019<\/li>\n<li>\n<ul>\n<li>\u539f\u56e0&#xff1a;<\/li>\n<li>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/li>\n<\/ul>\n<\/li>\n<li>4.2 Linux\/macOS\u62a5\u201cPermission denied\u201d\u5b89\u88c5\u5931\u8d25<\/li>\n<li>\n<ul>\n<li>\u539f\u56e0&#xff1a;<\/li>\n<li>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/li>\n<\/ul>\n<\/li>\n<li>4.3 \u7f51\u7edc\u95ee\u9898\u5bfc\u81f4\u65e0\u6cd5\u4e0b\u8f7dloguru<\/li>\n<li>\n<ul>\n<li>\u539f\u56e0&#xff1a;<\/li>\n<li>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/li>\n<\/ul>\n<\/li>\n<li>4.4 Conda\u73af\u5883\u4e2d\u5bfc\u5165loguru\u5931\u8d25<\/li>\n<li>\n<ul>\n<li>\u539f\u56e0&#xff1a;<\/li>\n<li>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\u4e94\u3001\u9884\u9632\u63aa\u65bd&#xff1a;\u907f\u514dModuleNotFoundError\u590d\u53d1<\/li>\n<li>\n<ul>\n<li>5.1 \u4e2a\u4eba\u5f00\u53d1\u73af\u5883<\/li>\n<li>5.2 \u56e2\u961f\u5f00\u53d1\u73af\u5883<\/li>\n<\/ul>\n<\/li>\n<li>\u516d\u3001\u603b\u7ed3<\/li>\n<li>\n<ul>\n<li>\n<ul>\n<li>\u5173\u952e\u70b9\u56de\u987e<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>\u4e00\u3001\u62a5\u9519\u6838\u5fc3\u8ba4\u77e5&#xff1a;\u6838\u5fc3\u662f\u300c\u73af\u5883\u4e00\u81f4&#043;\u7248\u672c\u517c\u5bb9&#043;\u5b89\u88c5\u5b8c\u6574\u300d<\/h2>\n<p>ModuleNotFoundError: No module named &#039;loguru&#039;\u662floguru\u4f7f\u7528\u7684\u9ad8\u9891\u5165\u95e8\u62a5\u9519&#xff0c;\u6838\u5fc3\u7279\u5f81\u662f&#xff1a;<\/p>\n<ul>\n<li>\u65e0\u547d\u540d\u9677\u9631&#xff1a;loguru\u7684\u5b89\u88c5\u540d&#xff08;pip install loguru&#xff09;\u3001Python\u5bfc\u5165\u540d&#xff08;import loguru&#xff09;\u5b8c\u5168\u4e00\u81f4&#xff08;\u5168\u5c0f\u5199&#xff09;&#xff0c;\u65e0\u9700\u7ea0\u7ed3\u547d\u540d\u5dee\u5f02&#xff1b;<\/li>\n<li>\u7248\u672c\u517c\u5bb9\u6838\u5fc3\u89c4\u5219&#xff1a;\n<ul>\n<li>loguru 0.7.x&#xff08;\u59820.7.2&#xff0c;\u4e3b\u6d41\u7a33\u5b9a\u7248&#xff09;&#xff1a;\u652f\u6301Python 3.7~3.13&#xff0c;\u65b0\u589e\u5f02\u6b65\u65e5\u5fd7\u4f18\u5316\u3001Python 3.13\u517c\u5bb9&#xff1b;<\/li>\n<li>loguru 0.6.x&#xff08;\u59820.6.0&#xff09;&#xff1a;\u4ec5\u652f\u6301Python 3.6~3.11&#xff08;\u5df2\u505c\u6b62\u7ef4\u62a4&#xff0c;\u65e0\u5b89\u5168\u66f4\u65b0&#xff09;&#xff1b;<\/li>\n<li>loguru \u22640.5.x&#xff1a;\u652f\u6301Python 3.5~3.10&#xff08;\u5b8c\u5168\u6dd8\u6c70&#xff0c;\u4e0d\u63a8\u8350&#xff09;&#xff1b;<\/li>\n<li>\u65e0Python 2.7\u652f\u6301&#xff1a;loguru\u4ece\u8bbe\u8ba1\u4e4b\u521d\u5c31\u653e\u5f03\u4e86Python 2\u517c\u5bb9&#xff1b;<\/li>\n<\/ul>\n<\/li>\n<li>\u4f9d\u8d56\u7279\u6027&#xff1a;\u7eafPython\u5e93&#xff0c;\u65e0\u4efb\u4f55\u5f3a\u5236\u6838\u5fc3\u4f9d\u8d56&#xff08;\u53ef\u9009\u4f9d\u8d56\u4ec5colorama&#xff08;Windows\u5f69\u8272\u8f93\u51fa&#xff09;\u3001win32-setctime&#xff08;Windows\u6587\u4ef6\u65f6\u95f4\u4fee\u6b63&#xff09;&#xff09;&#xff0c;\u5b89\u88c5\u5931\u8d25\u51e0\u4e4e\u90fd\u662f\u73af\u5883\u3001\u6743\u9650\u3001\u7f51\u7edc\u95ee\u9898\u5bfc\u81f4&#xff0c;\u65e0\u590d\u6742\u4f9d\u8d56\u51b2\u7a81&#xff1b;<\/li>\n<li>\u6613\u6df7\u6dc6\u70b9&#xff1a;\u65e0\u7c7b\u4f3c\u547d\u540d\u7684\u66ff\u4ee3\u5305&#xff0c;\u62a5\u9519\u4ec5\u6e90\u4e8e\u201c\u672a\u88c5\u5230\u5f53\u524d\u73af\u5883\u201d\u6216\u201c\u7248\u672c\u4e0d\u517c\u5bb9\u201d\u3002<\/li>\n<\/ul>\n<h3>\u6838\u5fc3\u89c4\u5219<\/h3>\n<table>\n<tr>\u573a\u666f\/\u9700\u6c42\u64cd\u4f5c\u65b9\u5f0f\u6838\u5fc3\u7279\u70b9<\/tr>\n<tbody>\n<tr>\n<td>\u901a\u7528\u5b89\u88c5&#xff08;\u63a8\u8350&#xff09;<\/td>\n<td>python -m pip install loguru<\/td>\n<td>\u786e\u4fddpip\u4e0e\u5f53\u524dPython\u7248\u672c\u5339\u914d<\/td>\n<\/tr>\n<tr>\n<td>\u7248\u672c\u9002\u914d&#xff08;Python 3.7&#043;&#xff09;<\/td>\n<td>python -m pip install loguru&gt;&#061;0.7.0<\/td>\n<td>\u5339\u914d\u65b0\u7248Python&#xff0c;\u529f\u80fd\u6700\u5168<\/td>\n<\/tr>\n<tr>\n<td>\u7248\u672c\u9002\u914d&#xff08;Python 3.6&#xff09;<\/td>\n<td>python -m pip install loguru&#061;&#061;0.6.0<\/td>\n<td>\u517c\u5bb9Python 3.6<\/td>\n<\/tr>\n<tr>\n<td>\u6743\u9650\u4e0d\u8db3\u5b89\u88c5<\/td>\n<td>python -m pip install loguru &#8211;user<\/td>\n<td>\u5b89\u88c5\u5230\u7528\u6237\u76ee\u5f55&#xff0c;\u907f\u514d\u6743\u9650\u62a5\u9519<\/td>\n<\/tr>\n<tr>\n<td>\u865a\u62df\u73af\u5883\u4fee\u590d<\/td>\n<td>\u6fc0\u6d3b\u865a\u62df\u73af\u5883\u540e\u6267\u884cpython -m pip install loguru<\/td>\n<td>\u8865\u88c5\u865a\u62df\u73af\u5883\u7684loguru<\/td>\n<\/tr>\n<tr>\n<td>\u9a8c\u8bc1\u5b89\u88c5<\/td>\n<td>python -c &#034;import loguru&#034;<\/td>\n<td>\u76f4\u63a5\u9a8c\u8bc1\u6a21\u5757\u662f\u5426\u53ef\u7528<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<table>\n<tr>loguru\u7248\u672c\u652f\u6301Python\u7248\u672c\u6838\u5fc3\u8bf4\u660e<\/tr>\n<tbody>\n<tr>\n<td>0.7.x<\/td>\n<td>3.7 ~ 3.13<\/td>\n<td>\u4e3b\u6d41\u7a33\u5b9a\u7248&#xff0c;\u652f\u6301\u5f02\u6b65\u65e5\u5fd7\u4f18\u5316<\/td>\n<\/tr>\n<tr>\n<td>0.6.x<\/td>\n<td>3.6 ~ 3.11<\/td>\n<td>\u4ec5\u9002\u914d\u8001\u65e7Python&#xff0c;\u65e0\u7ef4\u62a4<\/td>\n<\/tr>\n<tr>\n<td>\u22640.5.x<\/td>\n<td>3.5 ~ 3.10<\/td>\n<td>\u6dd8\u6c70\u7248\u672c&#xff0c;\u65e0\u5b89\u5168\u66f4\u65b0<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<ul>\n<li>\u62a5\u9519\u672c\u8d28&#xff1a;\u8981\u4e48\u662floguru\u672a\u5b89\u88c5\u5230\u5f53\u524d\u8fd0\u884c\u7684Python\u73af\u5883&#xff0c;\u8981\u4e48\u662f\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u65ad\u5bfc\u81f4\u6587\u4ef6\u7f3a\u5931&#xff0c;\u8981\u4e48\u662fPython\u7248\u672c\u4e0eloguru\u7248\u672c\u4e0d\u517c\u5bb9&#xff1b;<\/li>\n<li>\u6838\u5fc3\u7279\u5f81&#xff1a;\u6267\u884cpip install loguru\u63d0\u793a\u6210\u529f&#xff0c;\u4f46import loguru\/from loguru import logger\u8fd0\u884c\u65f6\u89e6\u53d1\u62a5\u9519&#xff1b;<\/li>\n<li>\u62a5\u9519\u89e6\u53d1\u903b\u8f91&#xff08;\u65b0\u624b\u5178\u578b\u64cd\u4f5c&#xff09;&#xff1a; \u7528pip3 install loguru\u5b89\u88c5&#xff08;\u7ed1\u5b9aPython 3.10&#xff09;\u2192 \u7528python&#xff08;\u7ed1\u5b9aPython 2.7&#xff09;\u6267\u884cimport loguru \u2192 \u629b\u51faModuleNotFoundError&#xff1b; \u6216Python 3.6\u5b89\u88c5loguru 0.7.2 \u2192 \u5b89\u88c5\u5931\u8d25\/\u8fd0\u884c\u62a5\u9519&#xff1b; \u6216\u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b&#xff0c;loguru\u88c5\u5230\u7cfb\u7edfPython\u5374\u5728\u865a\u62df\u73af\u5883\u4e2d\u8fd0\u884c \u2192 \u629b\u51faModuleNotFoundError\u3002<\/li>\n<\/ul>\n<h3>1.1 \u5178\u578b\u62a5\u9519\u8f93\u51fa<\/h3>\n<h4>\u573a\u666f1&#xff1a;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff08;\u6700\u5e38\u89c1&#xff0c;\u5360\u6bd445%&#xff09;<\/h4>\n<p><span class=\"token comment\"># \u7528pip3\u5b89\u88c5loguru&#xff08;\u7ed1\u5b9aPython 3.10&#xff09;<\/span><br \/>\npip3 <span class=\"token function\">install<\/span> loguru<br \/>\n<span class=\"token comment\"># \u8f93\u51fa&#xff1a;Successfully installed loguru-0.7.2<\/span><\/p>\n<p><span class=\"token comment\"># \u7528python&#xff08;\u7ed1\u5b9aPython 2.7&#xff09;\u9a8c\u8bc1\u5bfc\u5165<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru&#034;<\/span><\/p>\n<p><span class=\"token comment\"># \u6838\u5fc3\u62a5\u9519<\/span><br \/>\nModuleNotFoundError: No module named <span class=\"token string\">&#039;loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u672c\u8d28&#xff1a;pip3\u88c5\u5230Python3&#xff0c;python\u8c03\u7528Python2&#xff0c;\u73af\u5883\u4e0d\u5339\u914d<\/span><\/p>\n<h4>\u573a\u666f2&#xff1a;\u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b\u5bfc\u81f4\u73af\u5883\u9519\u4f4d<\/h4>\n<p><span class=\"token comment\"># \u521b\u5efa\u865a\u62df\u73af\u5883\u4f46\u672a\u6fc0\u6d3b&#xff0c;\u5b89\u88c5\u5230\u7cfb\u7edfPython<\/span><br \/>\npython -m venv loguru_env<br \/>\npip <span class=\"token function\">install<\/span> loguru  <span class=\"token comment\"># \u88c5\u5230\u7cfb\u7edfPython<\/span><\/p>\n<p><span class=\"token comment\"># \u6fc0\u6d3b\u865a\u62df\u73af\u5883\u540e\u9a8c\u8bc1\u5bfc\u5165<\/span><br \/>\n<span class=\"token builtin class-name\">source<\/span> loguru_env\/bin\/activate  <span class=\"token comment\"># Linux\/macOS<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru&#034;<\/span><\/p>\n<p><span class=\"token comment\"># \u6838\u5fc3\u62a5\u9519<\/span><br \/>\nModuleNotFoundError: No module named <span class=\"token string\">&#039;loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u672c\u8d28&#xff1a;\u865a\u62df\u73af\u5883\u4e2d\u672a\u5b89\u88c5loguru&#xff0c;\u4ec5\u7cfb\u7edfPython\u6709<\/span><\/p>\n<h4>\u573a\u666f3&#xff1a;Python\u7248\u672c\u8fc7\u4f4e\u5bfc\u81f4\u5b89\u88c5\/\u8fd0\u884c\u5931\u8d25<\/h4>\n<p><span class=\"token comment\"># Python 3.6\u73af\u5883\u5b89\u88c5loguru 0.7.2&#xff08;\u4e0d\u517c\u5bb9&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru<span class=\"token operator\">&gt;&#061;<\/span><span class=\"token number\">0.7<\/span>.0<br \/>\n<span class=\"token comment\"># \u8f93\u51fa&#xff1a;ERROR: Could not find a version that satisfies the requirement loguru&gt;&#061;0.7.0<\/span><br \/>\n<span class=\"token comment\"># \u6216\u5b89\u88c5\u540e\u8fd0\u884c\u62a5\u9519<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru&#034;<\/span><br \/>\nModuleNotFoundError: No module named <span class=\"token string\">&#039;loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u672c\u8d28&#xff1a;loguru 0.7&#043;\u4e0d\u652f\u6301Python 3.6<\/span><\/p>\n<h4>\u573a\u666f4&#xff1a;\u6743\u9650\u4e0d\u8db3\u5bfc\u81f4\u5b89\u88c5\u5931\u8d25<\/h4>\n<p><span class=\"token comment\"># Linux\/macOS\u65e0\u7ba1\u7406\u5458\u6743\u9650\u5168\u5c40\u5b89\u88c5<\/span><br \/>\npip <span class=\"token function\">install<\/span> loguru<\/p>\n<p><span class=\"token comment\"># \u6838\u5fc3\u9519\u8bef\u8f93\u51fa&#xff1a;<\/span><br \/>\nERROR: Could not <span class=\"token function\">install<\/span> packages due to an OSError: <span class=\"token punctuation\">[<\/span>Errno <span class=\"token number\">13<\/span><span class=\"token punctuation\">]<\/span> Permission denied: <span class=\"token string\">&#039;\/usr\/lib\/python3.10\/site-packages\/loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u8fd0\u884c\u65f6\u62a5\u9519<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru&#034;<\/span><br \/>\nModuleNotFoundError: No module named <span class=\"token string\">&#039;loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u672c\u8d28&#xff1a;\u65e0\u6743\u9650\u5199\u5165\u7cfb\u7edfPython\u76ee\u5f55&#xff0c;loguru\u672a\u6210\u529f\u5b89\u88c5<\/span><\/p>\n<h4>\u573a\u666f5&#xff1a;\u5b89\u88c5\u4e0d\u5b8c\u6574\/\u7f13\u5b58\u635f\u574f<\/h4>\n<p><span class=\"token comment\"># \u7f51\u7edc\u4e2d\u65ad\u5bfc\u81f4\u5b89\u88c5\u4e0d\u5b8c\u6574<\/span><br \/>\npip <span class=\"token function\">install<\/span> loguru<br \/>\n<span class=\"token comment\"># \u8f93\u51fa&#xff1a;WARNING: Failed to unpack loguru-0.7.2-py3-none-any.whl<\/span><br \/>\n<span class=\"token comment\"># \u8fd0\u884c\u65f6\u62a5\u9519<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru&#034;<\/span><br \/>\nModuleNotFoundError: No module named <span class=\"token string\">&#039;loguru&#039;<\/span><br \/>\n<span class=\"token comment\"># \u672c\u8d28&#xff1a;loguru\u6587\u4ef6\u672a\u5b8c\u6574\u89e3\u538b&#xff0c;\u6838\u5fc3\u6a21\u5757\u7f3a\u5931<\/span><\/p>\n<h2>\u4e8c\u3001\u62a5\u9519\u6839\u6e90\u62c6\u89e3&#xff1a;5\u5927\u7c7b\u6838\u5fc3\u8bf1\u56e0<\/h2>\n<p>\u8be5\u95ee\u9898\u7684\u5e95\u5c42\u903b\u8f91\u662f&#xff1a;\u8fd0\u884c\u4ee3\u7801\u65f6&#xff0c;\u5f53\u524dPython\u73af\u5883\u627e\u4e0d\u5230loguru\u6a21\u5757 \u2192 \u8981\u4e48\u662f\u6a21\u5757\u672a\u5b89\u88c5\/\u5b89\u88c5\u4e0d\u5b8c\u6574&#xff0c;\u8981\u4e48\u662f\u73af\u5883\/\u7248\u672c\u4e0d\u517c\u5bb9&#xff0c;\u8981\u4e48\u662f\u6743\u9650\u5bfc\u81f4\u5b89\u88c5\u5931\u8d25 \u2192 \u629b\u51faModuleNotFoundError\u3002\u6838\u5fc3\u8bf1\u56e0\u5206\u4e3a5\u7c7b&#xff1a;<\/p>\n<h3>2.1 \u6838\u5fc3\u8bf1\u56e01&#xff1a;\u73af\u5883\/\u7248\u672c\u9519\u4f4d&#xff08;\u5360\u6bd445%&#xff09;<\/h3>\n<ul>\n<li>pip\u4e0epython\u7248\u672c\u4e0d\u5339\u914d&#xff1a;\u5982pip\u7ed1\u5b9aPython 2&#xff08;\u5df2\u6dd8\u6c70&#xff09;\u3001pip3\u88c5\u5230Python 3.8\u4f46python3.10\u8c03\u7528&#xff1b;<\/li>\n<li>\u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b&#xff1a;loguru\u88c5\u5230\u7cfb\u7edfPython&#xff0c;\u4f46\u5728\u865a\u62df\u73af\u5883\u4e2d\u8fd0\u884c\u4ee3\u7801&#xff1b;<\/li>\n<li>Conda\u73af\u5883\u4e0e\u7cfb\u7edfPython\u51b2\u7a81&#xff1a;Anaconda\u7684Python\u8986\u76d6\u7cfb\u7edf\u8def\u5f84&#xff0c;\u5bfc\u81f4loguru\u6a21\u5757\u65e0\u6cd5\u8bc6\u522b&#xff1b;<\/li>\n<li>\u8bef\u5c06python\/pip\u6307\u5411\u4e0d\u540c\u865a\u62df\u73af\u5883&#xff08;\u5982\u540c\u65f6\u6709\u591a\u4e2avenv&#xff09;\u3002<\/li>\n<\/ul>\n<h3>2.2 \u6838\u5fc3\u8bf1\u56e02&#xff1a;\u5b89\u88c5\u4e0d\u5b8c\u6574\/\u7f13\u5b58\u635f\u574f&#xff08;\u5360\u6bd420%&#xff09;<\/h3>\n<ul>\n<li>\u7f51\u7edc\u6ce2\u52a8&#xff1a;PyPI\u6e90\u8d85\u65f6\/\u4e2d\u65ad&#xff0c;\u5bfc\u81f4loguru\u5305\u672a\u5b8c\u6574\u4e0b\u8f7d\/\u89e3\u538b&#xff1b;<\/li>\n<li>\u6740\u6bd2\u8f6f\u4ef6\u62e6\u622a&#xff1a;Windows Defender\u8bef\u5224loguru\u6838\u5fc3\u6587\u4ef6\u4e3a\u98ce\u9669\u6587\u4ef6&#xff0c;\u5220\u9664\u5173\u952e\u6a21\u5757&#xff1b;<\/li>\n<li>\u78c1\u76d8\u7a7a\u95f4\u4e0d\u8db3&#xff1a;\u5b89\u88c5\u8def\u5f84\u78c1\u76d8\u6ee1&#xff0c;\u5bfc\u81f4loguru\u76ee\u5f55\u672a\u5b8c\u6574\u89e3\u538b&#xff1b;<\/li>\n<li>pip\u7f13\u5b58\u635f\u574f&#xff1a;\u7f13\u5b58\u7684loguru\u5305\u6587\u4ef6\u635f\u574f&#xff0c;\u5b89\u88c5\u540e\u6838\u5fc3\u6a21\u5757&#xff08;\u5982loguru\/_logger.py&#xff09;\u7f3a\u5931\u3002<\/li>\n<\/ul>\n<h3>2.3 \u6838\u5fc3\u8bf1\u56e03&#xff1a;\u6743\u9650\u4e0d\u8db3&#xff08;\u5360\u6bd415%&#xff09;<\/h3>\n<ul>\n<li>Linux\/macOS\u65e0\u5168\u5c40\u5b89\u88c5\u6743\u9650&#xff0c;\u65e0\u6cd5\u5199\u5165\/usr\/lib\/pythonX\/site-packages&#xff1b;<\/li>\n<li>Windows\u65e0\u7ba1\u7406\u5458\u6743\u9650&#xff0c;\u65e0\u6cd5\u5199\u5165C:\\\\PythonX\\\\Lib\\\\site-packages&#xff1b;<\/li>\n<li>\u5b89\u88c5\u8def\u5f84\u88ab\u8bbe\u7f6e\u4e3a\u53ea\u8bfb&#xff0c;\u65e0\u6cd5\u5199\u5165loguru\u76f8\u5173\u6587\u4ef6\u3002<\/li>\n<\/ul>\n<h3>2.4 \u6838\u5fc3\u8bf1\u56e04&#xff1a;Python\u7248\u672c\u4e0d\u517c\u5bb9&#xff08;\u5360\u6bd415%&#xff09;<\/h3>\n<ul>\n<li>Python 3.6\u5b89\u88c5loguru 0.7.0&#043;&#xff1a;\u65b0\u7248loguru\u653e\u5f03\u5bf93.6\u7684\u652f\u6301&#xff1b;<\/li>\n<li>Python 3.5\u5b89\u88c5loguru 0.6.0&#043;&#xff1a;\u65e7Python\u4e0d\u6ee1\u8db3\u65b0\u7248\u7684\u8bed\u6cd5\u8981\u6c42&#xff1b;<\/li>\n<li>Python 2.7\u5b89\u88c5\u4efb\u610f\u7248\u672cloguru&#xff1a;loguru\u5b8c\u5168\u4e0d\u652f\u6301Python 2\u3002<\/li>\n<\/ul>\n<h3>2.5 \u6838\u5fc3\u8bf1\u56e05&#xff1a;\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u65ad&#xff08;\u5360\u6bd45%&#xff09;<\/h3>\n<ul>\n<li>\u5b89\u88c5\u65f6\u624b\u52a8\u5f3a\u5236\u4e2d\u65ad&#xff08;\u5982Ctrl&#043;C&#xff09;&#xff0c;\u5bfc\u81f4loguru\u76ee\u5f55\u672a\u5b8c\u6574\u521b\u5efa&#xff1b;<\/li>\n<li>\u591a\u6b21\u91cd\u590d\u5b89\u88c5\/\u5378\u8f7d&#xff0c;\u5bfc\u81f4pip\u7f13\u5b58\u6df7\u4e71&#xff0c;\u65e0\u6cd5\u6b63\u786e\u89e3\u6790\u5b89\u88c5\u8def\u5f84\u3002<\/li>\n<\/ul>\n<h2>\u4e09\u3001\u7cfb\u7edf\u5316\u89e3\u51b3\u6b65\u9aa4&#xff1a;\u5206\u573a\u666f\u9002\u914d<\/h2>\n<p>\u89e3\u51b3\u8be5\u95ee\u9898\u7684\u6838\u5fc3\u903b\u8f91\u662f&#xff1a;\u786e\u4fddpip\u4e0epython\u7248\u672c\u4e00\u81f4 &#043; \u9002\u914dPython\/loguru\u7248\u672c &#043; \u5b8c\u6574\u5b89\u88c5loguru\u4e3b\u5305 &#043; \u6fc0\u6d3b\u5bf9\u5e94\u73af\u5883&#xff0c;\u4f18\u5148\u7ea7&#xff1a;\u901a\u7528\u5b89\u88c5 &gt; \u865a\u62df\u73af\u5883\u4fee\u590d &gt; \u7248\u672c\u9002\u914d &gt; \u6743\u9650\u9002\u914d\u3002<\/p>\n<h3>3.1 \u524d\u7f6e\u9a8c\u8bc1&#xff1a;5\u5206\u949f\u5feb\u901f\u5b9a\u4f4d\u6839\u6e90<\/h3>\n<p><span class=\"token comment\"># 1. \u9a8c\u8bc1\u5f53\u524d\u8fd0\u884c\u7684Python\u7248\u672c&#xff08;\u5173\u952e&#xff1a;\u5339\u914dloguru\u7248\u672c&#xff09;<\/span><br \/>\npython &#8211;version<br \/>\n<span class=\"token comment\"># \u793a\u4f8b\u8f93\u51fa&#xff1a;Python 3.10.11 \u2192 \u9002\u914dloguru 0.7&#043;&#xff1b;Python 3.6.15 \u2192 \u4ec5\u9002\u914d0.6.0<\/span><\/p>\n<p><span class=\"token comment\"># 2. \u9a8c\u8bc1pip\u5bf9\u5e94\u7684Python\u7248\u672c<\/span><br \/>\npip &#8211;version<br \/>\n<span class=\"token comment\"># \u8f93\u51fa\u793a\u4f8b&#xff1a;pip 24.0 from &#8230;\/python3.10\/site-packages\/pip \u2192 \u5339\u914d\u5219\u6b63\u5e38<\/span><\/p>\n<p><span class=\"token comment\"># 3. \u9a8c\u8bc1\u662f\u5426\u5b89\u88c5\u4e86loguru\u4e3b\u5305<\/span><br \/>\npython -m pip show loguru<br \/>\n<span class=\"token comment\"># \u82e5\u8f93\u51fa\u201cWARNING: Package(s) not found: loguru\u201d \u2192 \u672a\u5b89\u88c5<\/span><\/p>\n<p><span class=\"token comment\"># 4. \u68c0\u67e5\u865a\u62df\u73af\u5883\u72b6\u6001<\/span><br \/>\n<span class=\"token comment\"># Linux\/macOS<\/span><br \/>\n<span class=\"token builtin class-name\">echo<\/span> <span class=\"token variable\">$VIRTUAL_ENV<\/span>  <span class=\"token comment\"># \u6709\u8f93\u51fa\u5219\u6fc0\u6d3b\u4e86\u865a\u62df\u73af\u5883<\/span><br \/>\n<span class=\"token comment\"># Windows&#xff08;PowerShell&#xff09;<\/span><br \/>\n<span class=\"token variable\">$env<\/span>:VIRTUAL_ENV<\/p>\n<p><span class=\"token comment\"># 5. \u5c1d\u8bd5\u76f4\u63a5\u9a8c\u8bc1\u6a21\u5757<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru; print(&#039;loguru\u7248\u672c&#xff1a;&#039;, loguru.__version__)&#034;<\/span><\/p>\n<h3>3.2 \u65b9\u68481&#xff1a;\u6838\u5fc3\u4fee\u590d\u2014\u2014\u901a\u7528\u5b89\u88c5&#xff08;\u786e\u4fdd\u73af\u5883\u4e00\u81f4&#xff09;<\/h3>\n<p>\u8fd9\u662f\u89e3\u51b3\u8be5\u62a5\u9519\u7684\u6700\u6838\u5fc3\u65b9\u6848&#xff0c;\u7528python -m pip\u5f3a\u5236\u7ed1\u5b9a\u5f53\u524dPython\u7248\u672c&#xff0c;\u5b8c\u6574\u5b89\u88c5loguru&#xff08;\u81ea\u52a8\u9002\u914d\u7248\u672c&#xff0c;3.7&#043;\u88c50.7.x&#xff0c;3.6\u88c50.6.0&#xff09;&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u8de8\u5e73\u53f0\u901a\u7528\u547d\u4ee4&#xff1a;\u7ed1\u5b9a\u5f53\u524dPython\u7248\u672c\u5b89\u88c5loguru &#043; \u56fd\u5185\u6e90\u52a0\u901f<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u9488\u5bf9Windows\u73af\u5883&#xff0c;\u989d\u5916\u5b89\u88c5\u53ef\u9009\u4f9d\u8d56&#xff08;\u5f69\u8272\u8f93\u51fa&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru colorama -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u9a8c\u8bc1\u5b89\u88c5&#xff08;\u53cc\u91cd\u9a8c\u8bc1&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 1. \u6a21\u5757\u5bfc\u5165\u9a8c\u8bc1<\/span><br \/>\npython -c <span class=\"token string\">&#034;<br \/>\nimport loguru<br \/>\nprint(&#039;loguru\u5bfc\u5165\u6210\u529f&#xff0c;\u7248\u672c&#xff1a;&#039;, loguru.__version__)<br \/>\n&#034;<\/span><br \/>\n<span class=\"token comment\"># \u8f93\u51fa&#xff1a;loguru\u5bfc\u5165\u6210\u529f&#xff0c;\u7248\u672c&#xff1a;0.7.2 \u2192 \u5b89\u88c5\u6210\u529f&#xff08;3.7&#043;&#xff09;<\/span><br \/>\n<span class=\"token comment\"># \u6216\u8f93\u51fa&#xff1a;0.6.0 \u2192 \u5b89\u88c5\u6210\u529f&#xff08;3.6&#xff09;<\/span><\/p>\n<p><span class=\"token comment\"># 2. \u57fa\u7840\u529f\u80fd\u9a8c\u8bc1&#xff08;\u8f93\u51fa\u65e5\u5fd7&#xff09;<\/span><br \/>\npython -c <span class=\"token string\">&#034;<br \/>\nfrom loguru import logger<\/p>\n<p># \u8f93\u51fa\u57fa\u7840\u65e5\u5fd7<br \/>\nlogger.info(&#039;\u6d4b\u8bd5loguru\u529f\u80fd&#xff0c;name&#061;{}, age&#061;{}&#039;, &#039;\u5f20\u4e09&#039;, 25)<br \/>\n# \u8f93\u51fa\u6587\u4ef6\u65e5\u5fd7&#xff08;\u9a8c\u8bc1\u6587\u4ef6\u5199\u5165&#xff09;<br \/>\nlogger.add(&#039;test_loguru.log&#039;, rotation&#061;&#039;10 MB&#039;)<br \/>\nlogger.success(&#039;\u6587\u4ef6\u65e5\u5fd7\u5199\u5165\u6210\u529f&#039;)<br \/>\nprint(&#039;loguru\u57fa\u7840\u529f\u80fd\u6b63\u5e38&#039;)<br \/>\n&#034;<\/span><br \/>\n<span class=\"token comment\"># \u8f93\u51fa&#xff1a;2026-01-19 10:00:00.000 | INFO     | __main__:&lt;module&gt;:5 &#8211; \u6d4b\u8bd5loguru\u529f\u80fd&#xff0c;name&#061;\u5f20\u4e09, age&#061;25<\/span><br \/>\n<span class=\"token comment\">#       loguru\u57fa\u7840\u529f\u80fd\u6b63\u5e38&#xff08;\u540c\u65f6\u751f\u6210test_loguru.log\u6587\u4ef6&#xff09;<\/span><\/p>\n<h3>3.3 \u65b9\u68482&#xff1a;\u7248\u672c\u9002\u914d&#xff08;\u5339\u914dPython\/loguru\u7248\u672c&#xff09;<\/h3>\n<p>\u6839\u636ePython\u7248\u672c\u9009\u62e9\u9002\u914d\u7684loguru\u7248\u672c&#xff0c;\u89e3\u51b3\u7248\u672c\u4e0d\u517c\u5bb9\u95ee\u9898&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u573a\u666f1&#xff1a;Python 3.7&#043;&#xff08;\u63a8\u8350\u5b89\u88c5\u6700\u65b0\u7248&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru<span class=\"token operator\">&gt;&#061;<\/span><span class=\"token number\">0.7<\/span>.0 -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u573a\u666f2&#xff1a;Python 3.6&#xff08;\u4ec5\u652f\u6301loguru\u22640.6.0&#xff0c;\u5efa\u8bae\u5347\u7ea7Python&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.6<\/span>.0 -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u573a\u666f3&#xff1a;Python 3.5&#xff08;\u4ec5\u652f\u6301loguru\u22640.5.3&#xff0c;\u5df2\u6dd8\u6c70&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.5<\/span>.3 -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u9a8c\u8bc1\u9002\u914d\u7ed3\u679c<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru; print(&#039;\u9002\u914d\u7248\u672c&#xff1a;&#039;, loguru.__version__)&#034;<\/span><\/p>\n<h3>3.4 \u65b9\u68483&#xff1a;\u865a\u62df\u73af\u5883\u4fee\u590d&#xff08;\u8865\u88c5\u7f3a\u5931\u7684loguru&#xff09;<\/h3>\n<p>\u82e5\u865a\u62df\u73af\u5883\u4e2d\u7f3a\u5931loguru&#xff0c;\u9700\u6fc0\u6d3b\u73af\u5883\u540e\u5355\u72ec\u5b89\u88c5&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa41&#xff1a;\u6fc0\u6d3b\u865a\u62df\u73af\u5883<\/span><br \/>\n<span class=\"token comment\"># Linux\/macOS<\/span><br \/>\n<span class=\"token builtin class-name\">source<\/span> loguru_env\/bin\/activate<br \/>\n<span class=\"token comment\"># Windows&#xff08;CMD&#xff09;<\/span><br \/>\nloguru_env<span class=\"token punctuation\">\\\\<\/span>Scripts<span class=\"token punctuation\">\\\\<\/span>activate<br \/>\n<span class=\"token comment\"># Windows&#xff08;PowerShell&#xff09;<\/span><br \/>\n.<span class=\"token punctuation\">\\\\<\/span>loguru_env<span class=\"token punctuation\">\\\\<\/span>Scripts<span class=\"token punctuation\">\\\\<\/span>Activate.ps1<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa42&#xff1a;\u5728\u865a\u62df\u73af\u5883\u4e2d\u5b89\u88c5loguru&#xff08;\u9002\u914d\u7248\u672c&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 3.7&#043;\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru<span class=\"token operator\">&gt;&#061;<\/span><span class=\"token number\">0.7<\/span>.0 -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<br \/>\n<span class=\"token comment\"># 3.6\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.6<\/span>.0 -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa43&#xff1a;\u9a8c\u8bc1\u5b89\u88c5<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru; print(&#039;\u865a\u62df\u73af\u5883\u4e2dloguru\u53ef\u7528&#039;)&#034;<\/span><\/p>\n<h3>3.5 \u65b9\u68484&#xff1a;\u6743\u9650\u9002\u914d\u2014\u2014\u65e0\u7ba1\u7406\u5458\u6743\u9650\u5b89\u88c5<\/h3>\n<p>\u82e5Linux\/macOS\/Windows\u65e0\u5168\u5c40\u5b89\u88c5\u6743\u9650&#xff0c;\u7528&#8211;user\u5b89\u88c5\u5230\u7528\u6237\u76ee\u5f55&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa41&#xff1a;&#8211;user\u5b89\u88c5loguru&#xff08;\u9002\u914d\u7248\u672c&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 3.7&#043;\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru<span class=\"token operator\">&gt;&#061;<\/span><span class=\"token number\">0.7<\/span>.0 &#8211;user -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<br \/>\n<span class=\"token comment\"># 3.6\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.6<\/span>.0 &#8211;user -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa42&#xff1a;\u914d\u7f6e\u7528\u6237\u76ee\u5f55\u5230PATH&#xff08;Linux\/macOS&#xff0c;\u4e34\u65f6\u751f\u6548&#xff09;<\/span><br \/>\n<span class=\"token builtin class-name\">export<\/span> <span class=\"token assign-left variable\"><span class=\"token environment constant\">PATH<\/span><\/span><span class=\"token operator\">&#061;<\/span><span class=\"token environment constant\">$PATH<\/span>:~\/.local\/bin<br \/>\n<span class=\"token comment\"># \u6c38\u4e45\u751f\u6548&#xff08;bash&#xff09;<\/span><br \/>\n<span class=\"token builtin class-name\">echo<\/span> <span class=\"token string\">&#034;export PATH&#061;\\\\<span class=\"token environment constant\">$PATH<\/span>:~\/.local\/bin&#034;<\/span> <span class=\"token operator\">&gt;&gt;<\/span> ~\/.bashrc<br \/>\n<span class=\"token builtin class-name\">source<\/span> ~\/.bashrc<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa42&#xff1a;Windows\u914d\u7f6e&#xff08;\u56fe\u5f62\u5316&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 1. \u53f3\u952e\u300c\u6b64\u7535\u8111\u300d\u2192\u300c\u5c5e\u6027\u300d\u2192\u300c\u9ad8\u7ea7\u7cfb\u7edf\u8bbe\u7f6e\u300d\u2192\u300c\u73af\u5883\u53d8\u91cf\u300d<\/span><br \/>\n<span class=\"token comment\"># 2. \u5728\u300c\u7528\u6237\u53d8\u91cf\u300d\u7684PATH\u4e2d\u6dfb\u52a0&#xff1a;%USERPROFILE%\\\\AppData\\\\Roaming\\\\Python\\\\Python310\\\\Scripts&#xff08;\u66ff\u6362\u4e3a\u4f60\u7684Python\u7248\u672c&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 3. \u91cd\u542f\u7ec8\u7aef\u9a8c\u8bc1<\/span><\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa43&#xff1a;\u9a8c\u8bc1\u5b89\u88c5<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru; print(&#039;\u65e0\u6743\u9650\u5b89\u88c5\u6210\u529f&#039;)&#034;<\/span><\/p>\n<h3>3.6 \u65b9\u68485&#xff1a;\u4fee\u590d\u65b9\u6848\u2014\u2014\u91cd\u88c5loguru&#xff08;\u7f13\u5b58\u635f\u574f\/\u5b89\u88c5\u4e0d\u5b8c\u6574&#xff09;<\/h3>\n<p>\u82e5\u5b89\u88c5\u540e\u4ecd\u62a5\u9519&#xff0c;\u6e05\u7406pip\u7f13\u5b58\u5e76\u91cd\u88c5&#xff0c;\u786e\u4fddloguru\u53ca\u4f9d\u8d56\u5b8c\u6574&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa41&#xff1a;\u5378\u8f7d\u73b0\u6709loguru\u53ca\u53ef\u9009\u4f9d\u8d56<\/span><br \/>\npython -m pip uninstall loguru colorama win32-setctime -y<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa42&#xff1a;\u6e05\u7406pip\u7f13\u5b58<\/span><br \/>\npip cache purge<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa43&#xff1a;\u91cd\u65b0\u5b89\u88c5&#xff08;\u7981\u7528\u7f13\u5b58&#xff0c;\u6307\u5b9a\u56fd\u5185\u6e90&#xff09;<\/span><br \/>\n<span class=\"token comment\"># 3.7&#043;\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru<span class=\"token operator\">&gt;&#061;<\/span><span class=\"token number\">0.7<\/span>.0 &#8211;no-cache-dir -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<br \/>\n<span class=\"token comment\"># 3.6\u73af\u5883<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.6<\/span>.0 &#8211;no-cache-dir -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa44&#xff1a;\u9a8c\u8bc1\u5b89\u88c5<\/span><br \/>\npip show loguru  <span class=\"token comment\"># \u6709Location\u5b57\u6bb5\u4e14\u65e0\u7f3a\u5931\u6587\u4ef6\u5219\u6210\u529f<\/span><\/p>\n<h3>3.7 \u65b9\u68486&#xff1a;\u79bb\u7ebf\u5b89\u88c5&#xff08;\u65e0\u7f51\u7edc\/\u5185\u7f51\u73af\u5883&#xff09;<\/h3>\n<p>\u82e5\u65e0\u6cd5\u8bbf\u95eePyPI\u6e90&#xff0c;\u4e0b\u8f7dloguru\u53ca\u4f9d\u8d56wheel\u5305\u624b\u52a8\u5b89\u88c5&#xff1a;<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa41&#xff1a;\u4e0b\u8f7d\u5bf9\u5e94\u7248\u672c\u7684wheel\u5305<\/span><br \/>\n<span class=\"token comment\"># loguru\u4e0b\u8f7d\u5730\u5740&#xff1a;https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\/loguru\/<\/span><br \/>\n<span class=\"token comment\"># 3.7&#043;\u73af\u5883&#xff1a;loguru-0.7.2-py3-none-any.whl<\/span><br \/>\n<span class=\"token comment\"># 3.6\u73af\u5883&#xff1a;loguru-0.6.0-py3-none-any.whl<\/span><br \/>\n<span class=\"token comment\"># Windows\u53ef\u9009\u4f9d\u8d56&#xff1a;colorama-0.4.6-py2.py3-none-any.whl<\/span><\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa42&#xff1a;\u5148\u5b89\u88c5\u53ef\u9009\u4f9d\u8d56&#xff08;Windows&#xff09;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> colorama-0.4.6-py2.py3-none-any.whl &#8211;user<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa43&#xff1a;\u79bb\u7ebf\u5b89\u88c5loguru<\/span><br \/>\n<span class=\"token comment\"># 3.7&#043;<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru-0.7.2-py3-none-any.whl &#8211;user<br \/>\n<span class=\"token comment\"># 3.6<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru-0.6.0-py3-none-any.whl &#8211;user<\/p>\n<p><span class=\"token comment\"># \u6b65\u9aa44&#xff1a;\u9a8c\u8bc1\u5b89\u88c5<\/span><br \/>\npython -c <span class=\"token string\">&#034;import loguru; print(&#039;\u79bb\u7ebf\u5b89\u88c5\u6210\u529f&#xff0c;\u7248\u672c&#xff1a;&#039;, loguru.__version__)&#034;<\/span><\/p>\n<h3>3.8 \u65b9\u68487&#xff1a;PyCharm\u73af\u5883\u9002\u914d<\/h3>\n<h4>\u5b50\u573a\u666f1&#xff1a;PyCharm\u4e2d\u8fd0\u884cloguru\u62a5\u9519\u7f3a\u5931\u6a21\u5757<\/h4>\n<li>\u6253\u5f00PyCharm \u2192 File \u2192 Settings \u2192 Project: xxx \u2192 Python Interpreter&#xff1b;<\/li>\n<li>\u70b9\u51fb&#043;\u53f7 \u2192 \u641c\u7d22loguru&#xff08;\u5168\u5c0f\u5199&#xff09;\u2192 \u70b9\u51fbInstall Package&#xff1b;\n<ul>\n<li>\u82e5Python 3.6&#xff0c;\u5b89\u88c5\u540e\u68c0\u67e5\u7248\u672c\u662f\u5426\u4e3a0.6.0&#xff1b;<\/li>\n<li>\u82e5Python 3.7&#043;&#xff0c;\u9ed8\u8ba4\u88c50.7.x\u5373\u53ef&#xff1b;<\/li>\n<\/ul>\n<\/li>\n<li>&#xff08;\u53ef\u9009&#xff09;\u641c\u7d22colorama\u5e76\u5b89\u88c5&#xff08;Windows\u73af\u5883&#xff09;&#xff1b;<\/li>\n<li>\u5728PyCharm\u7ec8\u7aef\u6267\u884cpython -c &#034;import loguru&#034;\u9a8c\u8bc1&#xff1b;<\/li>\n<li>\u7f16\u5199\u6d4b\u8bd5\u4ee3\u7801\u8fd0\u884c&#xff0c;\u65e0\u62a5\u9519\u5219\u5b8c\u6210\u3002<\/li>\n<h4>\u5b50\u573a\u666f2&#xff1a;PyCharm\u865a\u62df\u73af\u5883\u4e2d\u8bc6\u522b\u4e0d\u5230loguru<\/h4>\n<li>\u5728PyCharm\u4e2d\u5207\u6362\u5230\u9879\u76ee\u865a\u62df\u73af\u5883 \u2192 \u6253\u5f00\u7ec8\u7aef&#xff1b;<\/li>\n<li>\u6267\u884c\u9002\u914d\u7248\u672c\u7684\u5b89\u88c5\u547d\u4ee4&#xff08;\u59823.6\u88c5pip install loguru&#061;&#061;0.6.0&#xff09;&#xff1b;<\/li>\n<li>\u5237\u65b0PyCharm\u89e3\u91ca\u5668\u7f13\u5b58&#xff1a;File \u2192 Invalidate Caches \/ Restart \u2192 Invalidate and Restart&#xff1b;<\/li>\n<li>\u91cd\u65b0\u6267\u884c\u9a8c\u8bc1\u547d\u4ee4&#xff0c;\u786e\u8ba4\u6a21\u5757\u53ef\u7528\u3002<\/li>\n<h2>\u56db\u3001\u6392\u969c\u6280\u5de7&#xff1a;\u4fee\u590d\u540e\u4ecd\u63d0\u793a\u6a21\u5757\u627e\u4e0d\u5230<\/h2>\n<h3>4.1 \u5b89\u88c5loguru\u540e\u4ecd\u62a5ModuleNotFoundError: No module named \u2018loguru\u2019<\/h3>\n<h4>\u539f\u56e0&#xff1a;<\/h4>\n<ul>\n<li>pip\u4e0epython\u6307\u5411\u4e0d\u540cPython\u7248\u672c&#xff1b;<\/li>\n<li>\u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b&#xff0c;loguru\u88c5\u5230\u7cfb\u7edfPython&#xff1b;<\/li>\n<li>Python 3.6\u88c5\u4e86loguru 0.7.0&#043;&#xff0c;\u7248\u672c\u4e0d\u517c\u5bb9&#xff1b;<\/li>\n<li>\u5b89\u88c5\u8def\u5f84\u672a\u52a0\u5165sys.path&#xff1b;<\/li>\n<li>\u6740\u6bd2\u8f6f\u4ef6\u5220\u9664\u4e86loguru\u6838\u5fc3\u6587\u4ef6\u3002<\/li>\n<\/ul>\n<h4>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/h4>\n<li>\u5f3a\u5236\u6307\u5b9aPython\u8def\u5f84\u5b89\u88c5\/\u8fd0\u884c&#xff1a;<span class=\"token comment\"># Linux\/macOS&#xff1a;\u67e5\u770bPython\u8def\u5f84<\/span><br \/>\n<span class=\"token function\">which<\/span> python  <span class=\"token comment\"># \u8f93\u51fa&#xff1a;\/usr\/bin\/python3.10<\/span><br \/>\n\/usr\/bin\/python3.10 -m pip <span class=\"token function\">install<\/span> loguru  <span class=\"token comment\"># \u91cd\u65b0\u5b89\u88c5<\/span><br \/>\n\/usr\/bin\/python3.10 -c <span class=\"token string\">&#034;import loguru&#034;<\/span>  <span class=\"token comment\"># \u76f4\u63a5\u8fd0\u884c<\/span>\n <\/li>\n<li>\u9a8c\u8bc1Python\u7684sys.path&#xff0c;\u786e\u4fdd\u5b89\u88c5\u8def\u5f84\u5728\u5176\u4e2d&#xff1a;python -c <span class=\"token string\">&#034;<br \/>\nimport sys<br \/>\nprint(&#039;Python\u8def\u5f84&#xff1a;&#039;, sys.path)  # \u68c0\u67e5loguru\u5b89\u88c5\u8def\u5f84\u662f\u5426\u5728\u5217\u8868\u4e2d<br \/>\n&#034;<\/span>\n <\/li>\n<li>\u9488\u5bf93.6\u73af\u5883\u964d\u7ea7\u52300.6.0&#xff1a;python -m pip uninstall loguru -y<br \/>\npython -m pip <span class=\"token function\">install<\/span> <span class=\"token assign-left variable\">loguru<\/span><span class=\"token operator\">&#061;&#061;<\/span><span class=\"token number\">0.6<\/span>.0\n <\/li>\n<li>\u5173\u95ed\u6740\u6bd2\u8f6f\u4ef6\u540e\u91cd\u65b0\u5b89\u88c5&#xff1a;python -m pip uninstall loguru -y<br \/>\n<span class=\"token comment\"># \u5173\u95edWindows Defender\/\u7b2c\u4e09\u65b9\u6740\u6bd2\u8f6f\u4ef6<\/span><br \/>\npython -m pip <span class=\"token function\">install<\/span> loguru &#8211;no-cache-dir\n <\/li>\n<h3>4.2 Linux\/macOS\u62a5\u201cPermission denied\u201d\u5b89\u88c5\u5931\u8d25<\/h3>\n<h4>\u539f\u56e0&#xff1a;<\/h4>\n<ul>\n<li>\u65e0\u6743\u9650\u5199\u5165\u7cfb\u7edfPython\u76ee\u5f55&#xff1b;<\/li>\n<li>sudo pip\u7ed1\u5b9a\u7cfb\u7edfPython&#xff0c;\u5bfc\u81f4\u7248\u672c\u9519\u4f4d\u3002<\/li>\n<\/ul>\n<h4>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/h4>\n<li>\u4f18\u5148\u7528&#8211;user\u5b89\u88c5&#xff08;\u63a8\u8350&#xff09;&#xff1a;python -m pip <span class=\"token function\">install<\/span> loguru &#8211;user\n <\/li>\n<li>\u82e5\u5fc5\u987b\u5168\u5c40\u5b89\u88c5&#xff0c;\u7528sudo\u6307\u5b9aPython\u7248\u672c&#xff1a;<span class=\"token function\">sudo<\/span> \/usr\/bin\/python3.10 -m pip <span class=\"token function\">install<\/span> loguru\n <\/li>\n<h3>4.3 \u7f51\u7edc\u95ee\u9898\u5bfc\u81f4\u65e0\u6cd5\u4e0b\u8f7dloguru<\/h3>\n<h4>\u539f\u56e0&#xff1a;<\/h4>\n<ul>\n<li>\u8bbf\u95eePyPI\u5b98\u65b9\u6e90\u8d85\u65f6&#xff1b;<\/li>\n<li>\u516c\u53f8\u5185\u7f51\u9650\u5236\u8bbf\u95ee\u5916\u90e8\u6e90\u3002<\/li>\n<\/ul>\n<h4>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/h4>\n<li>\u4f7f\u7528\u56fd\u5185\u955c\u50cf\u6e90\u5b89\u88c5&#xff1a;python -m pip <span class=\"token function\">install<\/span> loguru -i https:\/\/mirrors.aliyun.com\/pypi\/simple\/\n <\/li>\n<li>\u914d\u7f6epip\u6c38\u4e45\u4f7f\u7528\u56fd\u5185\u6e90&#xff1a;<span class=\"token comment\"># Linux\/macOS<\/span><br \/>\n<span class=\"token function\">mkdir<\/span> -p ~\/.config\/pip<br \/>\n<span class=\"token builtin class-name\">echo<\/span> <span class=\"token string\">&#034;[global]<br \/>\nindex-url &#061; https:\/\/pypi.tuna.tsinghua.edu.cn\/simple&#034;<\/span> <span class=\"token operator\">&gt;<\/span> ~\/.config\/pip\/pip.conf<\/p>\n<p><span class=\"token comment\"># Windows&#xff08;PowerShell&#xff09;<\/span><br \/>\n<span class=\"token function\">mkdir<\/span> <span class=\"token variable\">$env<\/span>:APPDATA<span class=\"token punctuation\">\\\\<\/span>pip<br \/>\n<span class=\"token builtin class-name\">echo<\/span> <span class=\"token string\">&#034;[global]<br \/>\nindex-url &#061; https:\/\/pypi.tuna.tsinghua.edu.cn\/simple&#034;<\/span> <span class=\"token operator\">&gt;<\/span> <span class=\"token variable\">$env<\/span>:APPDATA<span class=\"token punctuation\">\\\\<\/span>pip<span class=\"token punctuation\">\\\\<\/span>pip.ini\n <\/li>\n<h3>4.4 Conda\u73af\u5883\u4e2d\u5bfc\u5165loguru\u5931\u8d25<\/h3>\n<h4>\u539f\u56e0&#xff1a;<\/h4>\n<ul>\n<li>Conda\u73af\u5883\u672a\u6fc0\u6d3b&#xff0c;loguru\u88c5\u5230\u7cfb\u7edfPython&#xff1b;<\/li>\n<li>Conda\u7684Python\u7248\u672c\u4e0eloguru\u4e0d\u517c\u5bb9\u3002<\/li>\n<\/ul>\n<h4>\u89e3\u51b3\u65b9\u6848&#xff1a;<\/h4>\n<li>\u6fc0\u6d3bConda\u73af\u5883\u540e\u5b89\u88c5&#xff1a;conda activate loguru_env<br \/>\npip <span class=\"token function\">install<\/span> loguru\n <\/li>\n<li>\u7528Conda\u5b89\u88c5loguru&#xff08;\u5907\u9009&#xff09;&#xff1a;conda activate loguru_env<br \/>\nconda <span class=\"token function\">install<\/span> -c conda-forge loguru\n <\/li>\n<h2>\u4e94\u3001\u9884\u9632\u63aa\u65bd&#xff1a;\u907f\u514dModuleNotFoundError\u590d\u53d1<\/h2>\n<h3>5.1 \u4e2a\u4eba\u5f00\u53d1\u73af\u5883<\/h3>\n<li>\u7262\u8bb0\u6838\u5fc3\u5b89\u88c5\u89c4\u5219&#xff1a;\n<ul>\n<li>\u59cb\u7ec8\u7528python -m pip install loguru\u66ff\u4ee3\u76f4\u63a5pip install loguru&#xff0c;\u786e\u4fdd\u7248\u672c\u5339\u914d&#xff1b;<\/li>\n<li>\u65b0\u5efa\u865a\u62df\u73af\u5883\u540e&#xff0c;\u5148\u6fc0\u6d3b\u518d\u5b89\u88c5loguru&#xff0c;\u907f\u514d\u73af\u5883\u9519\u4f4d&#xff1b;<\/li>\n<li>\u5b89\u88c5\u524d\u5148\u68c0\u67e5Python\u7248\u672c&#xff1a;Python 3.7&#043;\u88c50.7.x&#xff0c;3.6\u88c50.6.0&#xff0c;3.5\u53ca\u4ee5\u4e0b\u5347\u7ea7Python&#xff1b;<\/li>\n<li>\u5b89\u88c5\u540e\u7acb\u5373\u9a8c\u8bc1&#xff1a;python -c &#034;import loguru&#034;\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u907f\u514d\u6df7\u7528\u5168\u5c40\/\u865a\u62df\u73af\u5883&#xff1a; \u4f18\u5148\u4f7f\u7528\u865a\u62df\u73af\u5883\u7ba1\u7406loguru&#xff0c;\u9632\u6b62\u4e0d\u540c\u9879\u76ee\u7248\u672c\u51b2\u7a81\u3002<\/li>\n<li>\u56fa\u5b9a\u4f9d\u8d56\u7248\u672c&#xff1a; \u5728requirements.txt\u4e2d\u660e\u786e\u6307\u5b9a\u7248\u672c&#xff0c;\u907f\u514d\u81ea\u52a8\u5347\u7ea7\u5bfc\u81f4\u517c\u5bb9\u95ee\u9898&#xff1a;# 3.7&#043;\u73af\u5883<br \/>\nloguru&#061;&#061;0.7.2<br \/>\ncolorama&gt;&#061;0.4.6  # Windows\u5f69\u8272\u8f93\u51fa<br \/>\n# 3.6\u73af\u5883<br \/>\nloguru&#061;&#061;0.6.0\n <\/li>\n<h3>5.2 \u56e2\u961f\u5f00\u53d1\u73af\u5883<\/h3>\n<li>\u6807\u51c6\u5316\u73af\u5883\u914d\u7f6e&#xff1a; \u63d0\u4f9b\u7edf\u4e00\u7684\u73af\u5883\u8981\u6c42\u548c\u5b89\u88c5\u547d\u4ee4&#xff0c;\u907f\u514d\u7248\u672c\u6df7\u4e71&#xff1a;## loguru\u73af\u5883\u914d\u7f6e\u8bf4\u660e<br \/>\n### \u73af\u5883\u8981\u6c42<br \/>\n&#8211; Python&#xff1a;3.7~3.13&#xff08;\u63a8\u83503.10&#xff09;\u2192 \u7528loguru 0.7.2&#xff1b;3.6 \u2192 \u75280.6.0<br \/>\n&#8211; loguru&#xff1a;0.7.2&#xff08;3.7&#043;&#xff09;\/ 0.6.0&#xff08;3.6&#xff09;<br \/>\n&#8211; \u53ef\u9009\u4f9d\u8d56&#xff1a;colorama\u22650.4.6&#xff08;Windows&#xff09;<\/p>\n<p>### \u5b89\u88c5\u6b65\u9aa4<br \/>\n1. \u521b\u5efa\u865a\u62df\u73af\u5883&#xff1a;python -m venv loguru_env<br \/>\n2. \u6fc0\u6d3b\u73af\u5883&#xff1a;source loguru_env\/bin\/activate&#xff08;Linux\/macOS&#xff09;<br \/>\n3. \u5b89\u88c5\u4f9d\u8d56&#xff1a;python -m pip install -r requirements.txt -i \u6e05\u534e\u6e90<br \/>\n4. \u9a8c\u8bc1&#xff1a;python -c &#034;import loguru&#034;\n <\/li>\n<li>CI\/CD\u81ea\u52a8\u9a8c\u8bc1&#xff1a; \u5728\u6d41\u6c34\u7ebf\u4e2d\u9a8c\u8bc1loguru\u5b89\u88c5\u548c\u57fa\u7840\u529f\u80fd&#xff0c;\u63d0\u524d\u53d1\u73b0\u95ee\u9898&#xff1a;<span class=\"token comment\"># .gitlab-ci.yml\u793a\u4f8b<\/span><br \/>\n<span class=\"token key atrule\">test-loguru<\/span><span class=\"token punctuation\">:<\/span><br \/>\n  <span class=\"token key atrule\">script<\/span><span class=\"token punctuation\">:<\/span><br \/>\n    <span class=\"token punctuation\">&#8211;<\/span> python <span class=\"token punctuation\">&#8211;<\/span>m pip install loguru&#061;&#061;0.7.2  <span class=\"token comment\"># 3.7&#043;\u73af\u5883<\/span><br \/>\n    <span class=\"token punctuation\">&#8211;<\/span> python <span class=\"token punctuation\">&#8211;<\/span>c &#034;import loguru; assert loguru.__version__ &#061;&#061; &#039;0.7.2&#039;&#034;<br \/>\n    <span class=\"token punctuation\">&#8211;<\/span> python <span class=\"token punctuation\">&#8211;<\/span>c &#034;from loguru import logger; logger.info(&#039;loguru\u9a8c\u8bc1\u901a\u8fc7&#039;)&#034;\n <\/li>\n<h2>\u516d\u3001\u603b\u7ed3<\/h2>\n<p>ModuleNotFoundError: No module named &#039;loguru&#039;\u7684\u6838\u5fc3\u89e3\u51b3\u601d\u8def\u662f\u786e\u4fddpip\u4e0epython\u7248\u672c\u4e00\u81f4 &#043; \u9002\u914dPython\/loguru\u7248\u672c &#043; \u5b8c\u6574\u5b89\u88c5loguru\u4e3b\u5305 &#043; \u6fc0\u6d3b\u5bf9\u5e94\u73af\u5883&#xff1a;<\/p>\n<li>\u6838\u5fc3\u65b9\u6848&#xff1a;\u4f18\u5148\u7528python -m pip install loguru\u5b89\u88c5&#xff0c;\u65e0\u7ba1\u7406\u5458\u6743\u9650\u52a0&#8211;user&#xff1b;\u865a\u62df\u73af\u5883\u9700\u6fc0\u6d3b\u540e\u5b89\u88c5&#xff1b;Python 3.7&#043;\u88c50.7.x&#xff0c;3.6\u88c50.6.0&#xff1b;<\/li>\n<li>\u5173\u952e\u907f\u5751&#xff1a;\u907f\u514d\u76f4\u63a5\u7528pip install loguru&#xff08;\u7248\u672c\u9519\u4f4d\u98ce\u9669&#xff09;&#xff0c;\u907f\u514d\u5728\u672a\u6fc0\u6d3b\u7684\u865a\u62df\u73af\u5883\u4e2d\u8fd0\u884c\u4ee3\u7801&#xff0c;\u907f\u514dPython 3.6\u88c5loguru 0.7&#043;&#xff1b;<\/li>\n<li>\u9002\u914d\u6280\u5de7&#xff1a;loguru\u65e0\u547d\u540d\u9677\u9631&#xff0c;\u62a5\u951990%\u6e90\u4e8e\u73af\u5883\u9519\u4f4d\/\u7248\u672c\u4e0d\u517c\u5bb9&#xff0c;\u56fd\u5185\u955c\u50cf\u6e90\u53ef\u89e3\u51b3\u7f51\u7edc\u95ee\u9898&#xff0c;\u6e05\u7406\u7f13\u5b58\u53ef\u4fee\u590d\u5b89\u88c5\u4e0d\u5b8c\u6574\u3002<\/li>\n<h4>\u5173\u952e\u70b9\u56de\u987e<\/h4>\n<li>loguru\u7684\u5b89\u88c5\u540d\u548c\u5bfc\u5165\u540d\u5747\u4e3a\u5168\u5c0f\u5199&#xff0c;\u65e0\u4efb\u4f55\u547d\u540d\u9677\u9631&#xff0c;\u6838\u5fc3\u95ee\u9898\u662f\u73af\u5883\u4e00\u81f4\u6027&#xff1b;<\/li>\n<li>\u4fee\u590d\u7684\u6838\u5fc3\u6280\u5de7\u662f&#xff1a;\u7528python -m pip\u5b89\u88c5&#xff08;\u7ed1\u5b9a\u5f53\u524dPython&#xff09;\u3001\u6fc0\u6d3b\u865a\u62df\u73af\u5883\u3001\u5339\u914dPython\u7248\u672c&#xff08;3.7&#043;\u6700\u4f73&#xff09;&#xff1b;<\/li>\n<li>loguru\u7248\u672c\u4e0ePython\u5f3a\u7ed1\u5b9a&#xff08;0.7.x\u21923.7&#043;&#xff0c;0.6.0\u21923.6&#xff09;&#xff0c;\u7248\u672c\u9009\u9519\u76f4\u63a5\u5bfc\u81f4\u5b89\u88c5\/\u5bfc\u5165\u5931\u8d25\u3002<\/li>\n<p>\u3010\u4e13\u680f\u5730\u5740\u3011 \u66f4\u591a Python \u5f00\u53d1\u9ad8\u9891 bug \u89e3\u51b3\u65b9\u6848\u3001loguru\u65e5\u5fd7\u6700\u4f73\u5b9e\u8df5&#xff0c;\u6b22\u8fce\u8ba2\u9605\u6211\u7684 CSDN \u4e13\u680f&#xff1a;&#x1f525;\u5168\u6808BUG\u89e3\u51b3\u65b9\u6848<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6458\u8981<br \/>\n\u4f60\u5728\u4f7f\u7528pip\u5b89\u88c5\/\u8fd0\u884cloguru\u65f6\u9047\u5230ModuleNotFoundError: No module named loguru\u62a5\u9519&#xff0c;\u8be5\u95ee\u9898\u6838\u5fc3\u8bf1\u56e0\u662f\u73af\u5883\u4e00\u81f4\u6027\u95ee\u9898&#xff08;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff0c;\u5360\u6bd445%&#xff09; \u5b89\u88c5\u4e0d\u5b8c\u6574  \u6743\u9650\u4e0d\u8db3  \u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b  Python\u7248\u672c\u4e0d\u517c\u5bb9  \u7f13\u5b58\u635f\u574f&#xff1a;loguru\u662fPython\u6781\u7b80\u4e14\u529f\u80fd\u5f3a\u5927\u7684\u65e5\u5fd7\u5e93&#xff08;\u65e0\u9700\u590d\u6742\u914d\u7f6e\u3001\u652f\u6301\u5f02\u6b65\/\u5f69\u8272\u8f93\u51fa\u3001\u6587\u4ef6\u8f6e\u8f6c&amp;#x<\/p>\n","protected":false},"author":2,"featured_media":64447,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[249,216,81],"topic":[],"class_list":["post-64448","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-bug","tag-pip","tag-python"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/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.wsisp.com\/helps\/64448.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6458\u8981 \u4f60\u5728\u4f7f\u7528pip\u5b89\u88c5\/\u8fd0\u884cloguru\u65f6\u9047\u5230ModuleNotFoundError: No module named loguru\u62a5\u9519&#xff0c;\u8be5\u95ee\u9898\u6838\u5fc3\u8bf1\u56e0\u662f\u73af\u5883\u4e00\u81f4\u6027\u95ee\u9898&#xff08;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff0c;\u5360\u6bd445%&#xff09; \u5b89\u88c5\u4e0d\u5b8c\u6574 \u6743\u9650\u4e0d\u8db3 \u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b Python\u7248\u672c\u4e0d\u517c\u5bb9 \u7f13\u5b58\u635f\u574f&#xff1a;loguru\u662fPython\u6781\u7b80\u4e14\u529f\u80fd\u5f3a\u5927\u7684\u65e5\u5fd7\u5e93&#xff08;\u65e0\u9700\u590d\u6742\u914d\u7f6e\u3001\u652f\u6301\u5f02\u6b65\/\u5f69\u8272\u8f93\u51fa\u3001\u6587\u4ef6\u8f6e\u8f6c&amp;#x\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/64448.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-01-23T07:40:28+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/01\/20260123074025-697325e92c106.jpg\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"10 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/64448.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/64448.html\",\"name\":\"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-01-23T07:40:28+00:00\",\"dateModified\":\"2026-01-23T07:40:28+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/64448.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/64448.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/64448.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","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.wsisp.com\/helps\/64448.html","og_locale":"zh_CN","og_type":"article","og_title":"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6458\u8981 \u4f60\u5728\u4f7f\u7528pip\u5b89\u88c5\/\u8fd0\u884cloguru\u65f6\u9047\u5230ModuleNotFoundError: No module named loguru\u62a5\u9519&#xff0c;\u8be5\u95ee\u9898\u6838\u5fc3\u8bf1\u56e0\u662f\u73af\u5883\u4e00\u81f4\u6027\u95ee\u9898&#xff08;pip\u4e0epython\u7248\u672c\u9519\u4f4d&#xff0c;\u5360\u6bd445%&#xff09; \u5b89\u88c5\u4e0d\u5b8c\u6574 \u6743\u9650\u4e0d\u8db3 \u865a\u62df\u73af\u5883\u672a\u6fc0\u6d3b Python\u7248\u672c\u4e0d\u517c\u5bb9 \u7f13\u5b58\u635f\u574f&#xff1a;loguru\u662fPython\u6781\u7b80\u4e14\u529f\u80fd\u5f3a\u5927\u7684\u65e5\u5fd7\u5e93&#xff08;\u65e0\u9700\u590d\u6742\u914d\u7f6e\u3001\u652f\u6301\u5f02\u6b65\/\u5f69\u8272\u8f93\u51fa\u3001\u6587\u4ef6\u8f6e\u8f6c&amp;#x","og_url":"https:\/\/www.wsisp.com\/helps\/64448.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-01-23T07:40:28+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/01\/20260123074025-697325e92c106.jpg"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"10 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/64448.html","url":"https:\/\/www.wsisp.com\/helps\/64448.html","name":"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-01-23T07:40:28+00:00","dateModified":"2026-01-23T07:40:28+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/64448.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/64448.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/64448.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"Python\u7cfb\u5217Bug\u4fee\u590d\uff5c\u5982\u4f55\u89e3\u51b3 pip install \u5b89\u88c5\u62a5\u9519 ModuleNotFoundError: No module named \u2018loguru\u2019 \u95ee\u9898"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/64448","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=64448"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/64448\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/64447"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=64448"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=64448"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=64448"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=64448"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}