Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Github Token not added to Piplock file for github repos, which fails installation #6256

Closed
nakulsingh1299 opened this issue Sep 25, 2024 · 3 comments · Fixed by #6257
Closed
Labels
PR: awaiting-review The PR related to this issue is awaiting review by a maintainer. Type: Regression This issue is a regression of a previous behavior.

Comments

@nakulsingh1299
Copy link

nakulsingh1299 commented Sep 25, 2024

Issue description

Version 2024.0.3
I use private Github repos as a utility in my backend service code.

Pipfile
utility = {ref = "1.0.0", git = "https://${GITHUB_TOKEN}@github.com/org/Utilities"}

where GITHUB_TOKEN is an environment variable
When I lock my Pipfile using the latest version, it does not add the GitHub token in the Piplock file and it is not able to fetch the private packages from GitHub while installing dependencies

Expected result

Previous Piplock file

"utility": {
            "git": "https://${GITHUB_TOKEN}@github.com/org/Utilities",
            "ref": "commit-id"
 }

Actual result

"utility": {
            "git": "github.com/org/Utilities",
            "ref": "commit-id"
 }

Steps to replicate

  1. Create a pip file with any private Github repo as a package
  2. Run below command
    pipenv install --dev

Output

Installing dependencies from Pipfile.lock (38058a)...
: ERROR: Invalid requirement: 'utility@ git+github.com/org/Utilities@commit-id' (from line 1 of /tmp/pipenv-dntff654-requirements/pipenv-ig2fc_8d-reqs.txt)
: Hint: It looks like a path. File 'utility@ git+github.com/org/Utilities@commit-id' does not exist.
ERROR: Couldn't install package: [1m{}[0m
@julio-tl
Copy link

+1

@matteius matteius added the Type: Regression This issue is a regression of a previous behavior. label Sep 25, 2024
@matteius
Copy link
Member

Could you help check on #6257 to see if it resolves the problem?

@julio-tl
Copy link

Hi @matteius #6257 worked for me, thanks for looking into this

@matteius matteius added the PR: awaiting-review The PR related to this issue is awaiting review by a maintainer. label Sep 27, 2024
achim-k pushed a commit to foxglove/ws-protocol that referenced this issue Sep 30, 2024
Bumps [pipenv](https://github.com/pypa/pipenv) from 2024.0.3 to
2024.1.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/pypa/pipenv/releases">pipenv's
releases</a>.</em></p>
<blockquote>
<h2>Release v2024.1.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Vendor in Pip 24.1.2 by <a
href="https://github.com/matteius"><code>@​matteius</code></a> in <a
href="https://redirect.github.com/pypa/pipenv/pull/6253">pypa/pipenv#6253</a></li>
<li>Preserve uncleaned VCS URL in the lock file. by <a
href="https://github.com/matteius"><code>@​matteius</code></a> in <a
href="https://redirect.github.com/pypa/pipenv/pull/6257">pypa/pipenv#6257</a></li>
<li>Make this code path more safe to prevent stack trace/regression. by
<a href="https://github.com/matteius"><code>@​matteius</code></a> in <a
href="https://redirect.github.com/pypa/pipenv/pull/6261">pypa/pipenv#6261</a></li>
<li>Update get-pipenv.py by <a
href="https://github.com/oz123"><code>@​oz123</code></a> in <a
href="https://redirect.github.com/pypa/pipenv/pull/6260">pypa/pipenv#6260</a></li>
<li>Fix new vcs test on Windows by <a
href="https://github.com/matteius"><code>@​matteius</code></a> in <a
href="https://redirect.github.com/pypa/pipenv/pull/6262">pypa/pipenv#6262</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/pypa/pipenv/compare/v2024.0.3...v2024.1.0">https://github.com/pypa/pipenv/compare/v2024.0.3...v2024.1.0</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pypa/pipenv/blob/main/CHANGELOG.md">pipenv's
changelog</a>.</em></p>
<blockquote>
<h1>2024.1.0 (2024-09-29)</h1>
<h1>Pipenv 2024.1.0 (2024-09-29)</h1>
<h2>Features &amp; Improvements</h2>
<ul>
<li>Upgrade from <code>pip==24.0</code> to <code>pip==24.1.2</code>.
<code>[#6253](pypa/pipenv#6253)
&lt;https://github.com/pypa/pipenv/issues/6253&gt;</code>_</li>
</ul>
<h2>Bug Fixes</h2>
<ul>
<li>Fixes regression in lock file generation that caused environment
variable references (e.g., ${GIT_PASSWORD}) in VCS URLs to be stripped
out. This restores the ability to use credential placeholders in version
control system URLs.
<code>[#6256](pypa/pipenv#6256)
&lt;https://github.com/pypa/pipenv/issues/6256&gt;</code>_</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/pypa/pipenv/commit/2b9c78aff7a1120cb68c65d1777dd9001bf12ed2"><code>2b9c78a</code></a>
Release v2024.1.0</li>
<li><a
href="https://github.com/pypa/pipenv/commit/3a16980e93fcc6068bd3eb3674bfa8b64b78d64d"><code>3a16980</code></a>
Bumped version to 2024.1.0.</li>
<li><a
href="https://github.com/pypa/pipenv/commit/9d7dc56dede01c0cdde4a86dc37a49e7f35b5379"><code>9d7dc56</code></a>
don't try to bump to dev version during pypi publish.</li>
<li><a
href="https://github.com/pypa/pipenv/commit/89fd2656f81b73106ea3258dd15187611d69737f"><code>89fd265</code></a>
Merge pull request <a
href="https://redirect.github.com/pypa/pipenv/issues/6262">#6262</a>
from pypa/fix-ci-vcs</li>
<li><a
href="https://github.com/pypa/pipenv/commit/2651f9943de577f48ce4d6f58cc91fd4c410dc8c"><code>2651f99</code></a>
Fix tests for windows and leave behavior for mac/linux</li>
<li><a
href="https://github.com/pypa/pipenv/commit/cbcd06c4f9d9834e80da01a0658d5385fd74bf69"><code>cbcd06c</code></a>
Fix test on windows</li>
<li><a
href="https://github.com/pypa/pipenv/commit/d9e6dfe80b3337141b0d82800a8e5981a3ee6c77"><code>d9e6dfe</code></a>
Merge pull request <a
href="https://redirect.github.com/pypa/pipenv/issues/6260">#6260</a>
from pypa/fix-get-pipenv</li>
<li><a
href="https://github.com/pypa/pipenv/commit/7d2220071927b6aefed43081c0a9384d20e826e7"><code>7d22200</code></a>
ruff: ignore get-pipenv.py</li>
<li><a
href="https://github.com/pypa/pipenv/commit/e1866a9e263a1ba447fe5186255912d42e2a560b"><code>e1866a9</code></a>
Update get-pipenv.py</li>
<li><a
href="https://github.com/pypa/pipenv/commit/fa08ff5fc4141fd15ac8d6da84751f9a4c5344b4"><code>fa08ff5</code></a>
Make this code path more safe to prevent stack trace/regression.</li>
<li>Additional commits viewable in <a
href="https://github.com/pypa/pipenv/compare/v2024.0.3...v2024.1.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pipenv&package-manager=pip&previous-version=2024.0.3&new-version=2024.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: awaiting-review The PR related to this issue is awaiting review by a maintainer. Type: Regression This issue is a regression of a previous behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants