← Về thư mục
tests/test_orchestration_reconciler.py
- _Store · class · L40-L106 — class _Store
- init · method · L44-L47 — def init(self) -> None
- add · method · L49-L51 — def add(self, workload: Workload) -> Workload
- workloads_needing_attention · method · L53-L54 — def workloads_needing_attention(self)
- get_workload · method · L56-L57 — def get_workload(self, workload_id: str)
- get_allocation · method · L59-L60 — def get_allocation(self, allocation_id: str)
- active_allocation · method · L62-L71 — def active_allocation(self, workload_id: str)
- create_allocation · method · L73-L81 — def create_allocation(self, workload_id: str, epoch: int) -> Allocation
- save_allocation · method · L83-L85 — def save_allocation(self, allocation: Allocation) -> None
- save_workload · method · L87-L88 — def save_workload(self, workload: Workload) -> None
- save_allocation_and_workload · method · L90-L95 — def save_allocation_and_workload( self, allocation: Allocation, workload: Workload ) -> None
- open_recovery_epoch · method · L97-L106 — def open_recovery_epoch(self, allocation: Allocation, workload: Workload) -> None
- _FakeBackend · class · L109-L141 — class _FakeBackend
- init · method · L114-L120 — def init(self) -> None
- submit · method · L122-L126 — def submit(self, *, allocation, spec, profile)
- observe · method · L128-L131 — def observe(self, allocation)
- cancel · method · L133-L134 — def cancel(self, allocation, *, reason)
- find_by_token · method · L136-L138 — def find_by_token(self, token)
- diagnostics · method · L140-L141 — def diagnostics(self)
- _AcknowledgingFakeBackend · class · L144-L157 — class _AcknowledgingFakeBackend(_FakeBackend)
- init · method · L147-L150 — def init(self) -> None
- terminal_acknowledgement_candidates · method · L152-L153 — def terminal_acknowledgement_candidates(self) -> tuple[str, ...]
- acknowledge_terminal · method · L155-L157 — def acknowledge_terminal(self, allocation: Allocation) -> None
- _workload · function · L160-L166 — def _workload(**kwargs) -> Workload
- _reconciler · function · L169-L172 — def _reconciler(store, backend, **kwargs) -> Reconciler
- test_a_workload_is_submitted_then_advanced_to_terminal · function · L178-L195 — def test_a_workload_is_submitted_then_advanced_to_terminal()
- test_one_submission_per_workload_even_across_many_ticks · function · L198-L205 — def test_one_submission_per_workload_even_across_many_ticks()
- test_a_rejection_fails_the_workload_with_its_reason · function · L208-L217 — def test_a_rejection_fails_the_workload_with_its_reason()
- test_unknown_submission_is_never_retried_blindly · function · L223-L242 — def test_unknown_submission_is_never_retried_blindly()
- test_unknown_then_nothing_found_submits_once_more · function · L245-L257 — def test_unknown_then_nothing_found_submits_once_more()
- test_repeated_unknowns_never_accumulate_submissions · function · L260-L273 — def test_repeated_unknowns_never_accumulate_submissions()
- test_backend_unavailable_does_not_move_the_phase · function · L279-L291 — def test_backend_unavailable_does_not_move_the_phase()
- test_cancel_barrier_runs_in_order_and_reaches_terminal · function · L297-L311 — def test_cancel_barrier_runs_in_order_and_reaches_terminal()
- test_cancel_barrier_is_reentrant_when_the_backend_lags · function · L314-L332 — def test_cancel_barrier_is_reentrant_when_the_backend_lags()
- test_a_releasing_allocation_still_counts_as_active · function · L335-L352 — def test_a_releasing_allocation_still_counts_as_active()
- test_cancelling_an_allocation_that_was_never_placed_terminates · function · L355-L370 — def test_cancelling_an_allocation_that_was_never_placed_terminates()
- test_cancelling_an_unknown_submission_asks_before_concluding · function · L373-L391 — def test_cancelling_an_unknown_submission_asks_before_concluding()
- test_cancelling_a_workload_with_no_allocation_is_immediate · function · L394-L401 — def test_cancelling_a_workload_with_no_allocation_is_immediate()
- test_recovery_is_a_new_epoch_not_a_rewrite · function · L407-L452 — def test_recovery_is_a_new_epoch_not_a_rewrite()
- test_recovery_never_commits_the_dead_allocation_before_the_epoch_bump · function · L455-L511 — def test_recovery_never_commits_the_dead_allocation_before_the_epoch_bump(tmp_path)
- _FailFirstRecoveryCommit · class · L475-L486 — class _FailFirstRecoveryCommit
- init · method · L476-L478 — def init(self, delegate)
- getattr · method · L480-L481 — def getattr(self, name)
- open_recovery_epoch · method · L483-L486 — def open_recovery_epoch(self, dead, recovering)
- test_a_batch_terminal_transition_is_one_database_commit · function · L514-L565 — def test_a_batch_terminal_transition_is_one_database_commit(tmp_path)
- _FailFirstPair · class · L535-L546 — class _FailFirstPair
- init · method · L536-L538 — def init(self, delegate)
- getattr · method · L540-L541 — def getattr(self, name)
- save_allocation_and_workload · method · L543-L546 — def save_allocation_and_workload(self, observed, parent)
- test_one_broken_workload_does_not_stop_the_others · function · L571-L586 — def test_one_broken_workload_does_not_stop_the_others()
- _Exploding · class · L572-L576 — class _Exploding(_FakeBackend)
- submit · method · L573-L576 — def submit(self, *, allocation, spec, profile)
- test_the_loop_survives_a_tick_that_raises · function · L589-L604 — def test_the_loop_survives_a_tick_that_raises(monkeypatch)
- _boom · function · L594-L596 — def _boom()
- local_backend · function · L611-L616 — def local_backend(tmp_path)
- _local_workload · function · L619-L628 — def _local_workload(command) -> Workload
- _drive_to_terminal · function · L631-L640 — def _drive_to_terminal(rec, store, workload, *, timeout_s=10.0)
- _wait_local_terminal · function · L643-L650 — def _wait_local_terminal(backend, allocation, *, timeout_s=10.0)
- test_local_backend_runs_a_real_process_to_completion · function · L653-L659 — def test_local_backend_runs_a_real_process_to_completion(local_backend)
- test_local_backend_reports_a_nonzero_exit_as_failure · function · L662-L668 — def test_local_backend_reports_a_nonzero_exit_as_failure(local_backend)
- test_local_supervisor_preserves_a_sigkill_exit · function · L671-L699 — def test_local_supervisor_preserves_a_sigkill_exit(local_backend)
- test_local_backend_cancels_a_running_process · function · L702-L715 — def test_local_backend_cancels_a_running_process(local_backend)
- test_local_backend_cancels_descendants_after_the_leader_exits · function · L718-L755 — def test_local_backend_cancels_descendants_after_the_leader_exits(local_backend)
- test_local_backend_honours_the_token_like_a_cluster_does · function · L758-L779 — def test_local_backend_honours_the_token_like_a_cluster_does(local_backend)
- test_local_backend_refuses_beyond_its_concurrency_bound · function · L782-L815 — def test_local_backend_refuses_beyond_its_concurrency_bound(tmp_path)
- test_local_backend_does_not_leak_the_daemon_environment · function · L818-L851 — def test_local_backend_does_not_leak_the_daemon_environment(local_backend, tmp_path)
- test_restart_adopts_a_live_local_receipt_instead_of_resubmitting · function · L854-L889 — def test_restart_adopts_a_live_local_receipt_instead_of_resubmitting(tmp_path)
- test_spawn_before_arm_is_stopped_before_retry_and_runs_user_code_once · function · L892-L939 — def test_spawn_before_arm_is_stopped_before_retry_and_runs_user_code_once( tmp_path, monkeypatch )
- crash_after_prepared · function · L901-L904 — def crash_after_prepared(path, receipt)
- test_crash_after_running_receipt_before_handle_adopts_the_same_process · function · L942-L983 — def test_crash_after_running_receipt_before_handle_adopts_the_same_process( tmp_path, monkeypatch )
- crash_before_handle · function · L950-L953 — def crash_before_handle(path, process)
- test_restart_never_trusts_a_live_numeric_group_without_launch_identity · function · L986-L1052 — def test_restart_never_trusts_a_live_numeric_group_without_launch_identity(tmp_path)
- test_a_fast_terminal_job_remains_discoverable_by_token_after_restart · function · L1055-L1092 — def test_a_fast_terminal_job_remains_discoverable_by_token_after_restart(tmp_path)
- test_many_fast_terminal_receipts_are_reclaimed_after_durable_restart · function · L1095-L1164 — def test_many_fast_terminal_receipts_are_reclaimed_after_durable_restart(tmp_path)
- test_uncommitted_fast_terminal_receipt_survives_restart_until_pair_commit · function · L1167-L1221 — def test_uncommitted_fast_terminal_receipt_survives_restart_until_pair_commit( tmp_path, )
- test_terminal_acknowledgement_refuses_a_still_live_local_group · function · L1224-L1251 — def test_terminal_acknowledgement_refuses_a_still_live_local_group(tmp_path)
- test_restart_finishes_a_crash_after_terminal_ack_marker · function · L1254-L1298 — def test_restart_finishes_a_crash_after_terminal_ack_marker(tmp_path, monkeypatch)
- crash_after_ack_rename · function · L1280-L1283 — def crash_after_ack_rename(ack_path)
- test_an_armed_but_unconfirmed_launch_keeps_the_known_process · function · L1301-L1329 — def test_an_armed_but_unconfirmed_launch_keeps_the_known_process(tmp_path, monkeypatch)
- lose_confirmation · function · L1316-L1318 — def lose_confirmation(path, process)
- test_a_corrupt_post_arm_receipt_returns_unknown_with_its_token · function · L1332-L1361 — def test_a_corrupt_post_arm_receipt_returns_unknown_with_its_token( tmp_path, monkeypatch )
- corrupt_confirmation · function · L1349-L1352 — def corrupt_confirmation(path, process)
- test_a_corrupt_receipt_makes_token_absence_unknown · function · L1364-L1386 — def test_a_corrupt_receipt_makes_token_absence_unknown(tmp_path)
- test_a_running_receipt_cannot_authorize_a_different_process_group · function · L1389-L1419 — def test_a_running_receipt_cannot_authorize_a_different_process_group(tmp_path)
- test_an_untracked_allocation_is_lost_not_completed · function · L1422-L1434 — def test_an_untracked_allocation_is_lost_not_completed(local_backend)
- test_a_reconciler_save_cannot_overwrite_a_users_cancel · function · L1440-L1478 — def test_a_reconciler_save_cannot_overwrite_a_users_cancel(tmp_path)