-
Notifications
You must be signed in to change notification settings - Fork 21
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
Feat/workerize #96
base: development
Are you sure you want to change the base?
Feat/workerize #96
Conversation
Template init
…t-config feat: updated eslint to use flat-config file
This comment was marked as off-topic.
This comment was marked as off-topic.
Marked as off-topic because I was forward thinking things instead rather than for the npm package, my bad. |
…ility with PermitRequest
…er for improved clarity and consistency
This is the only important sentence to address before we can merge this and address the other problems in a separate PR
We could release a new major and we'd be safe no matter what I'm sure, I figured that's what we'd be doing. |
I think user id and wallet address should be passed in because we already fetch wallet address in |
I'm assuming you are talking about in regards to the npm package, but once permit generation is centralized to the worker I assume that it will be responsible for the user checks and pushing to the DB? Kept I haven't touched the |
I think if it can pass @whilefoo review it's fine. |
I ask again because ofc it's been highlighted through this PR that the spec wasn't clear as @whilefoo pointed out. This PR has sat for a long time with v little input or changes. Each new review is something else that's newly being considered for this feature. It's not right and it's not fair either. Can this be moved along, please? What ever else needs done or considered for this feature should be tasked out and a clear considered spec written for it. |
Different when your salaried, you don't mind if these situations occur because your still earning at the end of the day. You don't mind waiting for shit to be clarified and the team to get on the same page with things. When your just a contributor it's a completely different story. And situations like this need to be avoided and remedied quickly where it cannot be avoided. PRs/tasks like these are what I've seen make newer devs stop contributing within the ecosystem more than anything else. If this feature isn't due to be used or rolled out or whatever then merge to a feature branch without a new release. Whatever it is that needs done, can it be done please. |
@gentlementlegen perhaps you can bring it to the next step I think that the contribution dynamics will be normalized soon. It's part of the inspiration behind removing base pay. |
logger.info("Generating permit for: ", permitRequest); | ||
const { amount, userId, nonce, evmNetworkId, tokenAddress, type: permitType, userWalletAddress } = permitRequest; | ||
if (!userWalletAddress) { | ||
throw new Error(logger.error(`No userWalletAddress provided for permit request: ${JSON.stringify(permitRequest)}`).logMessage.raw); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can directly throw the logger.error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You have mentioned that before during this PR and I responded but you never replied. Idk if you had forgotten that we've spoken already or if this is you saying "regardless, these must be changed".
@@ -6,22 +6,13 @@ on: | |||
types: | |||
- completed | |||
|
|||
permissions: write-all | |||
|
|||
jobs: | |||
knip-reporter: | |||
runs-on: ubuntu-latest | |||
if: ${{ github.event.workflow_run.conclusion != 'success' }} | |||
steps: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can now replace gitcoindev/knip-reporter@main
with ubiquity/knip-reporter@main
x25519privateKey: string; | ||
}) { | ||
if (!userWalletAddress) { | ||
throw new Error(logger.error("ERC20 Permit generation error: Wallet not found").logMessage.raw); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can directly throw the logger error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Stop writing error in error messages. Also use warn instead of error unless it's something we'll need to triage later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return await tokenContract.decimals(); | ||
} catch (err) { | ||
const errorMessage = `Failed to get token decimals for token: ${tokenAddress}, ${err}`; | ||
logger.debug(errorMessage, { err }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can make this a one-liner and throw the logger error (should probably not be debug
)
contributionType: string; | ||
}) { | ||
if (!nftContractAddress) { | ||
throw new Error(logger.error("NFT Address not found").logMessage.raw); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this file it applies multiple time, same throw improvement can be made
nodeLinker: node-modules |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this can be deleted since we are using bun now
Co-authored-by: Mentlegen <9807008+gentlementlegen@users.noreply.github.com>
Co-authored-by: Mentlegen <9807008+gentlementlegen@users.noreply.github.com>
Co-authored-by: Mentlegen <9807008+gentlementlegen@users.noreply.github.com>
ty for review @gentlementlegen I'll implement these changes in the next hour and hopefully this can be merged today eh? Final word on the Is that reason being overruled and it should be updated to |
Resolves #92