Skip to content

fix(quickstart): add -p flag to avoid error from missing PostgreSQL#1006

Open
brunoguerios wants to merge 3 commits into
propeller-heads:mainfrom
brunoguerios:fix/quickstart-libpq-linker-error
Open

fix(quickstart): add -p flag to avoid error from missing PostgreSQL#1006
brunoguerios wants to merge 3 commits into
propeller-heads:mainfrom
brunoguerios:fix/quickstart-libpq-linker-error

Conversation

@brunoguerios

@brunoguerios brunoguerios commented May 11, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Running cargo run --release --example quickstart from the workspace root fails with ld: library 'pq' not found on machines without PostgreSQL installed
  • Cargo resolves the full workspace graph, pulling pq-sysdieseltycho-storage/tycho-indexer into the link step even though the quickstart has no database dependency
  • Fix: add -p tycho-simulation to all documented commands so the build is scoped to that crate's dependency tree, which does not include pq-sys

Alternative considered

  • Documenting brew install postgresql / apt install postgresql as a prerequisite. Rejected because the quickstart targets simulation consumers (solver/routing developers) who will never run the indexer and have no reason to install a PostgreSQL client. The -p flag is also the semantically correct Cargo idiom for building a single workspace member.

Also includes

  • Added TYCHO_API_KEY to all code blocks — it was previously undocumented, causing a confusing Invalid authentication key error on first run

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@brunoguerios brunoguerios changed the title fix(quickstart): add -p flag to avoid libpq linker error from workspace deps fix(quickstart): add -p flag to avoid error from missing PostgreSQL May 11, 2026

@zizou0x zizou0x left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch! LGTM, thanks!

@github-project-automation github-project-automation Bot moved this from Todo to In Progress in Tycho May 12, 2026
@brunoguerios

Copy link
Copy Markdown
Contributor Author

Hey @zizou0x - thanks for reviewing it!
I brought the branch up to date with latest changes on main, so it's ready to be merged ✅
Even though you approved the changes, seems that a few workflows are still pending.
Let me know if there's anything else you require from me to get this through or if you'll take it from here.
Cheers 🍻

@zizou0x zizou0x enabled auto-merge May 19, 2026 11:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

2 participants