Skip to content

Fetch from EVE for cargo before / cargo after - #54

Merged
Fazorath merged 1 commit into
issue-38-cargo-runsfrom
issue-47-fetch-cargo
Oct 28, 2026
Merged

Fazorath merged 1 commit into
issue-38-cargo-runsfrom
issue-47-fetch-cargo

Conversation

@Fazorath

Copy link
Copy Markdown
Owner

Closes #47

Based on issue-38-cargo-runs (it holds #45 and #48, which aren't on main yet), so the diff is only this ticket. Retarget to main once that branch lands.

What

  • cargo.py: get_cargo(client, character_id) reads ship_item_id from the ship endpoint, follows asset paging, keeps only items with location_id = that ship and flag Cargo (ammo counts, blueprint copies out), prices them with the existing market price reader, counts unpriced types, passes ESI's fetched-at through. Malformed ship/asset/price bodies raise ValueError.
  • Abyss page: a Fetch from EVE button and status note under each of Cargo before / after. Success fills two decimals and reads "From EVE at HH:MM · N unpriced"; errors show in the critical colour and leave the field alone; signed out says to sign in.
  • tk.PhotoImage(master=self, ...) in the app icon: baseline fix, the wallet-page tests failed on Linux without it.

Tests

New test_cargo.py (reader against a fake ESI client) and test_cargo_fetch.py (GUI via gui.App, reader mocked). Full suite: 137 tests under xvfb, all pass except test_theme font load, which fails here only because this Linux box has no Chakra Petch font.

NOT DONE: real-data check

The criterion to confirm against a live character that the hold's flag is Cargo and location_id is the ship's item id is still open. It needs the Windows rig with a signed-in docked character, and the rig can't be reached from this session (no desktop access, SSH off). Don't merge until it is written up here.

@Fazorath

Copy link
Copy Markdown
Owner Author

Live Cargo-flag check not run: the PC is offline and the user won't set up access. Decision (DIS-169): accept the fixture-tested reader; the user confirms on first real use with a docked character. Note this PR is based on issue-38-cargo-runs, since #45/#48 aren't on main.

@Fazorath

Copy link
Copy Markdown
Owner Author

Merging into issue-38-cargo-runs. Linux and Windows CI pass on 3.10 and 3.13. Both macOS jobs never got a runner (no steps ran, 15-minute queue timeout, rerun queued again), so that's GitHub infra, not this code. The live Cargo-flag check is waived per DIS-169: the user confirms on first real use.

@Fazorath
Fazorath merged commit 1800e35 into issue-38-cargo-runs Oct 28, 2026
11 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant