Amit Kumar Ojha
6af5cc7d0b
easyenv: add test coverage for typed env var getters ( #1749 )
...
## Summary
easyenv had no test coverage for boolean, num, string, or duration
getters, despite being used across every service and job in the
workspace. adds 34 tests covering the optional/required/or_default triad
for each type.tests use unique env var names per test instead of adding
`serial_test` dev-dep — `env::set_var` is process-global so cargo's
default parallel execution can race. cleanup via a `Drop` guard
(`EnvVarGuard`, in `tests_common.rs`) so a panicking test doesn't leak
state into its neighbors.
## follow-up
left `pathbuf.rs` for a separate PR — it depends on
`storyteller_root::get_substituted_path` which needs more setup than
belongs in this diff.
## behaviors these tests pin down but don't change
- boolean parsing only accepts `true` / `TRUE` / `false` / `FALSE` —
`"1"`, `"0"`, `"yes"`, `"no"` return `ParseError`
- duration parses whole seconds only, no `"5s"` style suffixes
worth flagging in case either is intentional and someone wants to loosen
these separately.
## verification
- `cargo test --package easyenv --test-threads=8` — 34/34 pass, no
flakes across 20 consecutive runs
- `cargo clippy --package easyenv -- -D warnings` — clean
2026-07-08 16:30:43 -04:00
Brandon Thomas
27cc125089
trace id logging ( #1725 )
2026-07-03 02:28:22 -04:00
Brandon Thomas
64d66aa9f0
Batched Seedance 2.0 Job Polling ( #1214 )
2026-03-24 17:20:31 -04:00
Brandon Thomas
2063434304
centralized dependency configuration ( #1169 )
2026-03-18 21:45:42 -04:00
Brandon Thomas
8845b177be
rename workspace hack
2025-04-09 20:39:36 -04:00
Brandon Thomas
ce0448edca
move rust code back to root directory
2025-02-11 21:58:04 -05:00
Brandon Thomas
495b161cae
move storyteller-rust files into subdir for merge
2025-02-11 21:09:22 -05:00
Brandon Thomas
5599ce2383
fix backfill query, improve logging
2024-09-03 00:25:14 -04:00
Brandon Thomas
826d710979
more package upgrades
2024-06-16 14:17:08 -04:00
dependabot[bot]
eb68ab54c4
Bump env_logger from 0.10.1 to 0.10.2 ( #341 )
...
Bumps [env_logger](https://github.com/rust-cli/env_logger ) from 0.10.1
to 0.10.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-cli/env_logger/releases ">env_logger's
releases</a>.</em></p>
<blockquote>
<h2>v0.10.2</h2>
<h2>What's Changed</h2>
<ul>
<li>refactor: Move impls next to types by <a
href="https://github.com/epage "><code>@epage</code></a> in <a
href="https://redirect.github.com/rust-cli/env_logger/pull/283 ">rust-cli/env_logger#283</a></li>
<li>chore(deps): update github/codeql-action action to v3 by <a
href="https://github.com/renovate "><code>@renovate</code></a> in <a
href="https://redirect.github.com/rust-cli/env_logger/pull/292 ">rust-cli/env_logger#292</a></li>
<li>chore(deps): update actions/setup-python action to v5 by <a
href="https://github.com/renovate "><code>@renovate</code></a> in <a
href="https://redirect.github.com/rust-cli/env_logger/pull/291 ">rust-cli/env_logger#291</a></li>
<li>fix(fmt): Address a couple of bugs by <a
href="https://github.com/epage "><code>@epage</code></a> in <a
href="https://redirect.github.com/rust-cli/env_logger/pull/296 ">rust-cli/env_logger#296</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-cli/env_logger/compare/v0.10.1...v0.10.2 ">https://github.com/rust-cli/env_logger/compare/v0.10.1...v0.10.2 </a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-cli/env_logger/blob/main/CHANGELOG.md ">env_logger's
changelog</a>.</em></p>
<blockquote>
<h2>[0.10.2] - 2024-01-18</h2>
<h3>Performance</h3>
<ul>
<li>Avoid extra UTF-8 validation performed in some cases</li>
</ul>
<h3>Fixes</h3>
<ul>
<li>Ensure custom pipes/stdout get flushed</li>
<li>Don't panic on broken pipes when <code>color</code> is disabled</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/rust-cli/env_logger/commit/7929b7fc3df3223320c3cdd346138965f2c7e52f "><code>7929b7f</code></a>
chore: Release env_logger version 0.10.2</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/3df552c315f00f4bce6e8dfd7b0ab56210e8a74b "><code>3df552c</code></a>
docs: Update changelog</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/6ec4104864ed6bf6694988d30611ee736d2dcb5e "><code>6ec4104</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-cli/env_logger/issues/296 ">#296</a>
from epage/refactor</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/939687dd75b606186989aa72fe43e716eaca5659 "><code>939687d</code></a>
style: Make clippy happy</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/c088820ae84318077e5a37a3bed6d20b3f7aa3f3 "><code>c088820</code></a>
fix(fmt): Ensure stream gets flushed</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/2b3f26fc29952296fdf79fa43d5beb35ddacbf40 "><code>2b3f26f</code></a>
perf(fmt): Avoid UTF-8 validation</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/7428386da32c2a78b80f7e67a04b5fd5449601d5 "><code>7428386</code></a>
refactor(fmt): Pull out stream lookup from write</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/e8674a237b62460b6dbc4ed8d8b48b6db0a97de4 "><code>e8674a2</code></a>
refactor(fmt): Consolidate target printing</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/f5f3392886cb3f2a1a3180122666fa40a2150efe "><code>f5f3392</code></a>
refactor(fmt): Pull is_test into the target</li>
<li><a
href="https://github.com/rust-cli/env_logger/commit/87008fdf78b861202ca9da4869475649e72b8e82 "><code>87008fd</code></a>
fix(fmt): Don't panic on broken pipes without termcolor</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-cli/env_logger/compare/v0.10.1...v0.10.2 ">compare
view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores )
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
</details>
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-15 21:07:53 -04:00
Brandon Thomas
e440a338b3
unused dependencies
2024-05-16 08:23:42 -07:00
Brandon Thomas
97a3310b59
cleanup imports
2024-05-16 07:04:48 -07:00
Brandon Thomas
8d22697855
better environment variable errors
2024-01-28 03:36:17 -05:00
Brandon Thomas
e18b86a55a
everything needs to refer to workplace-hack
2023-12-08 01:25:49 -05:00
Brandon Thomas
8a6678c7f5
move workspace-hack under crates/
2023-12-06 02:12:57 -05:00
dependabot[bot]
456b9e1ce6
Bump env_logger from 0.7.1 to 0.10.1
...
Bumps [env_logger](https://github.com/rust-cli/env_logger ) from 0.7.1 to 0.10.1.
- [Release notes](https://github.com/rust-cli/env_logger/releases )
- [Changelog](https://github.com/rust-cli/env_logger/blob/main/CHANGELOG.md )
- [Commits](https://github.com/rust-cli/env_logger/compare/v0.7.1...v0.10.1 )
---
updated-dependencies:
- dependency-name: env_logger
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com >
2023-11-30 09:35:18 +00:00
kasisnu
2eb5635c58
removing some unused creates
2023-11-14 12:31:37 +05:30
Brandon Thomas
26794b3d2e
CLI tool to upload media files and save them to the DB
2023-10-19 21:52:32 -04:00
Brandon Thomas
9e0bee8fba
Substitute config absolute paths with magic substitution strings
2023-10-17 21:37:20 -04:00
Brandon Thomas
3fc0f45942
"storyteller root" directory in development
2023-10-17 21:04:54 -04:00
Brandon Thomas
1ef7ae1009
Better env var support
2023-10-17 16:31:53 -04:00
Brandon Thomas
83dc262249
make lints and tests pass again
2023-09-26 02:13:16 -04:00
Brandon Thomas
1d3885c367
vendor in easyenv.rs (a crate I wrote)
2023-09-26 02:03:25 -04:00