Skip to content

feat: sprinkle to sub projects#12

Merged
jtourkos merged 3 commits into
mainfrom
splinke-to-sub-projects
Sep 1, 2025
Merged

feat: sprinkle to sub projects#12
jtourkos merged 3 commits into
mainfrom
splinke-to-sub-projects

Conversation

@jtourkos
Copy link
Copy Markdown
Contributor

@jtourkos jtourkos commented May 16, 2025

@jtourkos jtourkos requested review from Copilot and efstajas May 16, 2025 13:45
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces support for subprojects by sprinkling repository subaccount driver functionality across various modules, updating query table names, and refactoring project retrieval functions. Key changes include:

  • Adding the repoSubAccountDriver property to the Network type and getNetwork configuration.
  • Refactoring queries to use updated table names and consolidating split receiver queries.
  • Renaming and enhancing project query functions to include subproject data by calling a new contract method.

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/types.ts Added repoSubAccountDriver property to the Network type.
src/queries/getTokens.ts Updated table name formatting in token queries.
src/queries/getCurrentSplitsReceivers.ts Consolidated queries and mapping now always using fundeeProjectId.
src/queries/getAllProjectsSortedByCreationDate.ts Renamed function and added subproject-fetch logic via a contract call.
src/queries/getAllDripListsSortedByCreationDate.ts Updated table naming to follow the new naming convention.
src/index.ts Updated imports and usage to reflect the renamed project query.
src/getNetwork.ts Added repoSubAccountDriver addresses for supported networks.
src/contracts/*.ts Added new contract files supporting subaccount driver and removed duplication in drips-client.
Comments suppressed due to low confidence (2)

src/queries/getAllProjectsSortedByCreationDate.ts:10

  • [nitpick] The function name 'getAllProjectsAndSubProjectSortedByCreationDate' may be slightly inconsistent; consider using a plural form for subprojects (e.g. 'getAllProjectsAndSubProjectsSortedByCreationDate') for clarity.
export async function getAllProjectsAndSubProjectSortedByCreationDate(

src/queries/getCurrentSplitsReceivers.ts:28

  • The mapping now always uses 'fundeeProjectId' for building the splits receiver, which previously handled both 'dripList' and 'project' types separately. Confirm that the 'splits_receivers' table reliably contains 'fundeeProjectId' for all cases or adjust the mapping accordingly.
...splits.map(({fundeeProjectId, weight}) => ({

Comment thread src/queries/getAllProjectsSortedByCreationDate.ts
Comment thread src/queries/getAllProjectsSortedByCreationDate.ts Outdated
@railway-app
Copy link
Copy Markdown

railway-app Bot commented May 16, 2025

🚅 Previously deployed to Railway in the Drips App project. Environment has been deleted.

@jtourkos jtourkos requested a review from mhgbrown May 16, 2025 13:53
Copy link
Copy Markdown

@mhgbrown mhgbrown left a comment

Choose a reason for hiding this comment

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

Looking great!

@jtourkos jtourkos merged commit 35d3639 into main Sep 1, 2025
2 checks 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.

Make Sprinkler discover & split RepoSubAccountDriver accounts

3 participants