Skip to content
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

PLT-9008- Fix generated docs warnings #139

Merged
merged 7 commits into from
Dec 19, 2023
Merged

Conversation

hrajchert
Copy link
Collaborator

@hrajchert hrajchert commented Dec 19, 2023

This PR:

Summary by CodeRabbit

  • New Features

    • Introduced a new "Check docs generation" job in the CI workflow.
    • Expanded REST client functionality with additional exported entities for contract interactions and withdrawal processes.
  • Documentation

    • Improved inline documentation for better clarity in TypeScript and JavaScript usage.
  • Refactor

    • Modified package descriptions for enhanced understanding of endpoint functionalities.
  • Style

    • Adjusted comment placement for better code readability.

Copy link
Contributor

coderabbitai bot commented Dec 19, 2023

Warning

Rate Limit Exceeded

@hrajchert has exceeded the limit for the number of files or commits that can be reviewed per hour. Please wait 3 minutes and 14 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. 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.

Commits Files that changed from the base of the PR and between 5c7b4b2 and 8dbd99f.

Walkthrough

The recent update introduces a new job in the CI pipeline to check documentation generation, refines comments in TypeScript code, and expands the REST client's capabilities by adding new modules and exports. These enhancements include additional configurations, request types, and status entities to support contract and payout functionalities, as well as extending withdrawal capabilities with new endpoint modules.

Changes

File Path Change Summary
.github/workflows/test-suite.yaml Added a new CI job "Check docs generation".
packages/language/core/v1/src/index.ts Moved an explanatory comment inline with the associated code.
packages/runtime/client/rest/src/contract/index.ts Expanded exports with new configurations, request types, and contract-related entities.
packages/runtime/client/rest/src/payout/index.ts
packages/runtime/client/rest/src/withdrawal/index.ts
Exported new modules "collection.js" and "singleton.js" from the "endpoints" directory.

Poem

In the code's vast burrow, a new job does appear,
"Check docs," it commands, with a twitch of its ear.
Contracts and payouts, now spryly they hop,
🐇 With each new module, they joyfully bop.

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on X ?


Tips

Chat with CodeRabbit Bot (@coderabbitai)

  • You can reply to a review comment made by CodeRabbit.
  • You can tag CodeRabbit on specific lines of code or files in the PR by tagging @coderabbitai in a comment.
  • You can tag @coderabbitai in a PR comment and ask one-off questions about the PR and the codebase. Use quoted replies to pass the context for follow-up questions.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json

Copy link
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.

Review Status

Actionable comments generated: 0

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 25b9d50 and 9d68d8d.
Files ignored due to filter (1)
  • package.json
Files selected for processing (5)
  • .github/workflows/test-suite.yaml (1 hunks)
  • packages/language/core/v1/src/index.ts (1 hunks)
  • packages/runtime/client/rest/src/contract/index.ts (3 hunks)
  • packages/runtime/client/rest/src/payout/index.ts (1 hunks)
  • packages/runtime/client/rest/src/withdrawal/index.ts (1 hunks)
Files skipped from review due to trivial changes (1)
  • packages/language/core/v1/src/index.ts
Additional comments: 8
.github/workflows/test-suite.yaml (1)
  • 36-38: The new CI job "Check docs generation" is correctly defined and will run the documentation generation command. Ensure that the npm run docs command is properly set up to fail the CI job if any warnings are generated.
packages/runtime/client/rest/src/contract/index.ts (5)
  • 31-31: The addition of RoleTokenConfigurations to the exported entities is correctly implemented.

  • 49-49: The addition of ApplyInputsToContractRequest to the exported entities is correctly implemented.

  • 52-57: The addition of several entities related to contract sources and closures is correctly implemented.

  • 61-61: The addition of TxStatus to the exported entities is correctly implemented.

  • 62-62: The addition of GetNextStepsForContractRequest to the exported entities is correctly implemented.

packages/runtime/client/rest/src/payout/index.ts (1)
  • 4-5: The export of "collection.js" and "singleton.js" modules is correctly implemented.
packages/runtime/client/rest/src/withdrawal/index.ts (1)
  • 3-4: The export of "collection.js" and "singleton.js" modules is correctly implemented.

@hrajchert hrajchert force-pushed the PLT-9008-fix-doc-warnings branch from 9d68d8d to 63a3c2c Compare December 19, 2023 14:06
Copy link
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.

Review Status

Actionable comments generated: 0

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 25b9d50 and 63a3c2c.
Files ignored due to filter (2)
  • package.json
  • packages/language/examples/typedoc.json
Files selected for processing (8)
  • .github/workflows/test-suite.yaml (1 hunks)
  • changelog.d/20231219_104332_hrajchert_PLT_9008_fix_doc_warnings.md (1 hunks)
  • packages/language/core/v1/src/index.ts (1 hunks)
  • packages/language/examples/src/atomicSwap.ts (1 hunks)
  • packages/language/examples/src/playground-v1/escrow.ts (1 hunks)
  • packages/runtime/client/rest/src/contract/index.ts (3 hunks)
  • packages/runtime/client/rest/src/payout/index.ts (1 hunks)
  • packages/runtime/client/rest/src/withdrawal/index.ts (1 hunks)
Files skipped from review due to trivial changes (3)
  • .github/workflows/test-suite.yaml
  • packages/language/core/v1/src/index.ts
  • packages/runtime/client/rest/src/payout/index.ts
Files skipped from review as they are similar to previous changes (2)
  • packages/runtime/client/rest/src/contract/index.ts
  • packages/runtime/client/rest/src/withdrawal/index.ts
Additional comments: 3
changelog.d/20231219_104332_hrajchert_PLT_9008_fix_doc_warnings.md (1)
  • 1-3: The changelog entry succinctly captures the essence of the PR, clearly stating the issue addressed and the solution implemented.
packages/language/examples/src/atomicSwap.ts (1)
  • 73-74: The export of IReduce aligns with the PR's objective to refine public API exports. However, the initialization of iReduce as undefined is unconventional since TypeScript types are design-time constructs and do not exist at runtime. Verify if this is intentional and how it's meant to be used.
Verification successful

The search results indicate that iReduce is used as an input in the atomicSwap.ts file. Given that iReduce is initialized as undefined, it seems to be intentionally used to represent a void input within the context of this file.

Final response:

The IReduce type has been correctly exported, and the iReduce constant is used as a void input within the atomicSwap.ts file. This appears to be an intentional use case for representing a void type in the codebase.

Scripts Executed

The following scripts were executed for the analysis:


Script:

#!/bin/bash
# Search for usage of `iReduce` to understand its purpose.
rg --type typescript "iReduce"

Length of output: 65



Script:

#!/bin/bash
# Correct the search for usage of `iReduce` by specifying the file extension for TypeScript files.
rg "iReduce" -g "*.ts"

Length of output: 171

packages/language/examples/src/playground-v1/escrow.ts (1)
  • 66-69: The export of EscrowParams is consistent with the PR's objective to expand the public API. Ensure that this change is reflected in the documentation if EscrowParams is intended for public use.

Copy link
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.

Review Status

Actionable comments generated: 0

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 63a3c2c and 5c7b4b2.
Files selected for processing (1)
  • .github/workflows/test-suite.yaml (1 hunks)
Files skipped from review due to trivial changes (1)
  • .github/workflows/test-suite.yaml

@hrajchert hrajchert requested a review from nhenin December 19, 2023 14:32
@nhenin nhenin merged commit 12cb474 into main Dec 19, 2023
2 checks passed
@nhenin nhenin deleted the PLT-9008-fix-doc-warnings branch December 19, 2023 14:52
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.

PLT-9008: Fix warnings in doc generation PLT-8882 Make sure the formatter runs in the CI
2 participants