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

Replace deprecated pipenv lock with pipenv requirements #7764

Merged
merged 1 commit into from
Aug 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def generated_requirements_files(type)

# Find any requirement files that list the same dependencies as
# the (old) Pipfile.lock. Any such files were almost certainly
# generated using `pipenv lock -r`
# generated using `pipenv requirements`
requirements_files.select do |req_file|
deps = []
req_file.content.scan(regex) { deps << Regexp.last_match }
Expand Down Expand Up @@ -237,12 +237,12 @@ def post_process_lockfile(updated_lockfile_content)

def generate_updated_requirements_files
req_content = run_pipenv_command(
"pyenv exec pipenv lock -r"
"pyenv exec pipenv requirements"
)
File.write("req.txt", req_content)

dev_req_content = run_pipenv_command(
"pyenv exec pipenv lock -r -d"
"pyenv exec pipenv requirements --dev"
)
File.write("dev-req.txt", dev_req_content)
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@
context "with a requirements.txt" do
let(:dependency_files) { [pipfile, lockfile, requirements_file] }

context "that looks like the output of `pipenv lock -r`" do
context "that looks like the output of `pipenv requirements`" do
let(:pipfile_fixture_name) { "hard_names" }
let(:lockfile_fixture_name) { "hard_names.lock" }
let(:requirements_file) do
Expand Down Expand Up @@ -471,7 +471,7 @@
end
end

context "that looks like the output of `pipenv lock -r -d`" do
context "that looks like the output of `pipenv requirements --dev`" do
let(:requirements_file) do
Dependabot::DependencyFile.new(
name: "req-dev.txt",
Expand Down