-
Notifications
You must be signed in to change notification settings - Fork 51
Release #2076
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
base: master
Are you sure you want to change the base?
Release #2076
Changes from 13 commits
4594536
5a81f9e
4c2277b
efb2aad
29aee53
e3ed3c9
77c8549
0cdc07d
e41ee56
9b1f5fd
2d94bfd
bfe11a7
63ecf4a
937fb97
752b64a
9140890
4a72da5
d3a1293
9d3ba90
3080c8f
a8942cd
89848ea
a130a6a
b8628bb
d10251b
41e8998
34f6a65
da7eea1
a8f3415
78b3169
738ef2c
82f8b1c
a0cb09d
5353ccf
831b062
3d211cc
95f2803
277457c
d1910ca
8d0edf4
c1bad1d
be33847
cabc743
b19b82d
1dbfedf
37bd43f
0a10ad2
257870c
4a451a5
5ca5c3b
bd4e169
31efb24
96e48f8
0f31e0e
d63d000
78f180a
413a85a
9895c7c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -4,7 +4,26 @@ All notable changes to this package will be documented in this file. | |||||||||
|
||||||||||
The format is based on [Common Changelog](https://common-changelog.org/). | ||||||||||
|
||||||||||
## [0.11.0] - 2025-08-01 | ||||||||||
## [0.13.0] - 2025-08-07 (Not published yet) | ||||||||||
|
||||||||||
### Changed | ||||||||||
|
||||||||||
- Set the Hardhat Solidity version to v0.8.30 and enable the IR pipeline ([#2069](https://github.com/kleros/kleros-v2/issues/2069)) | ||||||||||
- Set the Foundry Solidity version to v0.8.30 and enable the IR pipeline ([#2073](https://github.com/kleros/kleros-v2/issues/2073)) | ||||||||||
- Bump `hardhat` to v2.26.2 ([#2069](https://github.com/kleros/kleros-v2/issues/2069)) | ||||||||||
- Bump `@kleros/vea-contracts` to v0.7.0 ([#2073](https://github.com/kleros/kleros-v2/issues/2073)) | ||||||||||
|
||||||||||
## [0.12.0] - 2025-08-05 | ||||||||||
|
||||||||||
### Changed | ||||||||||
|
||||||||||
- **Breaking:** Make `viem` a peer dependency, it should be provided by the consuming package ([`4594536`](https://github.com/kleros/kleros-v2/commit/4594536c)) | ||||||||||
|
||||||||||
### Added | ||||||||||
|
||||||||||
- Add helper function `getDisputeKitsViem` to retrieve a deployment's available dispute kit infos including their capabilities (`isShutter`, `isGated`) ([`5a81f9e`](https://github.com/kleros/kleros-v2/commit/5a81f9ec)) | ||||||||||
|
||||||||||
## [0.11.0] - 2025-08-02 | ||||||||||
|
||||||||||
### Changed | ||||||||||
|
||||||||||
|
@@ -107,6 +126,8 @@ The format is based on [Common Changelog](https://common-changelog.org/). | |||||||||
|
||||||||||
## [0.8.1] - 2025-04-10 | ||||||||||
|
||||||||||
[0.13.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected] | ||||||||||
[0.12.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected] | ||||||||||
Comment on lines
+142
to
+143
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainAvoid adding a release link for an unpublished tag. If 0.13.0 isn’t published, this link will 404. Add it only when the release is live. -[0.13.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected]
+<!-- [0.13.0]: (add after publishing) --> Optionally confirm release existence before merging: 🏁 Script executed: #!/bin/bash
# Prints 200 if the tag exists, otherwise likely 404
curl -s -o /dev/null -w "%{http_code}\n" \
"https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected]" Length of output: 132 Remove unpublished release link for v0.13.0 in CHANGELOG.md The • File: Recommended change: -[0.13.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected]
+<!-- [0.13.0]: (add after publishing) --> 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
||||||||||
[0.11.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected] | ||||||||||
[0.10.0]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected] | ||||||||||
[0.9.4]: https://github.com/kleros/kleros-v2/releases/tag/@kleros%[email protected] | ||||||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,85 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
import { getContracts } from "./contractsViem"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
import { Abi, AbiEvent, getAbiItem, PublicClient } from "viem"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
import { DeploymentName } from "./utils"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
export type DisputeKitContracts = ReturnType<typeof getContracts>; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
export type DisputeKit = | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| NonNullable<DisputeKitContracts["disputeKitClassic"]> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| NonNullable<DisputeKitContracts["disputeKitShutter"]> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| NonNullable<DisputeKitContracts["disputeKitGated"]> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| NonNullable<DisputeKitContracts["disputeKitGatedShutter"]> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| null; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
export type DisputeKitInfos = { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
address: `0x${string}`; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
contract: DisputeKit; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
isGated: boolean; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
isShutter: boolean; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
export type DisputeKitByIds = Record<string, DisputeKitInfos>; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const fetchDisputeKits = async (client: PublicClient, klerosCoreAddress: `0x${string}`, klerosCoreAbi: Abi) => { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const DisputeKitCreated = getAbiItem({ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
abi: klerosCoreAbi, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
name: "DisputeKitCreated", | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}) as AbiEvent; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment on lines
+21
to
+24
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Unsafe type assertion - add runtime validation. The type assertion - const DisputeKitCreated = getAbiItem({
- abi: klerosCoreAbi,
- name: "DisputeKitCreated",
- }) as AbiEvent;
+ const DisputeKitCreated = getAbiItem({
+ abi: klerosCoreAbi,
+ name: "DisputeKitCreated",
+ });
+
+ if (!DisputeKitCreated || DisputeKitCreated.type !== 'event') {
+ throw new Error('DisputeKitCreated event not found in ABI');
+ } 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const logs = await client.getLogs({ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
address: klerosCoreAddress, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
event: DisputeKitCreated, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
fromBlock: 0n, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
toBlock: "latest", | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment on lines
+20
to
+30
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Consider performance implications of unbounded block range. Fetching events from block 0 to latest will become increasingly expensive as the chain grows. Consider adding block range parameters or caching mechanisms for production use. -const fetchDisputeKits = async (client: PublicClient, klerosCoreAddress: `0x${string}`, klerosCoreAbi: Abi) => {
+const fetchDisputeKits = async (
+ client: PublicClient,
+ klerosCoreAddress: `0x${string}`,
+ klerosCoreAbi: Abi,
+ fromBlock: bigint = 0n
+) => {
const DisputeKitCreated = getAbiItem({
abi: klerosCoreAbi,
name: "DisputeKitCreated",
}) as AbiEvent;
const logs = await client.getLogs({
address: klerosCoreAddress,
event: DisputeKitCreated,
- fromBlock: 0n,
+ fromBlock,
toBlock: "latest",
}); 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
return Object.fromEntries( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
logs | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
.filter((log) => { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const args = log.args as Record<string, unknown>; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
return "_disputeKitID" in args && "_disputeKitAddress" in args; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
.map((log) => { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const { _disputeKitID, _disputeKitAddress } = log.args as { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
_disputeKitID: bigint; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
_disputeKitAddress: string; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
return { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
disputeKitID: _disputeKitID, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
disputeKitAddress: _disputeKitAddress, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
.map(({ disputeKitID, disputeKitAddress }) => [disputeKitID!.toString(), disputeKitAddress as `0x${string}`]) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Comment on lines
+31
to
+49
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Add error handling for blockchain interactions. The function lacks error handling for potential RPC failures or malformed event data. Wrap the blockchain interaction in try-catch: + try {
const logs = await client.getLogs({
address: klerosCoreAddress,
event: DisputeKitCreated,
fromBlock: 0n,
toBlock: "latest",
});
+ } catch (error) {
+ throw new Error(`Failed to fetch DisputeKitCreated events: ${error}`);
+ }
🤖 Prompt for AI Agents
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
export const getDisputeKits = async (client: PublicClient, deployment: DeploymentName): Promise<DisputeKitByIds> => { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const { klerosCore, disputeKitClassic, disputeKitShutter, disputeKitGated, disputeKitGatedShutter } = getContracts({ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
publicClient: client, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
deployment: deployment, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const isDefined = <T>(kit: T): kit is NonNullable<T> => kit != null; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const disputeKitContracts = [disputeKitClassic, disputeKitShutter, disputeKitGated, disputeKitGatedShutter].filter( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
isDefined | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const shutterEnabled = [disputeKitShutter, disputeKitGatedShutter].filter(isDefined); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const gatedEnabled = [disputeKitGated, disputeKitGatedShutter].filter(isDefined); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const disputeKitMap = await fetchDisputeKits(client, klerosCore.address, klerosCore.abi); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
return Object.fromEntries( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Object.entries(disputeKitMap).map(([disputeKitID, address]) => { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
const contract = | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
disputeKitContracts.find((contract) => contract.address.toLowerCase() === address.toLowerCase()) ?? null; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
return [ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
disputeKitID, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
address, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
contract: contract satisfies DisputeKit, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
isGated: contract | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
? gatedEnabled.some((gated) => contract.address.toLowerCase() === gated.address.toLowerCase()) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
: false, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
isShutter: contract | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
? shutterEnabled.some((shutter) => contract.address.toLowerCase() === shutter.address.toLowerCase()) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
: false, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}, | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
]; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
}; |
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -1,6 +1,6 @@ | ||||||||||||||||||||||||||||||||||||
{ | ||||||||||||||||||||||||||||||||||||
"name": "@kleros/kleros-v2-contracts", | ||||||||||||||||||||||||||||||||||||
"version": "0.11.0", | ||||||||||||||||||||||||||||||||||||
"version": "0.12.0", | ||||||||||||||||||||||||||||||||||||
"description": "Smart contracts for Kleros version 2", | ||||||||||||||||||||||||||||||||||||
"main": "./cjs/deployments/index.js", | ||||||||||||||||||||||||||||||||||||
"module": "./esm/deployments/index.js", | ||||||||||||||||||||||||||||||||||||
|
@@ -121,7 +121,7 @@ | |||||||||||||||||||||||||||||||||||
"@types/mocha": "^10.0.10", | ||||||||||||||||||||||||||||||||||||
"@types/node": "^20.17.6", | ||||||||||||||||||||||||||||||||||||
"@types/sinon": "^17.0.4", | ||||||||||||||||||||||||||||||||||||
"@wagmi/cli": "^2.2.0", | ||||||||||||||||||||||||||||||||||||
"@wagmi/cli": "^2.3.2", | ||||||||||||||||||||||||||||||||||||
"abitype": "^0.10.3", | ||||||||||||||||||||||||||||||||||||
"chai": "^4.5.0", | ||||||||||||||||||||||||||||||||||||
"dotenv": "^16.6.1", | ||||||||||||||||||||||||||||||||||||
|
@@ -131,7 +131,7 @@ | |||||||||||||||||||||||||||||||||||
"gluegun": "^5.2.0", | ||||||||||||||||||||||||||||||||||||
"graphql": "^16.9.0", | ||||||||||||||||||||||||||||||||||||
"graphql-request": "^7.1.2", | ||||||||||||||||||||||||||||||||||||
"hardhat": "2.25.0", | ||||||||||||||||||||||||||||||||||||
"hardhat": "2.26.2", | ||||||||||||||||||||||||||||||||||||
"hardhat-contract-sizer": "^2.10.0", | ||||||||||||||||||||||||||||||||||||
"hardhat-deploy": "^1.0.4", | ||||||||||||||||||||||||||||||||||||
"hardhat-deploy-ethers": "^0.4.2", | ||||||||||||||||||||||||||||||||||||
|
@@ -154,10 +154,17 @@ | |||||||||||||||||||||||||||||||||||
}, | ||||||||||||||||||||||||||||||||||||
"dependencies": { | ||||||||||||||||||||||||||||||||||||
"@chainlink/contracts": "^1.4.0", | ||||||||||||||||||||||||||||||||||||
"@kleros/vea-contracts": "^0.6.0", | ||||||||||||||||||||||||||||||||||||
"@kleros/vea-contracts": "^0.7.0", | ||||||||||||||||||||||||||||||||||||
"@openzeppelin/contracts": "^5.4.0", | ||||||||||||||||||||||||||||||||||||
"@shutter-network/shutter-sdk": "0.0.2", | ||||||||||||||||||||||||||||||||||||
"isomorphic-fetch": "^3.0.0", | ||||||||||||||||||||||||||||||||||||
"isomorphic-fetch": "^3.0.0" | ||||||||||||||||||||||||||||||||||||
}, | ||||||||||||||||||||||||||||||||||||
"peerDependencies": { | ||||||||||||||||||||||||||||||||||||
"viem": "^2.24.1" | ||||||||||||||||||||||||||||||||||||
}, | ||||||||||||||||||||||||||||||||||||
"peerDependenciesMeta": { | ||||||||||||||||||||||||||||||||||||
"viem": { | ||||||||||||||||||||||||||||||||||||
"optional": false | ||||||||||||||||||||||||||||||||||||
} | ||||||||||||||||||||||||||||||||||||
} | ||||||||||||||||||||||||||||||||||||
Comment on lines
+162
to
169
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Peer dependency viem ^2.24.1 conflicts with root resolution (^2.23.2). This will produce peer warnings/errors and potentially divergent behavior across workspaces. Either relax the peer to match the resolution, or better, update the root resolution to satisfy the peer (recommended): Preferred (root package.json): - "viem@npm:2.x": "npm:^2.23.2"
+ "viem@npm:2.x": "npm:^2.24.1" If you must stay on 2.23.x, change this package’s peer to: - "viem": "^2.24.1"
+ "viem": "^2.23.0" …but this may block newer features you rely on. 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
||||||||||||||||||||||||||||||||||||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import { getDisputeKits } from "../deployments/disputeKitsViem"; | ||
import { createPublicClient, http } from "viem"; | ||
import { arbitrumSepolia } from "viem/chains"; | ||
|
||
const rpc = process.env.ARBITRUM_SEPOLIA_RPC; | ||
if (!rpc) { | ||
throw new Error("ARBITRUM_SEPOLIA_RPC is not set"); | ||
} | ||
|
||
const client = createPublicClient({ | ||
chain: arbitrumSepolia, | ||
transport: http(rpc), | ||
}); | ||
|
||
async function main() { | ||
try { | ||
console.log("Fetching DisputeKitCreated events..."); | ||
const disputeKitResult = await getDisputeKits(client, "devnet"); | ||
console.log(disputeKitResult); | ||
} catch (error) { | ||
console.error("Error fetching events:", error); | ||
throw error; | ||
} | ||
} | ||
|
||
if (require.main === module) { | ||
main() | ||
.then(() => process.exit(0)) | ||
.catch((error) => { | ||
console.error(error); | ||
process.exit(1); | ||
}); | ||
} |
Original file line number | Diff line number | Diff line change | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -77,7 +77,8 @@ | |||||||||||||
"elliptic@npm:6.5.4": "npm:6.6.1", | ||||||||||||||
"word-wrap@npm:~1.2.3": "npm:1.2.5", | ||||||||||||||
"@codemirror/state": "npm:6.5.2", | ||||||||||||||
"undici@npm:7.3.0": "npm:7.5.0" | ||||||||||||||
"undici@npm:7.3.0": "npm:7.5.0", | ||||||||||||||
"viem@npm:2.x": "npm:^2.23.2" | ||||||||||||||
Comment on lines
+80
to
+81
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainAlign viem resolution with contracts’ peer dependency to avoid peer conflicts. Root resolution pins viem 2.x to ^2.23.2, while contracts require viem ^2.24.1 as a peer. This will trigger peer resolution warnings/errors in Yarn 4 and could break consumers. Update the resolution to satisfy the peer: "resolutions": {
...
- "viem@npm:2.x": "npm:^2.23.2"
+ "viem@npm:2.x": "npm:^2.24.1"
}, To check for other mismatches: 🏁 Script executed: #!/bin/bash
rg -n --json '"viem"\s*:\s*"' | jq -r '.data.path.text + ":" + .data.line_number|tostring + " " + .data.lines.text' Length of output: 1417 🏁 Script executed: #!/bin/bash
# Search for all references to “viem” in any JSON file to spot mismatched pins
rg -n '"viem"' -g '*.json' Length of output: 440 Update viem resolution to match peerDependency (^2.24.1) All of your sub-packages (contracts, web, kleros-sdk, web-devtools, kleros-app) declare viem at ^2.24.1, but the root • File: package.json (root) "resolutions": {
…
- "viem@npm:2.x": "npm:^2.23.2"
+ "viem@npm:2.x": "npm:^2.24.1"
}, 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
||||||||||||||
}, | ||||||||||||||
"scripts": { | ||||||||||||||
"check-prerequisites": "scripts/check-prerequisites.sh", | ||||||||||||||
|
Original file line number | Diff line number | Diff line change | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -9,3 +9,8 @@ YARN_ENABLE_GLOBAL_CACHE = "true" | |||||||||||||||||
|
||||||||||||||||||
[functions] | ||||||||||||||||||
directory = "web/netlify/functions/" | ||||||||||||||||||
|
||||||||||||||||||
[[headers]] | ||||||||||||||||||
for = "/*" | ||||||||||||||||||
[headers.values] | ||||||||||||||||||
X-Robots-Tag = "llms-txt" | ||||||||||||||||||
Comment on lines
+13
to
+16
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainHeader value likely incorrect; consider advertising llms.txt via Link header instead of X-Robots-Tag. X-Robots-Tag expects crawler directives (e.g., noindex, noai). Using "llms-txt" here is non-standard and probably ignored. To advertise a policy file, prefer a Link header (and ensure the file is served at the expected path). Apply one of these: Option A — advertise a policy file: [[headers]]
for = "/*"
[headers.values]
- X-Robots-Tag = "llms-txt"
+ Link = "</llms.txt>; rel=\"ai-policy\"" Option B — if you meant to control AI crawlers: [[headers]]
for = "/*"
[headers.values]
- X-Robots-Tag = "llms-txt"
+ X-Robots-Tag = "noai, noimageai" Also verify the file is published at the root (e.g., web/public/llms.txt → https://site/llms.txt), not under src. Run to locate the file and confirm its publish path: 🏁 Script executed: #!/bin/bash
fd -HI --glob "llms.txt" Length of output: 48 Misuse of X-Robots-Tag; advertise AI policy via Link header
Option A — advertise your policy file via Link header: [[headers]]
for = "/*"
[headers.values]
- X-Robots-Tag = "llms-txt"
+ Link = "</llms.txt>; rel=\"ai-policy\"" Option B — apply valid X-Robots-Tag directives: [[headers]]
for = "/*"
[headers.values]
- X-Robots-Tag = "llms-txt"
+ X-Robots-Tag = "noai, noimageai" 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# v2.kleros.builders llms.txt | ||
|
||
> Facilitates decentralized arbitration by allowing users to create, manage, and resolve dispute cases through crowdsourced juror consensus, rewarding jurors with cryptocurrency for coherent votes on disputes on the blockchain-based Kleros platform. | ||
|
||
- [Kleros Dispute Dashboard](https://v2.kleros.builders): Dashboard for managing and viewing decentralized dispute cases, jurors, and court statistics on Kleros platform. | ||
- [Kleros Dispute Cases](https://v2.kleros.builders/#/cases/display/1/desc/all): Provide a platform for viewing and managing decentralized dispute resolution cases. | ||
- [Kleros Decentralized Courts](https://v2.kleros.builders/#/courts): Facilitate decentralized dispute resolution by allowing users to stake tokens, participate as jurors, and view court cases. | ||
- [Kleros Jurors Leaderboard](https://v2.kleros.builders/#/jurors/1/desc/all): Display ranking and statistics of jurors based on coherent voting and rewards in the Kleros decentralized arbitration system. | ||
- [Get PNK Token](https://v2.kleros.builders/#/get-pnk): Facilitates cross-chain swaps of PNK tokens typically between the Ethereum and Arbitrum networks. |
Uh oh!
There was an error while loading. Please reload this page.