Regression-test `table(scheduled(at = col_name))` syntax

Open Beginner friendly
#3,120 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
68/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
rust
Domain
testing

Research direction

Locate the module-test module and inspect how scheduled tables and reducers are currently declared. Add a case using table(scheduled(at = col_name)), then build the module or run the relevant CI test to confirm the syntax is accepted and remains covered.

Written by the indexing model from the issue text.

Description

From our macro code:

let scheduled_at_column = scheduled_at_column.ok_or_else(|| {
    syn::Error::new(
        sched.span,
        "scheduled tables must have a `scheduled_at: spacetimedb::ScheduleAt` column. \
                 if the column has a name besides `scheduled_at`, you can specify it with \
                 `scheduled(my_reducer, at = custom_scheduled_at)`",
    )
})?;

This syntax, with the at = col_name parameter supplied, does not appear in our docs, and is not regression-tested.

Definition of Done

Add a use of this syntax to the module-test module so that it gets built in CI

Dominant language
Rust
Stars
25.2k
Forks
1.1k
Avg merge
2d 20h
Merged PRs (30d)
45

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from clockworklabs/SpacetimeDB

All issues in clockworklabs/SpacetimeDB

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.