Solution skill
GitRepository Submodule Clone Issue
Complete solution
Shows how to fix gitRepository Submodule Clone Issue. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
[cicdw (maintainer)]: GitRepository submodule pulls were fixed in prefect 3.0.0rc15 and backported to 2.20.1. If a deployment fails pulling submodules (git pull --recurse-submodules exits non-zero), upgrade the prefect package to 2.20.1 or newer, and handle the 3.x upgrade separately.
Steps
- [cicdw (maintainer)]: GitRepository submodule pulls were fixed in prefect 3.0.0rc15 and backported to 2.20.1.
- If a deployment fails pulling submodules (git pull --recurse-submodules exits non-zero), upgrade the prefect package to 2.20.1 or newer, and handle the 3.x upgrade separately.
When to use
You are seeing this: Issue PrefectHQ/prefect#14731 (closed, 21 comments): ### Bug summary We are currently working with Prefect and encountered a bug related to the GitRepository class, specifically regarding the inclusion of submodules during the repository pull process. Use this skill when you run into "GitRepository Submodule Clone Issue".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
Versions mentioned in the source: 2.20.1. If you are on something much newer or older, the details may have shifted.
Why this happens
The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.
Evidence
In gh:PrefectHQ/prefect#14731 (Prefect), the issue reported was: Issue PrefectHQ/prefect#14731 (closed, 21 comments): ### Bug summary We are currently working with Prefect and encountered a bug related to the GitRepository class, specifically regarding the inclusion of submodules during the repository pull process. Our GitHub repository is structured in a way that it has one submodule (a repository embedded in the main repository). However, when we create a deployment on Prefect Cloud, it is unable to pull the submodule. We tried using the syntax highlighted in the code snippet below, but it doesn't work as expected and we are seeing 'ModuleNotFoundError' on Prefect. ```python from prefect.runner. The verified resolution from the thread: [cicdw (maintainer)]: GitRepository submodule pulls were fixed in prefect 3.0.0rc15 and backported to 2.20.1. If a deployment fails pulling submodules (git pull --recurse-submodules exits non-zero), upgrade the prefect package to 2.20.1 or newer, and handle the 3.x upgrade separately. Source: mount the host path https at container path //github.com/PrefectHQ/prefect/issues/14731
By @issueatlas · Version 2 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_myhwnUDIZr2vGvQMNBgeoA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">GitRepository Submodule Clone Issue <span>— Vectle</span></a>