Skip to content

Commit 6ca378c

Browse files
author
Hanzhang Zeng (Roger)
committed
Fix markdown links
1 parent a8f2a9b commit 6ca378c

File tree

3 files changed

+15
-15
lines changed

3 files changed

+15
-15
lines changed

articles/azure-functions/TOC.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@
329329
- name: Troubleshoot storage
330330
href: functions-recover-storage-account.md
331331
- name: Troubleshoot Python dependencies
332-
href: functions-recover-module-not-found.md
332+
href: recover-module-not-found.md
333333
- name: Reference
334334
items:
335335
- name: API references

articles/azure-functions/functions-reference-python.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@ CORS is fully supported for Python function apps.
635635

636636
Thanks to your valuable feedbacks, we are able to maintain a list of troubleshooting guides for common issues:
637637

638-
* [ModuleNotFoundError and ImportError](functions-recover-module-not-found.md)
638+
* [ModuleNotFoundError and ImportError](recover-module-not-found.md)
639639

640640
All known issues and feature requests are tracked using [GitHub issues](https://github.com/Azure/azure-functions-python-worker/issues) list. If you run into a problem and can't find the issue in GitHub, open a new issue and include a detailed description of the problem.
641641

articles/azure-functions/recover-module-not-found.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ This article helps you troubleshoot module-related errors in your Python functio
1616
1717
This error issue occurs when a Python function app fails to load a Python module. The root cause for this error is one of the following issues:
1818

19-
- [The package can't be found](#the-package-cannot-be-found)
20-
- [The package isn't resolved with proper Linux wheel](#the-package-is-not-resolved-with-proper-linux-wheel)
19+
- [The package can't be found](#the-package-cant-be-found)
20+
- [The package isn't resolved with proper Linux wheel](#the-package-isnt-resolved-with-proper-linux-wheel)
2121
- [The package is incompatible with the Python interpreter version](#the-package-is-incompatible-with-the-python-interpreter-version)
2222
- [The package conflicts with other packages](#the-package-conflicts-with-other-packages)
2323
- [The package only supports Windows or macOS platforms](#the-package-only-supports-windows-or-macos-platforms)
@@ -33,9 +33,9 @@ To identify the actual cause of your issue, you need to get the Python project f
3333

3434
The rest of this article helps you troubleshoot potential causes of this error by inspecting your function app's content, identifying the root cause, and resolving the specific issue.
3535

36-
## Diagnose ModuleNotFoundError
36+
## Diagnose ModuleNotFoundError
3737

38-
This section details potential root causes of module-related errors. After you figure out which is the likely root cause, you can go to the related mitigation.
38+
This section details potential root causes of module-related errors. After you figure out which is the likely root cause, you can go to the related mitigation.
3939

4040
### The package can't be found
4141

@@ -57,13 +57,13 @@ See [Enable Remote Build](#enable-remote-build) or [Build Native Dependencies](#
5757

5858
Go to `.python_packages/lib/python3.6/site-packages/<package-name>-<version>-dist-info` or `.python_packages/lib/site-packages/<package-name>-<version>-dist-info`. Using a text editor, open the METADATA file and check the **Classifiers:** section. If the section doesn't contains `Python :: 3`, `Python :: 3.6`, `Python :: 3.7`, or `Python :: 3.8`, this means the package version is either too old, or most likely, the package is already out of maintenance.
5959

60-
You can check the Python version of your function app from the [Azure portal](https://portal.azure.com). Navigate to your function app, choose **Resource explorer**, and select **Go**.
60+
You can check the Python version of your function app from the [Azure portal](https://portal.azure.com). Navigate to your function app, choose **Resource explorer**, and select **Go**.
6161

6262
:::image type="content" source="media/recover-module-not-found/resource-explorer.png" alt-text="Open the Resource Explorer for the function app in the portal":::
6363

6464
After the explorer loads, search for **LinuxFxVersion**, which shows the Python version.
6565

66-
See [Update Package To The Latest Version](#update-package-to-the-latest-version) or [Replace Package With Equivalents](#replace-package-with-equivalents) for mitigation.
66+
See [Update Your Package To The Latest Version](#update-your-package-to-the-latest-version) or [Replace the package with equivalents](#replace-the-package-with-equivalents) for mitigation.
6767

6868
### The package conflicts with other packages
6969

@@ -73,30 +73,30 @@ If you have verified that the package is resolved correctly with the proper Linu
7373
If you installed azure-storage, or if you installed azure 1.x/2.x and didn’t uninstall azure-storage,
7474
you must uninstall azure-storage first.</pre>
7575

76-
You can find the documentation for your package version in `https://pypi.org/project/<package-name>/<package-version>`.
76+
You can find the documentation for your package version in `https://pypi.org/project/<package-name>/<package-version>`.
7777

78-
See [Update Package To The Latest Version](#update-package-to-the-latest-version) or [Replace Package With Equivalents](#replace-package-with-equivalents) for mitigation.
78+
See [Update Your Package To The Latest Version](#update-your-package-to-the-latest-version) or [Replace the package with equivalents](#replace-the-package-with-equivalents) for mitigation.
7979

8080
### The package only supports Windows or macOS platforms
8181

8282
Open the `requirements.txt` with a text editor and check the package in `https://pypi.org/project/<package-name>`. Some packages only run on Windows or macOS platforms. For example, pywin32 only runs on Windows.
8383

8484
The `Module Not Found` error may not occur when you're using Windows or macOS for local development. However, the package fails to import on Azure Functions, which uses Linux at runtime. This is likely to be caused by using `pip freeze` to export virtual environment into requirements.txt from your Windows or macOS machine during project initialization.
8585

86-
See [Replace Package With Equivalents](#replace-package-with-equivalents) or [Handcraft Requirements.txt](#handcraft-requirementstxt) for mitigation.
86+
See [Replace the package with equivalents](#replace-the-package-with-equivalents) or [Handcraft Requirements.txt](#handcraft-requirementstxt) for mitigation.
8787

8888
## Mitigate ModuleNotFoundError
8989

90-
The following are potential mitigations for module-related issues. Use the [diagnoses above](#diagnose-the-root-cause) to determine which of these mitigations to try.
90+
The following are potential mitigations for module-related issues. Use the [diagnoses above](#diagnose-modulenotfounderror) to determine which of these mitigations to try.
9191

9292
### Enable remote build
9393

9494
Make sure that remote build is enabled. The way that you do this depends on your deployment method.
9595

96-
# [Visual Studio Code](#tab/vscode)
96+
# [Visual Studio Code](#tab/vscode)
9797
Make sure that the latest version of the [Azure Functions extension for Visual Studio Code](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-azurefunctions) is installed. Verify that `.vscode/settings.json` exists and it contains the setting `"azureFunctions.scmDoBuildDuringDeployment": true`. If not, please create this file with the `azureFunctions.scmDoBuildDuringDeployment` setting enabled and redeploy the project.
9898

99-
# [Azure Functions Core Tools](#tab/coretools)
99+
# [Azure Functions Core Tools](#tab/coretools)
100100

101101
Make sure that the latest version of [Azure Functions Core Tools](https://github.com/Azure/azure-functions-core-tools/releases) is installed. Go to your local function project folder, and use `func azure functionapp publish <app-name>` for deployment.
102102

@@ -118,7 +118,7 @@ If these are correct, you can update the package to the latest version by changi
118118

119119
### Handcraft requirements.txt
120120

121-
Some developers use `pip freeze > requirements.txt` to generate the list of Python packages for their developing environments. Although this convenience should work in most cases, there can be issues in cross-platform deployment scenarios, such as developing functions locally on Windows or macOS, but publishing to a function app, which runs on Linux. In this scenario, `pip freeze` can introduce unexpected operating system-specific dependencies or dependencies for your local development environment. These dependencies can break the Python function app when running on Linux.
121+
Some developers use `pip freeze > requirements.txt` to generate the list of Python packages for their developing environments. Although this convenience should work in most cases, there can be issues in cross-platform deployment scenarios, such as developing functions locally on Windows or macOS, but publishing to a function app, which runs on Linux. In this scenario, `pip freeze` can introduce unexpected operating system-specific dependencies or dependencies for your local development environment. These dependencies can break the Python function app when running on Linux.
122122

123123
The best practice is to check the import statement from each .py file in your project source code and only check-in those modules in requirements.txt file. This guarantees the resolution of packages can be handled properly on different operating systems.
124124

0 commit comments

Comments
 (0)