Skip to content

TypeScript Package #31

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 28 commits into from
Closed

TypeScript Package #31

wants to merge 28 commits into from

Conversation

@PaulRBerg PaulRBerg force-pushed the tsc-package branch 3 times, most recently from 1557c6d to c7ebd8f Compare April 30, 2025 06:46
@PaulRBerg PaulRBerg force-pushed the tsc-package branch 4 times, most recently from c76d52f to 58d6524 Compare May 19, 2025 16:28
@PaulRBerg PaulRBerg force-pushed the tsc-package branch 6 times, most recently from 0aa3ff6 to eef2799 Compare May 25, 2025 13:39
@PaulRBerg PaulRBerg marked this pull request as ready for review May 25, 2025 13:39
@PaulRBerg
Copy link
Member Author

The PR is finally ready for review, @sablier-labs/evm!

We should hop on a call to discuss next week. Feel free to book a time in my Calendly.

@smol-ninja
Copy link
Member

Well done. I have booked for Tuesday afternoon.

PaulRBerg added 8 commits May 26, 2025 18:34
chore: more comments
chore: remove unneeded fields in tsconfig
feat: more aliases in justfile
feat: script for printing chains
fix: fix addresses for Sophon
refactor: rename scripts
test: rename functions
PaulRBerg added 5 commits June 3, 2025 21:30
docs: draft README and CONTRIBUTING guide
refactor: rename queries to sablier
refactor: fewer default exports
build: add "viem" as dependency
build: move build-only settings to "tsconfig.build.json"
refactor: export mainnets before testnets
refactor: get rid of "logAndThrow"
refactor: move release-specific helpers
refactor: move "logger" and "check-broadcast" to "src/internal"
refactor: non-default exports
refactor: rename "scripts" to "cli"
refactor: simplify logic in "resolvers.ts"
@smol-ninja
Copy link
Member

Since, its very difficult to post comments on the diff, I will post some of them here (which requires discussion) and the rest can be seen in my PR: #41.

Its not a good idea to emit the entire periphery deployment under airdrops repo. Between SABLIER_V2_BATCH and SABLIER_V2_MERKLE_STREAMER_FACTORY, only the latter should be a part of the airdrops release whereas SABLIER_V2_BATCH should be part of the lockup release. We can fix it by refactoring as the following:

    core: {
      [manifest.core.SABLIER_V2_COMPTROLLER]: "0x17Ec73692F0aDf7E7C554822FBEAACB4BE781762",
      [manifest.core.SABLIER_V2_LOCKUP_DYNAMIC]: ["0xf390cE6f54e4dc7C5A5f7f8689062b7591F7111d", 161_612_601],
      [manifest.core.SABLIER_V2_LOCKUP_LINEAR]: ["0xFDD9d122B451F549f48c4942c6fa6646D849e8C1", 161_611_816],
      [manifest.core.SABLIER_V2_NFT_DESCRIPTOR]: "0x2fb103fC853b2F5022a840091ab1cDf5172E7cfa",
      [manifest.periphery.SABLIER_V2_BATCH]: "0xAFd1434296e29a0711E24014656158055F00784c",
    },
    periphery: {
      [manifest.periphery.SABLIER_V2_MERKLE_STREAMER_FACTORY]: [
        "0x237400eF5a41886a75B0e036228221Df075b3B80",
        161_026_555,
      ],

If you agree with this, lmk and I will be happy to make this change in my review PR.

PaulRBerg added 5 commits June 9, 2025 19:32
build: move decorator settings in tsconfig
chore: ignore node_modules in biome config
chore: ignore empty message logs in winston
refactor: refactor "logInfo" and "logVerbose" into "log"
fix: fix circular dependency
@PaulRBerg
Copy link
Member Author

PaulRBerg commented Jun 10, 2025

Its not a good idea to emit the entire periphery deployment under airdrops repo

Ah, great observation — I don't agree with the fix, though.

What we should do is convert the LockupV1 release into a Standard release. I'll handle it on my branch directly.

edit: wait, I don't think I see any bug here. We are only looking for the factories:

function filterByTestnet(isTestnet: boolean): Sablier.Deployment[] {
return _.filter(deployments, (deployment) => {
const chain = chainsQueries.get(deployment.chainId);
return (
chain?.isTestnet === isTestnet &&
_.some(deployment.periphery, { name: manifest.SABLIER_V2_MERKLE_STREAMER_FACTORY })
);
});
}

But maybe I misunderstood your point, @smol-ninja. Could you confirm?

smol-ninja and others added 2 commits June 10, 2025 12:33
* feat: recursive approach instead of hardcoding protocols
docs: natspec of deployment query
fix: reverts when only chainId is passed in getAll function
chore: adds missing rpc endpoints
fix: tangle native token
feat: adds missing parameters in CompilerSettings type
fix: invalid undefined return when flatMap is used
refactor: alphabetical order of Flow deployments
fix: incorrect isLatest value for older Airdrops deployments
fix: missing zksync broadcasts
script: default just recipe

* refactor: allow chainId in getAll

* refactor: simpler definition for catalog

---------

Co-authored-by: Paul Razvan Berg <[email protected]>
@smol-ninja
Copy link
Member

You are right. I misread that. All good now. Thanks.

@PaulRBerg PaulRBerg force-pushed the tsc-package branch 3 times, most recently from 237164d to 9ba4649 Compare June 10, 2025 15:53
@PaulRBerg
Copy link
Member Author

I was almost ready to merge this PR, but I realized that what I built is so different from what this repo was originally meant to be that I decided to put my work into a new repo called SDK:

https://github.com/sablier-labs/sdk

The package will be available on npm as sablier 🤩


Besides that, there is another benefit to creating a new repo (SDK) and archiving this repo (deployments):

Backward-compatibility with the links we have shared over time, e.g. in the docs, we use the main branch as a re instead of a particular git commit ref. See an example here).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants