Skip to content

Document all supported environment variables in the example app README#332

Merged
0xNgoo merged 2 commits into
0xNgoo:mainfrom
ikemHood:docs/example-env-vars-273
Jul 1, 2026
Merged

Document all supported environment variables in the example app README#332
0xNgoo merged 2 commits into
0xNgoo:mainfrom
ikemHood:docs/example-env-vars-273

Conversation

@ikemHood

Copy link
Copy Markdown
Contributor

What does this PR do?

Updates the example app README to document every environment variable read by example/express-app.ts, as a table with the current default for each. Defaults match the example app code.

How to test?

bun run test — new example README documents all env vars suite asserts each env var read by the example app is listed.

Checklist

  • My code follows the code style of this project.
  • I have added tests for my changes.
  • I have updated the documentation accordingly.
  • I have run bun run test and bun run lint locally.

Issue Reference

Closes #273

@drips-wave

drips-wave Bot commented Jun 29, 2026

Copy link
Copy Markdown

@ikemHood Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@gemini-code-assist gemini-code-assist 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.

Code Review

This pull request updates the example/README.md to document all environment variables in a structured table format and introduces a new test suite (tests/example-readme-env-vars.test.ts) to verify that all environment variables are documented. Feedback includes correcting a minor typo in the README and refactoring the test assertions to use regular expressions instead of exact string matches, preventing fragile test failures due to markdown auto-formatting.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread example/README.md Outdated
| `PORT` | `3000` | Port the example server listens on. Must be a positive number. |
| `DATABASE_URL` | `file:/tmp/anchor-kit-example-<uuid>.sqlite` | Database location. `file:...` selects SQLite; otherwise PostgreSQL. |
| `INTERACTIVE_DOMAIN` | `http://localhost:3000` | Interactive flow domain used by SEP-24. |
| `SEP10_SIGNING_KEY` | fresh random keypair | SEP-10 challenge signing secret. Regenerated on every start unset. |

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.

medium

There is a minor typo in the description: "Regenerated on every start unset." It should be "Regenerated on every start if unset." for better readability.

Suggested change
| `SEP10_SIGNING_KEY` | fresh random keypair | SEP-10 challenge signing secret. Regenerated on every start unset. |
| `SEP10_SIGNING_KEY` | fresh random keypair | SEP-10 challenge signing secret. Regenerated on every start if unset. |

Comment thread tests/example-readme-env-vars.test.ts Outdated
Comment on lines +29 to +31
expect(readme).toContain('| `PORT` | `3000` |');
expect(readme).toContain('| `CHALLENGE_EXPIRATION_SECONDS` | `300` |');
expect(readme).toContain('| `WATCHERS_ENABLED` | enabled |');

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.

medium

These assertions are highly fragile because they expect exact spacing in the Markdown table. If an auto-formatter (like Prettier) runs on README.md and aligns the table columns with extra spaces, these assertions will fail. Using regular expressions with \s* makes the test robust against formatting changes.

Suggested change
expect(readme).toContain('| `PORT` | `3000` |');
expect(readme).toContain('| `CHALLENGE_EXPIRATION_SECONDS` | `300` |');
expect(readme).toContain('| `WATCHERS_ENABLED` | enabled |');
expect(readme).toMatch(/\|\s*`PORT`\s*\|\s*`3000`\s*\|/);
expect(readme).toMatch(/\|\s*`CHALLENGE_EXPIRATION_SECONDS`\s*\|\s*`300`\s*\|/);
expect(readme).toMatch(/\|\s*`WATCHERS_ENABLED`\s*\|\s*enabled\s*\|/);

@0xNgoo 0xNgoo force-pushed the docs/example-env-vars-273 branch from cba0ff5 to 47582b6 Compare July 1, 2026 14:22
@0xNgoo 0xNgoo merged commit 85923ba into 0xNgoo:main Jul 1, 2026
1 check 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.

Document all supported environment variables in the example app README

2 participants