The compose header teardown and `make down` leave profile services running (follow-up to #1285)

Đang mở
#1,287 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
74/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
docker, docker-compose, python, yaml
Lĩnh vực
devops, documentation, testing

Hướng nghiên cứu

Start with the docker-compose.yml profile declarations and the teardown commands in docker-compose.yml, Makefile, and the three getting-started pages mentioned through CONTRIBUTING.md. Update the regression test at backend/tests/unit/docs/test_demo_profile_command.py::test_the_header_and_the_two_pages_print_the_same_command to cover the header and all three pages. Done means each full-teardown command names exactly the demo, tools, and aws profiles, the regression test passes, docker compose config remains byte-identical, and the named-volume persistence assertions still hold.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug documentation post-launch

Follow-up to #1285. That issue fixes the three getting-started pages. Two more copies of the same teardown remain,
and they stay as they are in v0.36.1:

  • docker-compose.yml line 16, the header comment: docker compose down -v # stop and drop the volumes, directly
    under the header's --profile demo, --profile tools and --profile aws start lines.
  • Makefile lines 82-83, the down target: $(COMPOSE) down -v --remove-orphans, which CONTRIBUTING.md line 114
    documents as "Stop everything and drop the volumes", right under make demo.

Why --remove-orphans does not help

From Compose's source (v2.24.5 and v2.38.2): down removes containers only for the services in the loaded project, and
services whose profile is not enabled are "disabled", not absent. isOrphaned counts both enabled and disabled services
as defined, so a disabled-profile container is never an orphan. After make demo, make down leaves shoplab,
streampulse and both simulators running, with the same effects as in #1285.

Scope of the fix (one PR)

  • The header teardown and the down recipe name every profile; CONTRIBUTING.md line 114 becomes true.
  • A regression test (markers unit and regression, standard library only, no git) asserting that every documented
    full teardown names exactly the set of profiles declared in docker-compose.yml: the three pages' fenced
    docker compose … down lines, the header line and the Makefile recipe. The PR shows it failing on a page reverted to
    docker compose down -v and on a page without --profile aws.
  • backend/tests/unit/docs/test_demo_profile_command.py::test_the_header_and_the_two_pages_print_the_same_command is
    adjusted so that a header demo start line without the seeds still fails.
  • docker compose config is byte-identical before and after.
  • An assertion that the tools and aws services keep their data in named volumes, against which the pages' new
    "also deletes pgAdmin's and LocalStack's data" sentences are re-registered.

The regression test is deliberately not part of #1285's PR, so that v0.36.1 stays docs-only.

Ngôn ngữ chính
Python
Star
0
Fork
4
Merge trung bình
5 giờ 19 phút
Pull request đã merge (30 ngày)
503

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của Controlvar/controlvar

Tất cả issue của Controlvar/controlvar

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.