Skip to content

[Fix] Include submission_template in resource_dict#956

Merged
jan-janssen merged 3 commits intomainfrom
resource_dict_submission_template
Mar 24, 2026
Merged

[Fix] Include submission_template in resource_dict#956
jan-janssen merged 3 commits intomainfrom
resource_dict_submission_template

Conversation

@jan-janssen
Copy link
Copy Markdown
Member

@jan-janssen jan-janssen commented Mar 24, 2026

Summary by CodeRabbit

  • New Features
    • Added acceptance and validation of a new optional submission_template field in resource validation so it’s no longer treated as unrecognized.
  • Tests
    • Updated unit test expectations to include submission_template among the recognized resource keys.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 24, 2026

Warning

Rate limit exceeded

@jan-janssen has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 12 minutes and 37 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 4ed80dd1-c3f4-4824-942b-ae42daef1954

📥 Commits

Reviewing files that changed from the base of the PR and between 931a790 and ea0036a.

📒 Files selected for processing (1)
  • tests/unit/standalone/test_validate.py
📝 Walkthrough

Walkthrough

Added an optional submission_template: Optional[str] field to the ResourceDictValidation model so validation now recognizes and parses this key instead of treating it as unrecognized.

Changes

Cohort / File(s) Summary
Validation Schema Updates
src/executorlib/standalone/validate.py
Added submission_template: Optional[str] = None to ResourceDictValidation, making the field accepted by validation and key-filtering logic.
Unit Test Update
tests/unit/standalone/test_validate.py
Updated test_get_accepted_keys expected keys to include submission_template, aligning tests with the new model field.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 A tiny field tucked in with care,
submission_template hops in the air.
No more surprises, no stray key fright,
Validation hums softly into the night. 🎋

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main change: adding submission_template field to the resource_dict validation model.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch resource_dict_submission_template

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@tests/unit/standalone/test_validate.py`:
- Around line 60-62: The list literal that currently contains the adjacent
string literals "slurm_cmd_args" "submission_template" must include a trailing
comma after "slurm_cmd_args" to prevent implicit string concatenation; update
the list so the two entries are separate elements by adding the missing comma
(fix the list that includes "slurm_cmd_args" and "submission_template" in the
failing test).

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 0e284019-5f23-43b8-8ffe-c76f2c2dfeb3

📥 Commits

Reviewing files that changed from the base of the PR and between 1abf979 and 931a790.

📒 Files selected for processing (1)
  • tests/unit/standalone/test_validate.py

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.14%. Comparing base (1d13f5c) to head (ea0036a).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #956   +/-   ##
=======================================
  Coverage   94.14%   94.14%           
=======================================
  Files          39       39           
  Lines        2082     2083    +1     
=======================================
+ Hits         1960     1961    +1     
  Misses        122      122           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jan-janssen jan-janssen merged commit 837f48c into main Mar 24, 2026
36 checks passed
@jan-janssen jan-janssen deleted the resource_dict_submission_template branch March 24, 2026 19:12
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