Closed HelgeKrueger closed 3 weeks ago
[!WARNING]
Rate limit exceeded
@dahlia has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 23 minutes and 18 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 as a PR comment. 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](https://coderabbit.ai/docs/faq) for further information.📥 Commits
Reviewing files that changed from the base of the PR and between 06da44dfe9b33ace6018ef6814138a9f1dae0ddc and 4fd03b957538415f5cf5929deb4927fe26f51915.
The changes introduce a new property allowPrivateAddress
in src/federation/index.ts
, determined by the environment variable ALLOW_PRIVATE_ADDRESS
. In src/index.tsx
, a constant LISTEN_PORT
is added, retrieving its value from the environment variable LISTEN_PORT
, defaulting to 3000
. This constant is incorporated into the export statement, modifying the exported object to include both the fetch
method and the new port
property when BEHIND_PROXY
is true. The .env.sample
file is also updated to include these new environment variables.
File | Change Summary |
---|---|
src/federation/index.ts | Added allowPrivateAddress to createFederation based on ALLOW_PRIVATE_ADDRESS environment variable. |
src/index.tsx | Introduced LISTEN_PORT constant from LISTEN_PORT environment variable, defaulting to 3000 . Modified export to include fetch and port properties. |
.env.sample | Added new environment variables LISTEN_PORT=3000 and ALLOW_PRIVATE_ADDRESS=false with comments. |
CHANGES.md | Documented the addition of LISTEN_PORT and ALLOW_PRIVATE_ADDRESS environment variables. |
docs/src/content/docs/install/env.mdx | Updated documentation to include LISTEN_PORT and ALLOW_PRIVATE_ADDRESS with descriptions and defaults. |
docs/src/content/docs/ja/install/env.mdx | Updated Japanese documentation to include LISTEN_PORT and ALLOW_PRIVATE_ADDRESS with descriptions. |
docs/src/content/docs/ko/install/env.mdx | Updated Korean documentation to include LISTEN_PORT and ALLOW_PRIVATE_ADDRESS with descriptions. |
docs/src/content/docs/zh-cn/install/env.mdx | Updated Chinese documentation to include LISTEN_PORT and ALLOW_PRIVATE_ADDRESS with descriptions. |
ALLOW_PRIVATE_ADDRESS
environment variable, which is also documented in the retrieved PR that adds a Simplified Chinese translation for the documentation, ensuring that users can understand the new configuration options in their language.In the code where rabbits play,
New properties hop in today!
A port to fetch, a flag to see,
Private addresses, oh so free!
With each change, we leap and cheer,
For better code is finally here! 🐇✨
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 your favorite social media?
An option like this does make sense, however, it should be a comma separated string of private IP addresses or ranges not to enforce checking on, not a simple Boolean value.
e.g., https://docs.joinmastodon.org/admin/config/#allowed_private_addresses
Added change to .env.sample
I also created https://github.com/dahlia/fedify/issues/157
It is strange when I run biome, there is no erro rrmessage ...
docker compose run --rm hollo bunx biome check
WARN[0000] The "LOG_LEVEL" variable is not set. Defaulting to a blank string.
WARN[0000] The "BEHIND_PROXY" variable is not set. Defaulting to a blank string.
WARN[0000] The "SECRET_KEY" variable is not set. Defaulting to a blank string.
[+] Creating 3/0
✔ Container hollo-minio-1 Running 0.0s
✔ Container hollo-postgres-1 Running 0.0s
✔ Container hollo-create-bucket-1 Created 0.0s
[+] Running 1/1
✔ Container hollo-create-bucket-1 Started 0.2s
Checked 77 files in 1322ms. No fixes applied.
These errors came from TypeScript (bunx tsc
):
src/federation/index.ts(112,36): error TS4111: Property 'ALLOW_PRIVATE_ADDRESS' comes from an index signature, so it must be accessed with ['ALLOW_PRIVATE_ADDRESS'].
src/index.tsx(34,48): error TS4111: Property 'LISTEN_PORT' comes from an index signature, so it must be accessed with ['LISTEN_PORT'].
Sorry, for needing so many tries to get everything working. I still cannot get biome working in the docker environment. But it works on the host. Not sure what is going on.
As far as tsc, I get the errors. Are they expected?
/app # bunx tsc
src/components/AccountForm.tsx:28:11 - error TS2322: Type 'string' is not assignable to type 'HTMLAttributeFormMethod | undefined'.
28 <form method={props.method ?? "post"} action={props.action}>
~~~~~~
node_modules/hono/dist/types/jsx/intrinsic-elements.d.ts:272:9
272 method?: HTMLAttributeFormMethod | undefined;
~~~~~~
The expected type comes from property 'method' which is declared here on type 'FormHTMLAttributes'
src/components/LoginForm.tsx:16:11 - error TS2322: Type 'string' is not assignable to type 'HTMLAttributeFormMethod | undefined'.
16 <form method={props.method ?? "post"} action={props.action}>
~~~~~~
node_modules/hono/dist/types/jsx/intrinsic-elements.d.ts:272:9
272 method?: HTMLAttributeFormMethod | undefined;
~~~~~~
The expected type comes from property 'method' which is declared here on type 'FormHTMLAttributes'
src/components/OtpForm.tsx:12:11 - error TS2322: Type 'string' is not assignable to type 'HTMLAttributeFormMethod | undefined'.
12 <form method={props.method ?? "post"} action={props.action}>
~~~~~~
node_modules/hono/dist/types/jsx/intrinsic-elements.d.ts:272:9
272 method?: HTMLAttributeFormMethod | undefined;
~~~~~~
The expected type comes from property 'method' which is declared here on type 'FormHTMLAttributes'
src/components/SetupForm.tsx:16:11 - error TS2322: Type 'string' is not assignable to type 'HTMLAttributeFormMethod | undefined'.
16 <form method={props.method ?? "post"} action={props.action}>
~~~~~~
node_modules/hono/dist/types/jsx/intrinsic-elements.d.ts:272:9
272 method?: HTMLAttributeFormMethod | undefined;
~~~~~~
The expected type comes from property 'method' which is declared here on type 'FormHTMLAttributes'
Found 4 errors in 4 files.
Errors Files
1 src/components/AccountForm.tsx:28
1 src/components/LoginForm.tsx:16
1 src/components/OtpForm.tsx:12
1 src/components/SetupForm.tsx:16
Did you run bun install
?
By setting
one allows private addresses and runs on port 80.
Summary by CodeRabbit
New Features
Documentation
.env.sample
to include the newLISTEN_PORT
andALLOW_PRIVATE_ADDRESS
variables for server configuration.