instance_id
stringlengths
10
65
repo
stringlengths
5
59
pr_number
int64
1
313k
task_type
stringclasses
1 value
base_commit
stringlengths
40
40
review_commit
stringlengths
40
40
title
stringlengths
2
282
body
stringlengths
7
3k
patch
stringlengths
202
204k
n_defects
int64
1
72
n_supported
int64
1
65
n_major
int64
0
32
defects
stringlengths
140
18.8k
certifier_count
int64
tldraw__tldraw__8037
tldraw/tldraw
8,037
defect
bb089564da0c5864200a4a69e90b3d6b483fa4a6
115acbc32eb86c44d9eb44122b627ab4ba495649
fix(ui): save input on blur in link editor + alt text editor
In order to prevent users from accidentally losing their link edits when clicking outside the rich text link editor and alt text editor, this PR makes clicking away save the current value instead of discarding it. Closes #7673. ### Change type - [x] `improvement` ### Test plan 1. Create a geo shape and doub...
diff --git a/apps/examples/e2e/tests/test-rich-text-toolbar.spec.ts b/apps/examples/e2e/tests/test-rich-text-toolbar.spec.ts index f8206c634b29..313554832f4b 100644 --- a/apps/examples/e2e/tests/test-rich-text-toolbar.spec.ts +++ b/apps/examples/e2e/tests/test-rich-text-toolbar.spec.ts @@ -123,6 +123,32 @@ test.describ...
1
1
1
[{"id": "G0", "claim": "Blurring or clicking away from the link editor with empty input calls handleLinkComplete(''), which prepends https:// and silently saves an invalid 'https://' link on the selected text (including when an existing link's text is cleared), where clicking away used to be a no-op.", "category": "cor...
null
tldraw__tldraw__8054
tldraw/tldraw
8,054
defect
bb089564da0c5864200a4a69e90b3d6b483fa4a6
3ed81d11571fde1f02ab58e48dae272fc4084f16
fix(eraser): erase shapes inside groups when starting drag from within group bounds
In order to fix erasing shapes inside groups when the eraser drag starts from within the group bounds, this PR updates the hit-resolution logic in the Erasing state. Previously, `getOutermostSelectableShape` resolved every hit shape to the group, which was then filtered out by the exclusion set — so nothing got erased....
diff --git a/packages/tldraw/src/lib/tools/EraserTool/childStates/Erasing.ts b/packages/tldraw/src/lib/tools/EraserTool/childStates/Erasing.ts index ad8d2c01d86f..fe04f8d54b82 100644 --- a/packages/tldraw/src/lib/tools/EraserTool/childStates/Erasing.ts +++ b/packages/tldraw/src/lib/tools/EraserTool/childStates/Erasing....
1
1
1
[{"id": "G0", "claim": "The 'Erases the whole group when starting drag outside of it' test drags over box1 instead of box2, so it should use a drag path that stays away from box1 (e.g. start at 100,-100) and it should not edit the expectations.", "category": "correctness", "verdict": "supported", "priority": "P1", "sco...
null
tldraw__tldraw__8128
tldraw/tldraw
8,128
defect
62f7fb4691286e68020658c16c9b59ed2b43db41
4c6dee5c6fc953a153efe20aef72140be843a91f
feat(dotcom): add /import route and app file download endpoint
In order to support importing a tldraw file from a URL (e.g. \`/import?url=...\`) and to allow downloading app files as .tldr from the sidebar and editor, this PR adds the \`/import\` route, a server-side download endpoint, and wires the Download action to use it for all app files. Relates to #8089. The import URL is ...
diff --git a/apps/dotcom/client/src/__snapshots__/routes.test.tsx.snap b/apps/dotcom/client/src/__snapshots__/routes.test.tsx.snap index 690622b7d779..d2d592983599 100644 --- a/apps/dotcom/client/src/__snapshots__/routes.test.tsx.snap +++ b/apps/dotcom/client/src/__snapshots__/routes.test.tsx.snap @@ -34,6 +34,10 @@ ex...
11
10
7
[{"id": "G0", "claim": "If the upload fails, uploadTldrFiles returns without calling the callback, so the importFromUrl promise hangs until the 90-second timeout fires, leaving a blank page and a second duplicate error toast.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"},...
null
tldraw__tldraw__8146
tldraw/tldraw
8,146
defect
73506731905f5c138812108188fcef75e719153a
c5af263135c2e16e5c80e2b4a20d1d5e5f812890
fix(sync-worker): use custom tar reader for Pierre history snapshot to avoid Workers deadlock
In order to fix the Pierre history snapshot endpoint hanging in Cloudflare Workers, this PR replaces `modern-tar` with a minimal USTAR stream reader and keeps the response streaming to avoid OOM for large files. `modern-tar` yields `entry.body` as a nested `ReadableStream` that is fed in a later `transform()` call. In...
diff --git a/apps/dotcom/sync-worker/package.json b/apps/dotcom/sync-worker/package.json index 0fadda92aed8..95540214e299 100644 --- a/apps/dotcom/sync-worker/package.json +++ b/apps/dotcom/sync-worker/package.json @@ -39,7 +39,6 @@ "jose": "^5.9.6", "kysely": "^0.27.5", "lodash.throttle": "^4.1.1", - "modern...
3
2
1
[{"id": "G0", "claim": "When typeflag is not 0x30 but size > 0, readTarStream consumes neither the entry body nor its block-aligned padding, desynchronizing and corrupting all subsequent entries (affecting POSIX AREGTYPE and GNU long-name entries).", "category": "correctness", "verdict": "uncertain", "priority": "P1", ...
null
tldraw__tldraw__8161
tldraw/tldraw
8,161
defect
3383b00fff8351606f5432a608e769b9e7dce122
f7b5e6e2784add5727fec48ff3379f73181f35c5
fix(create-tldraw): create subdirectory from project name
Closes #8148 ## Summary - `npm create tldraw` now always creates a subdirectory from the project name instead of installing into the current directory - If a directory with that name already exists, appends `-1`, `-2`, etc. — never overwrites - Removes the `--overwrite` flag and "directory is not empty" prompt,...
diff --git a/packages/create-tldraw/src/main.ts b/packages/create-tldraw/src/main.ts index 9653ae39184f..7311412b4741 100644 --- a/packages/create-tldraw/src/main.ts +++ b/packages/create-tldraw/src/main.ts @@ -1,7 +1,7 @@ import { parse as parseArgs } from '@bomb.sh/args' -import { outro, select, spinner, text } from...
4
2
2
[{"id": "G0", "claim": "isDirEmpty calls readdirSync on paths that may be regular files - the candidate paths findAvailableDir auto-generates, or an initial targetDir matching an existing file - which throws ENOTDIR and crashes the tool.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "i...
null
tldraw__tldraw__8163
tldraw/tldraw
8,163
defect
6c9d28260f168277abf35d43175497dddc3dba07
ec564601f0adf3d6b68141bee23c9f7447128787
fix(images): use dual DPI baselines for correct pixelRatio on all platforms
High-DPI PNGs (e.g. Retina screenshots) store their logical size in `asset.props.w`/`h`, but their actual pixel dimensions are larger. Without knowing the pixel ratio, the CDN image resize endpoints cap the requested width at the logical size, returning a downscaled image that looks blurry on retina displays. This P...
diff --git a/apps/dotcom/client/src/utils/multiplayerAssetStore.ts b/apps/dotcom/client/src/utils/multiplayerAssetStore.ts index ba48c9f7e5fb..343b5b36e67f 100644 --- a/apps/dotcom/client/src/utils/multiplayerAssetStore.ts +++ b/apps/dotcom/client/src/utils/multiplayerAssetStore.ts @@ -125,13 +125,15 @@ export function...
4
2
1
[{"id": "G0", "claim": "Using 72 DPI as the pixelsPerMeter baseline misclassifies standard 96 DPI PNGs as high-DPI (pixelRatio ~1.333 instead of 1, and Windows 192 DPI screenshots as ~2.667 instead of 2.0), so w and h are divided by the wrong ratio and those images appear ~25% smaller than their actual pixel dimensions...
null
tldraw__tldraw__8285
tldraw/tldraw
8,285
defect
0bcbb3ed5bcb7fe24e5d2bd47b4de6f230d1391c
e26c6154591650e5b87ba90a89dcf3007a1b2454
Feature: adds mind map diagram types to Mermaid
Adds in support for mind maps as a new diagram type in mermaid. <img width="456" height="301" alt="Screenshot 2026-03-19 at 15 10 12" src="https://github.com/user-attachments/assets/e5cfe2b7-5174-4275-a5df-501883f3b278" /> <img width="1173" height="413" alt="Screenshot 2026-03-19 at 15 10 20" src="https://github.co...
diff --git a/apps/examples/src/examples/use-cases/hundred-mermaids/MermaidDiagramsExample.tsx b/apps/examples/src/examples/use-cases/hundred-mermaids/MermaidDiagramsExample.tsx index 902362c39948..0a506bae4e49 100644 --- a/apps/examples/src/examples/use-cases/hundred-mermaids/MermaidDiagramsExample.tsx +++ b/apps/examp...
2
2
1
[{"id": "G0", "claim": "Mindmap node colours should be derived with the same code from colors.ts that the other graphs use, returning the closest colour from the tldraw palette, instead of the ad-hoc section-colour fallback that causes a colour discrepancy.", "category": "correctness", "verdict": "supported", "priority...
null
tldraw__tldraw__8344
tldraw/tldraw
8,344
defect
f1cd46b631a48b8bb80ec90140262723371cd7f7
6f97cfc778f24b6203ded4d5f9efa7d79eac1c07
feat: use plaintext for mermaid parsing when clipboard has html+text
Fixes an issue where mermaid code from VS Code, textedit, and live mermaid editor (among others) wasn't rendering as shapes because the stripped HTML removed the linebreaks so it was parsing as invalid mermaid. This has been kept inside the mermaid handler to make sure it shouldn't impact any other copy/paste functi...
diff --git a/apps/dotcom/client/src/components/SneakyMermaidHandler/SneakyMermaidHandler.tsx b/apps/dotcom/client/src/components/SneakyMermaidHandler/SneakyMermaidHandler.tsx index 88d3064a019b..da2e4e32ab91 100644 --- a/apps/dotcom/client/src/components/SneakyMermaidHandler/SneakyMermaidHandler.tsx +++ b/apps/dotcom/c...
2
2
0
[{"id": "G0", "claim": "Add a quick explanatory comment to the MARKDOWN_MERMAID_FENCE_REGEX in simpleMermaidStringTest.ts.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Replace the comment above plainTextSource in SneakyMermaidHandler.tsx with cl...
null
tldraw__tldraw__8392
tldraw/tldraw
8,392
defect
3f6bf50409007a1429211f8ecae218a6a8984ea3
2f2ba6f74930795b5c2f84903778d3c51df0579c
refactor(editor): replace @use-gesture/react with custom gesture handling
In order to remove a stale, unmaintained dependency and eliminate workarounds for its behavior, this PR replaces `@use-gesture/react` with custom event handlers for wheel and pinch gesture handling on the canvas. Closes #8391. The library was only used in a single file (`useGestureEvents.ts`) for wheel and pinch actio...
diff --git a/packages/editor/package.json b/packages/editor/package.json index 1a70b1f52443..d4fbce8fdc2b 100644 --- a/packages/editor/package.json +++ b/packages/editor/package.json @@ -56,7 +56,6 @@ "@tldraw/tlschema": "workspace:*", "@tldraw/utils": "workspace:*", "@tldraw/validate": "workspace:*", - "@use...
2
2
0
[{"id": "G0", "claim": "The explanatory touch-pinch comments being removed (e.g. the `[touch]-------origin-------[touch]` diagram) should be kept rather than deleted.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The explanatory comments remove...
null
tldraw__tldraw__8501
tldraw/tldraw
8,501
defect
4677565c1ea7ff93e3918b1fa6e5eca7a9788398
4ed8cba3c38a07d4ab35f227102b80e96954b831
feat(editor): right-click and drag to pan the camera
In order to support a common panning interaction from tools like Figma, this PR lets users pan the canvas with right-click + drag while keeping a static right-click as the trigger for the context menu. Enabled by default via the new `rightClickPanning` editor option (mirroring `spacebarPanning`) — set it to `false` to ...
diff --git a/assets/translations/main.json b/assets/translations/main.json index 4344bef7854c..c86cb6aede84 100644 --- a/assets/translations/main.json +++ b/assets/translations/main.json @@ -102,6 +102,8 @@ "action.toggle-edge-scrolling": "Toggle edge scrolling", "action.toggle-invert-zoom.menu": "Invert mouse zoom...
4
3
2
[{"id": "G0", "claim": "The synthetic contextmenu dispatch in onPointerUp should probably depend on isRightClickToDrag; otherwise event duplication may occur.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The code comment saying the early dispatch ...
null
tldraw__tldraw__8573
tldraw/tldraw
8,573
defect
71f3bec648166e20fafcae06e5421b09c01f2c90
d2e7afcbfa70cc3df800ed2f3879be52fe3db4e1
feat(perf): add A/B test for canvas indicators vs SVG indicators
In order to measure the performance impact of the 2D canvas indicator rendering introduced in #7708, this PR adds an A/B test that splits users between canvas-rendered indicators (treatment) and legacy SVG-rendered indicators (control). Closes #8572. The `canvas_indicators_ab` percentage feature flag uses the existing...
diff --git a/apps/dotcom/client/src/hooks/useCanvasIndicatorsAb.ts b/apps/dotcom/client/src/hooks/useCanvasIndicatorsAb.ts new file mode 100644 index 000000000000..eabcf007190a --- /dev/null +++ b/apps/dotcom/client/src/hooks/useCanvasIndicatorsAb.ts @@ -0,0 +1,19 @@ +import { useState } from 'react' +import { getCurre...
4
2
2
[{"id": "G0", "claim": "The hook resolves the A/B group from the default feature-flag values at mount instead of waiting for the initial flag fetch, which can misbucket the user and mismatch what usePerformanceTracking records.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"...
null
tldraw__tldraw__8604
tldraw/tldraw
8,604
defect
cfe95d2b31b64ff6e090c2fe0606a74a79a72e6e
03e5b4f0d3cc56d31f012181d81072b5d3cbca96
fix(memory): clean up module-level state leaks after editor unmount
In order to prevent `Editor`, `Store`, and sync client instances from being retained after unmount, this PR cleans up several module-level caches, globals, and debounced functions that hold references. Particularly impactful for apps that mount/unmount editors frequently (iOS WebViews hit memory limits). Closes #8440. ...
diff --git a/packages/editor/src/lib/exports/fetchCache.ts b/packages/editor/src/lib/exports/fetchCache.ts index 0b4f7c0c9b49..966362d42fd8 100644 --- a/packages/editor/src/lib/exports/fetchCache.ts +++ b/packages/editor/src/lib/exports/fetchCache.ts @@ -1,9 +1,7 @@ -import { FileHelpers, assert, fetch } from '@tldraw/...
4
4
1
[{"id": "G0", "claim": "An LruCache capacity of 500 for the image alpha cache seems high.", "category": "design", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "An LruCache capacity of 200 for the fetch cache seems maybe high; 100 is probably fine.", "category": "design", "verd...
null
tldraw__tldraw__8651
tldraw/tldraw
8,651
defect
84b3964a430d9ca6668132ea0e62f609a44bf375
e22a0bd7232e5db7ddadd9736f17a21823e70be4
feat: hold accel to temporarily erase from draw / highlight
In order to let users dip into the eraser without leaving the draw or highlight tool, this PR makes accel-click temporarily erase. While in draw / highlight idle, holding the accel key (Cmd on macOS, Ctrl elsewhere) and clicking goes straight into eraser pointing/dragging. The toolbar still shows the originating tool, ...
diff --git a/packages/tldraw/api-report.api.md b/packages/tldraw/api-report.api.md index c59da21ed7ab..9fd62cead164 100644 --- a/packages/tldraw/api-report.api.md +++ b/packages/tldraw/api-report.api.md @@ -1750,11 +1750,24 @@ export class EraserTool extends StateNode { // (undocumented) static id: string; ...
1
1
1
[{"id": "G0", "claim": "`_accelHeld` is set to true on any Meta/Control keydown even when that key is not the platform accel key (e.g. Control on macOS), which can keep `_accelHeld` true mid-erase and prevent returning to the originating tool; use `info.accelKey` / `isAccelKey(info)` to update `_accelHeld` instead of c...
null
tldraw__tldraw__8714
tldraw/tldraw
8,714
defect
6473e418fb54d996a9e43389f3e7e6f1d82c6bf6
0fce6a5b478145df724aad9378ecfbfd6844f92f
fix(shapes): ignore colliding customGeoTypes keys in configure()
In order to make `GeoShapeUtil.configure()` actually ignore colliding `customGeoTypes` keys, this PR strips the colliding entries out of the options before delegating to `super.configure()`. Follow-up to review feedback on #8705. Previously, the dev-mode warning said the colliding key would be ignored, but only the sc...
diff --git a/packages/tldraw/src/lib/shapes/geo/GeoShapeUtil.test.tsx b/packages/tldraw/src/lib/shapes/geo/GeoShapeUtil.test.tsx index 783c309281c1..ec7999e18493 100644 --- a/packages/tldraw/src/lib/shapes/geo/GeoShapeUtil.test.tsx +++ b/packages/tldraw/src/lib/shapes/geo/GeoShapeUtil.test.tsx @@ -1,5 +1,8 @@ import {...
2
2
2
[{"id": "G0", "claim": "Because existingValues is built from GeoShapeGeoStyle.values (which includes custom values added by earlier configure() calls), the PR's new filtering/early-return makes reusing a custom key in a second configure() call be treated as a collision and stripped from options.customGeoTypes, making t...
null
tleunen__babel-plugin-module-resolver__205
tleunen/babel-plugin-module-resolver
205
defect
d4558aef9647e2863bbf45e2379328c50bb71c64
3920880b2c86c8b7091417725ef19f93651ce0cb
Add a stripExtensions option for RN support
See #90 for context. Example : ```json #before.babelrc { "presets": ["react-native"], "plugins": [ [ "module-resolver", { "root": ["./src"], "extensions": [".js", ".ios.js", ".android.js"] } ] ] } #after.babelrc { "presets": ["react-native"], ...
diff --git a/README.md b/README.md index 11cea6e..83912ae 100644 --- a/README.md +++ b/README.md @@ -55,6 +55,7 @@ Are you a plugin author (e.g. IDE integration)? We have [documented the exposed - The custom value `packagejson` will make the plugin look for the closest `package.json` based on the file to parse. -...
4
2
1
[{"id": "G0", "claim": "The plugin should strip extensions by default, iterating through the configured extensions, instead of adding a new stripExtensions option.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "A boolean stripExtensions option could work...
null
tleunen__babel-plugin-module-resolver__253
tleunen/babel-plugin-module-resolver
253
defect
bc9fa3a279b6eb98f4bdc4c455c94a3135ebdefe
97dddb0ab78fb21ab7375ed65721b643190e3b46
Fix path transformation for dot files that are sibling to current file
Currently the code checks for a relative path by checking if it starts with a dot. This incorrectly identifies a path resolved dot file e.g. `.eslintrc` as a relative path. So it does NOT transform the path to relative path such as `./.eslintric`. This is fixed by using a regex that checks for a `./` or `../` at the st...
diff --git a/src/resolvePath.js b/src/resolvePath.js index 9858489..30c73f7 100644 --- a/src/resolvePath.js +++ b/src/resolvePath.js @@ -3,7 +3,7 @@ import path from 'path'; import { warn } from './log'; import mapToRelative from './mapToRelative'; import normalizeOptions from './normalizeOptions'; -import { nodeRes...
3
3
1
[{"id": "G0", "claim": "The isRelativePath regex should be anchored to /^\\.?\\.\\// because the unanchored /\\.?\\.\\// also matches paths like `foo./bar`, and a regression test should be added for that case.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "c...
null
tlivings__enjoi__82
tlivings/enjoi
82
defect
c3ac49cfaac5cd87c692557ac0b105ceedfa1d33
f90df374444e853d7202829df0eca022e7e6abf3
Fix for #73: Empty string ignores regex string validation
The previous fix for #73 did not fix the issue. I added simple test case to the code (below), where the empty string is passed to regex validation and it's returned as OK (that doesn't make sense). Proposed fix is simple: let's NOT call "allow('')" if the minLength is not explicitly defined as 0.
diff --git a/lib/resolver.js b/lib/resolver.js index 182af2a..6135dc9 100644 --- a/lib/resolver.js +++ b/lib/resolver.js @@ -351,9 +351,7 @@ class SchemaResolver { if (Util.isUndefined(schema.minLength)) { schema.minLength = 0; - } - - if (schema.minLength === 0) { + ...
1
1
0
[{"id": "G0", "claim": "Put the `else if (schema.minLength === 0)` clause on a new line instead of at the end of the closing-brace line, to keep with the rest of the code style.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
tlsfuzzer__python-ecdsa__102
tlsfuzzer/python-ecdsa
102
defect
a7f1db605f73589db396f6a3cd95974cba5187fe
3a0142cd1f2b66d174436a510044fbeabed7f66b
Pk Recovery
Added methods and test for public key recovery. fixes #101
diff --git a/src/ecdsa/ecdsa.py b/src/ecdsa/ecdsa.py index 755918d9..1aec4108 100644 --- a/src/ecdsa/ecdsa.py +++ b/src/ecdsa/ecdsa.py @@ -57,7 +57,6 @@ from . import ellipticcurve from . import numbertheory - class RSZeroError(RuntimeError): pass @@ -69,6 +68,26 @@ def __init__(self, r, s): self.r = r...
3
3
0
[{"id": "G0", "claim": "PEP-8 requires top-level function and class definitions to be surrounded by two blank lines, but src/ecdsa/ecdsa.py has only one blank line before the new class.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Computing al...
null
tlsfuzzer__python-ecdsa__118
tlsfuzzer/python-ecdsa
118
defect
bcf6afe422a2fb142433e5579908e9d662e28f5e
53783c323acd897f34f011ea2a6d6fdbb4a245be
Support for X9.62 formatted public keys
This is re-working of the PR #54 (which in turn is a reworking of #34). This implements support for the compressed, uncompressed and hybrid format specified in X9.62 and the SEC1 standards http://www.secg.org/sec1-v2.pdf fixes #1, #53 closes #54, #34 I'm not adding documentation as I plan to do that eith...
diff --git a/src/ecdsa/keys.py b/src/ecdsa/keys.py index e56c5d48..54f4751c 100644 --- a/src/ecdsa/keys.py +++ b/src/ecdsa/keys.py @@ -3,7 +3,9 @@ from . import ecdsa from . import der from . import rfc6979 +from . import ellipticcurve from .curves import NIST192p, find_curve +from .numbertheory import square_root_...
1
1
0
[{"id": "G0", "claim": "The exception class added by this PR should be named MalformedPointError instead of MalformedPoint, for consistency with built-in Python exception naming.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tlsfuzzer__python-ecdsa__124
tlsfuzzer/python-ecdsa
124
defect
bb359d32e93acc3eb4d216aff4ba0e7531599cfb
3f4df629ac398e68b503f1a57f5f058287f9e7aa
Backport signature decode
Backport the recent fixes to signature decoding. See #114 also harden the public and private key decoding (partial backport of #118)
diff --git a/ecdsa/der.py b/ecdsa/der.py index b045952f..8afcf23d 100644 --- a/ecdsa/der.py +++ b/ecdsa/der.py @@ -60,10 +60,15 @@ def remove_constructed(string): return tag, body, rest def remove_sequence(string): + if not string: + raise UnexpectedDER("Empty string does not encode a sequence") ...
3
3
0
[{"id": "G0", "claim": "The new ecdsa/test_malformed_sigs.py imports many modules and names it never uses (unittest, os, time, shutil, subprocess, the hash modules, curves, Point, der, rfc6979, copy), so the unused imports should be dropped.", "category": "maintainability", "verdict": "supported", "priority": "P2", "sc...
null
tlsfuzzer__python-ecdsa__138
tlsfuzzer/python-ecdsa
138
defect
4e7f373430e962e8f5c09c6423fa44da621e7201
650a2a8e6dccfc188ab2a377021609f8e5fccbaf
Correct handling of BIT STRING in DER
the first byte of the bit string in DER is the number of unused bits in the bit string, parse it properly and give expected error values if the parsing fails fixes #120 Todo: - [x] fix the loss of coverage for `keys.py`
diff --git a/src/ecdsa/der.py b/src/ecdsa/der.py index 3ed7f6c3..2d2a7a25 100644 --- a/src/ecdsa/der.py +++ b/src/ecdsa/der.py @@ -2,6 +2,7 @@ import binascii import base64 +import warnings from six import int2byte, b, integer_types, text_type @@ -29,8 +30,61 @@ def encode_integer(r): return b("\x02")...
2
2
1
[{"id": "G0", "claim": "The remove_bitstring docstring misspells \"being\" as \"bing\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "encode_bitstring should check the padding of the last byte when unused is non-zero, rather than overriding it.",...
null
tlsfuzzer__python-ecdsa__156
tlsfuzzer/python-ecdsa
156
defect
aa7e7b36b9eedecbbc0698e80ea9d59882e95bed
2848eb8ce45e2d3f0f25b6d4335770794a48f954
Add mutation testing to CI
related to #131 0.14.1: With just 20 mutants executed in 25 minutes, it's not really useful (the confidence interval is way too large) 0.15-beta (8deb089e7d): Single test suite execution takes about 9.97s on Travis, in 25 minutes we execute 107 tests, so better, but that still translates to a 99.9% confidence inte...
diff --git a/.travis.yml b/.travis.yml index 009656c5..8729ca80 100644 --- a/.travis.yml +++ b/.travis.yml @@ -174,12 +174,12 @@ script: cr-report session.sqlite | tail -n 3; done & REPORT_PID=$! - # kill exec after 25 minutes - (sleep $((60*25)); kill $COSMIC_PID) &...
11
1
0
[{"id": "G0", "claim": "The mutation-testing CI runs test suites too slowly (about 6.7s per suite execution), which still means a 99.9% confidence interval of 10 percentage points, so the suites need to get down to around 1s per execution for workable confidence intervals.", "category": "performance", "verdict": "suppo...
null
tlsfuzzer__python-ecdsa__157
tlsfuzzer/python-ecdsa
157
defect
d6cb2886c53923ea7499fb0defc4315f3b3fb9bb
a127819a57fd2480e9f1af591b3c33ef0d22abc6
der: fix encoding and decoding OIDs
make the code handle oids with a large second subidentifier (fixes #155) make the code raise correct exception when the encoded multi-byte subidentifier is missing the last byte move OID test coverage to test_der module and extend it update the OID generators in random DER generator to generate OIDs with lar...
diff --git a/src/ecdsa/der.py b/src/ecdsa/der.py index 187b90bc..7db20f71 100644 --- a/src/ecdsa/der.py +++ b/src/ecdsa/der.py @@ -3,6 +3,7 @@ import binascii import base64 import warnings +from itertools import chain from six import int2byte, b, text_type from ._compat import str_idx_as_int @@ -97,12 +98,10 @@ ...
1
1
0
[{"id": "G0", "claim": "The `b7` in the base-128 subidentifier comment is confusing because the standard uses `b8`, and the comment should unambiguously say most significant bit.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}]
null
tlsfuzzer__python-ecdsa__175
tlsfuzzer/python-ecdsa
175
defect
8deb089e7d5b1836aee9305a8f1258d361c84884
c3de560915d5028275a506a55c404a218407631b
make CurveFp hash()able again
Revert an unfortunate consequence of 79d7d90 making CurveFp unhashable. Fixes #172.
diff --git a/src/ecdsa/ellipticcurve.py b/src/ecdsa/ellipticcurve.py index 82994940..e15d5b0f 100644 --- a/src/ecdsa/ellipticcurve.py +++ b/src/ecdsa/ellipticcurve.py @@ -93,6 +93,9 @@ def __eq__(self, other): and self.__b == other.__b return NotImplemented + def __hash__(self): + return hash((self....
1
1
1
[{"id": "G0", "claim": "The set/dict literals in test_conflation_curves use `{}` syntax unsupported on Python 2.6, so the code needs to be explicit, e.g. `set([c_23, ne1, ne2, ne3])`.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}]
null
tlsfuzzer__python-ecdsa__195
tlsfuzzer/python-ecdsa
195
defect
d2f787ecfe73b92c7db0b0b50f02a6ef9c999944
9d893d68fe4ed5172bb80d7d25f73df4ba68f89b
Add support for PKCS#8 private keys
Closes #113
diff --git a/src/ecdsa/keys.py b/src/ecdsa/keys.py index b9261639..0f3b5bbb 100644 --- a/src/ecdsa/keys.py +++ b/src/ecdsa/keys.py @@ -78,7 +78,13 @@ from .ecdsa import RSZeroError from .util import string_to_number, number_to_string, randrange from .util import sigencode_string, sigdecode_string -from .util import ...
12
11
3
[{"id": "G0", "claim": "from_pem should not carry the duplicated EC-DER/PKCS#8 PEM branch logic just to set one variable (and should still abort on other PEM types like BEGIN RSA PRIVATE KEY, with the forced-format option checking the outside PEM container, not just the inside DER).", "category": "design", "verdict": "...
null
tlsfuzzer__python-ecdsa__199
tlsfuzzer/python-ecdsa
199
defect
a77608426e146feabb3a279486bb86a74ac97236
fc93bd43bc95754c771d974cbde54d84723ded15
🚫🥒 do not pickle the unpickleable RWLock
This is to fix the `can't pickle thread.lock objects` error when attempting to pickle something such as an `ecdsa.keys.VerifyingKey` Alternatively, the custom getstate and setstate could be within the RWLock class.
diff --git a/src/ecdsa/ellipticcurve.py b/src/ecdsa/ellipticcurve.py index c016b8b8..a33d2a4e 100644 --- a/src/ecdsa/ellipticcurve.py +++ b/src/ecdsa/ellipticcurve.py @@ -185,6 +185,15 @@ def __init__(self, curve, x, y, z, order=None, generator=False): doubler = doubler.double().scale() ...
4
4
3
[{"id": "G0", "claim": "The copy made in __getstate__ should acquire the RWLock, since the lock is what keeps the object self-consistent.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Add a test case verifying that the object is pickleable and that...
null
tlsfuzzer__python-ecdsa__205
tlsfuzzer/python-ecdsa
205
defect
14e673d287f0a15846020265d06a8d8b5c7ba3cf
7888c7bdf9425b51e140c35b650e57f0ee345967
Expose allow_truncate option in SigningKey.sign() and VerifyingKey.verify()
PR #168 added the `allow_truncate` option to `SigningKey.sign_digest()` and `VerifyingKey.verify_digest()`, and then forcibly defaulted their value to `True` in [`SigningKey.sign()`](https://github.com/warner/python-ecdsa/pull/168/files#diff-a6539daf3a35718bc7cb90c1395b6953R1138) and [`VerifyingKey.verify()`](https://g...
diff --git a/src/ecdsa/keys.py b/src/ecdsa/keys.py index 89273500..e1ebd884 100644 --- a/src/ecdsa/keys.py +++ b/src/ecdsa/keys.py @@ -602,7 +602,8 @@ def to_der(self, point_encoding="uncompressed"): ) def verify( - self, signature, data, hashfunc=None, sigdecode=sigdecode_string + self, s...
3
3
1
[{"id": "G0", "claim": "The maintainer asks what the use case (or usage scenario) is for not allowing verification of large hashes with small curves, saying he does not understand it well enough to decide whether to restore the pre-0.15 behaviour.", "category": "design", "verdict": "supported", "priority": "P3", "scope...
null
tlsfuzzer__python-ecdsa__223
tlsfuzzer/python-ecdsa
223
defect
bbe36794ae60683b1095098893570360f86c7084
32192592c41f73c1c3d06ea5d6f9497f3ffb2a93
Add support for small curves
finish fixing #197, fix #224 fix #24 because we deduplicate some fairly well-tested code, the overall percentage coverage of `ecdsa.keys` _falls_, making straight-up change fail instrumental testing; add some test coverage for it to counteract it also adds some static test coverage for `is_prime()` to stop the...
diff --git a/src/ecdsa/__init__.py b/src/ecdsa/__init__.py index 4ae0a114..b429e253 100644 --- a/src/ecdsa/__init__.py +++ b/src/ecdsa/__init__.py @@ -19,6 +19,9 @@ BRAINPOOLP320r1, BRAINPOOLP384r1, BRAINPOOLP512r1, + SECP112r1, + SECP112r2, + SECP128r1, ) from .ecdh import ( ECDH, @@ -72...
4
2
0
[{"id": "G0", "claim": "The curve definitions pass -3 for parameter a while the specifications list the full-precision value, and the code should at least carry a comment explaining that equivalence.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "...
null
tlsfuzzer__python-ecdsa__262
tlsfuzzer/python-ecdsa
262
defect
76a9592f7607645b01f33c2bb3e8322708600011
43bb453a6aa9596480e2067e8a7e24ee2315d652
eddsa: add support for point precomputation
Significantly speed up all EdDSA operations by computing multiplication table of the generator point
diff --git a/README.md b/README.md index ccea21cc..340cb493 100644 --- a/README.md +++ b/README.md @@ -110,8 +110,8 @@ On an Intel Core i7 4790K @ 4.0GHz I'm getting the following performance: SECP112r2: 28 0.00015s 6697.11 0.00015s 6479.98 0.00028s 3524.72 0.00058s 1716.16 ...
7
4
1
[{"id": "G0", "claim": "Judged by PointEdwards.__eq__, the new point setter appears to allow replacing the point not only with one carrying a different generator marking but also with one of different order and, possibly, INFINITY, and the reviewer asks whether those cases are OK.", "category": "correctness", "verdict"...
null
tlsfuzzer__python-ecdsa__313
tlsfuzzer/python-ecdsa
313
defect
644412d7a27503fb682e7201c57343f3c43b6640
0edcc812994df273b86f815db66476c22a67969f
Ci updates
Update CI configuration to keep it working fixes #312
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 112719c0..44c169ea 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -47,14 +47,6 @@ jobs: os: ubuntu-18.04 python-version: 2.7 tox-env: gmpy2py27 - - name: py3.3 - os:...
1
1
0
[{"id": "G0", "claim": "Since the PR removes the compatibility implementation of hmac, the hmac_compat wrapper may no longer be needed and could be dropped completely.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tlsfuzzer__python-ecdsa__323
tlsfuzzer/python-ecdsa
323
defect
5db1d2d2c415b25e741c06451dbc72cb44f75e23
f273a51ba158561aac78a995083c6526598dcf86
export to ssh
Initial support for exporting keys in the SSH format as requested in #111. For now it only supports Ed25519 curves but it shouldn't be hard to add additional ones.
diff --git a/src/ecdsa/keys.py b/src/ecdsa/keys.py index 2b7d3168..d77f4fc4 100644 --- a/src/ecdsa/keys.py +++ b/src/ecdsa/keys.py @@ -7,7 +7,7 @@ import os from six import PY2, b from . import ecdsa, eddsa -from . import der +from . import der, ssh from . import rfc6979 from . import ellipticcurve from .curves i...
7
4
3
[{"id": "G0", "claim": "OpenSSH supports only a handful of curves (P-256, P-384, P-521, Ed25519, Ed448), so the SSH export should support all of them, not only Ed25519.", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "to_ssh() should take the SSH comment a...
null
tlsfuzzer__python-ecdsa__329
tlsfuzzer/python-ecdsa
329
defect
0d72435f876efa10155912458a346f3a9760dbfc
0d6c726dcc633bf5620c33e813640f5220754680
remove usage of six.b("literal")
as a side effect the program would maybe run faster
diff --git a/speed.py b/speed.py index 3ed72c49..a3f9e59c 100644 --- a/speed.py +++ b/speed.py @@ -1,4 +1,3 @@ -import six import timeit from ecdsa.curves import curves @@ -43,9 +42,9 @@ def do(setup_statements, statement): ) for curve in [i.name for i in curves]: - S1 = "import six; from ecdsa import Signin...
3
2
0
[{"id": "G0", "claim": "Keep the `six.b(\"\")` line in src/ecdsa/__init__.py unchanged, because it exists to give six a use so that pyflakes is happy.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "In src/ecdsa/test_pyecdsa.py, merge the adjacen...
null
tlsfuzzer__python-ecdsa__61
tlsfuzzer/python-ecdsa
61
defect
04a383c7bc144453593192005b78aba2e989c91e
91140ad7b2840a97184fc31b0aac5b13c15bf22d
Added support for Brainpool r1
Added support for Brainpool r1 curves. I might not have searched hard enough, but can't find the ecdsa test vectors for brainpool curves to add rfc6979 unit tests. Note: requires openssl 1.0.2 fixes #61
diff --git a/ecdsa/curves.py b/ecdsa/curves.py index 5ff53ad9..9a292ce6 100644 --- a/ecdsa/curves.py +++ b/ecdsa/curves.py @@ -43,8 +43,45 @@ def __init__(self, name, curve, generator, oid, openssl_name=None): SECP256k1 = Curve("SECP256k1", ecdsa.curve_secp256k1, ecdsa.generator_secp256k1, ...
9
8
2
[{"id": "G0", "claim": "The tests should detect whether the installed OpenSSL supports the brainpool curves and skip them when it does not.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Test vectors for the new brainpool curves should be added so they ...
null
tlsnotary__tlsn__1027
tlsnotary/tlsn
1,027
defect
5fef2af6988b591819996f42070478157dd022ca
cd416cc2a4cd14dab9dceda16990e13f982e57aa
Make tls_client compatible with a synchronous API
This PR makes `write_plaintext` synchronous and removes some unneeded parts.
diff --git a/crates/tls/client/src/conn.rs b/crates/tls/client/src/conn.rs index 8457c54f77..13aedb84ad 100644 --- a/crates/tls/client/src/conn.rs +++ b/crates/tls/client/src/conn.rs @@ -457,6 +457,9 @@ impl ConnectionCommon { return Err(Error::CorruptMessage); } + // Process outgoing pla...
1
1
1
[{"id": "G0", "claim": "write_all_plaintext's loop can spin forever when the internal buffer does not grow to fit all the plaintext, because write_plaintext copies only up to the buffer limit; it should instead use the method that grows the buffer, as the removed send_plain did with Limit::No.", "category": "correctnes...
null
tlsnotary__tlsn__1036
tlsnotary/tlsn
1,036
defect
f2e119bb669d16648e144dd6dc58b5081c33f19b
6c408856c9ae757111d51dd21decc7fd6228b8fd
refactor: sans-io TLS IO
This PR adds a sans-io api for our prover in the form of a new prover state `Prover<Connected>`.
diff --git a/crates/tls/client-async/src/lib.rs b/crates/tls/client-async/src/lib.rs index c962731eba..ca7ffaacc3 100644 --- a/crates/tls/client-async/src/lib.rs +++ b/crates/tls/client-async/src/lib.rs @@ -197,8 +197,8 @@ pub fn bind_client<T: AsyncRead + AsyncWrite + Send + Unpin + 'static>( ...
15
15
8
[{"id": "G0", "claim": "The Prover's TLS IO methods (read_tls, write_tls, read, write, client_close, server_close) should return ProverError instead of std::io::Error.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Replace the async defer_decryption with...
null
tlsnotary__tlsn__1037
tlsnotary/tlsn
1,037
defect
5fef2af6988b591819996f42070478157dd022ca
126420c8ead4782abe1ff8c2deb5bed779f88ea1
fix(attestation): verify sig during validation
This PR adds the missing verification of the signature during attestation validation. I realized that we can use a simpler approach than what we discussed in https://github.com/tlsnotary/tlsn/pull/794/ Closes: https://github.com/tlsnotary/tlsn/issues/622
diff --git a/crates/attestation/src/request.rs b/crates/attestation/src/request.rs index 250162edf1..a8b51e1a06 100644 --- a/crates/attestation/src/request.rs +++ b/crates/attestation/src/request.rs @@ -20,7 +20,12 @@ use serde::{Deserialize, Serialize}; use tlsn_core::hash::HashAlgId; -use crate::{Attestation, Ex...
1
1
1
[{"id": "G0", "claim": "Request::validate should not instantiate its own default SignatureVerifierProvider, because that prevents users from supporting signature algorithms beyond the ones provided; instead a user-configurable CryptoProvider should be passed in.", "category": "design", "verdict": "supported", "priority...
null
tlsnotary__tlsn__108
tlsnotary/tlsn
108
defect
3c592d9e1b0eb673024b5c48c472206c3f65a69c
02eecad318e45a89e8e81fac760c2c53f00f812e
A2M 2PC
This PR implements an addition-to-multiplication 2pc algorithm. It depends on #106, which needs to be merged first.
diff --git a/Cargo.toml b/Cargo.toml index 62e61f50ee..cd297943ee 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ members = [ "utils-aio", "clmul", "matrix-transpose", - "m2a-2pc" + "gf2-128" ] exclude = ["tls-client"] diff --git a/m2a-2pc/Cargo.toml b/gf2-128/Cargo.toml similarity i...
2
2
1
[{"id": "G0", "claim": "Let's make sure that random != 0, otherwise the security will be broken.", "category": "security", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "A comment should be added explaining that `self.inner() & (1 << i)` extracts the bit of `self.inner()` in po...
null
tlsnotary__tlsn__123
tlsnotary/tlsn
123
defect
6fe6dd9d241eb54aadda181018fbae98880c80e3
b3163527825519e83e2ae5d919e386ba25f94e76
Refactor of gf2_128 crate
This PR refactors `gf2_128` crate into `share-conversion`. This is still a **semi-honest version**, but now provides a `core`-layer and an `aio`-layer. It exposes a general interface for share-conversion and encapsulates the conversion logic.
diff --git a/Cargo.toml b/Cargo.toml index 906aa894f7..2e89a48577 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ members = [ "utils-aio", "clmul", "matrix-transpose", - "gf2-128" + "share-conversion" ] exclude = ["tls-client"] diff --git a/gf2-128/src/lib.rs b/gf2-128/src/lib.rs del...
8
6
2
[{"id": "G0", "claim": "The a2m conversion's handling of a zero `random` should be changed — drop the panic over the 2^-128 case and instead sample from non-zero values, since 0 is an invalid input (it has no inverse) that would leak the sender's share to the receiver.", "category": "correctness", "verdict": "supported...
null
tlsnotary__tlsn__294
tlsnotary/tlsn
294
defect
d1e56787d3799e80b57ed9dec68aefcf8c82a19e
268760c13f4d2021b6e8ab50d1cda674a42beddd
Async tls client fix. New server fixture and tests. Don't rely on close_notify.
This PR: - introduces fixes in tls-client-async and tests. - adds a new tls server fixture (with the existing hyper-based one it was not possible to test certain server behaviour). - does not treat absence of close_notify as an error.
diff --git a/components/tls/Cargo.toml b/components/tls/Cargo.toml index 3c8d5077db..4607e5d4a8 100644 --- a/components/tls/Cargo.toml +++ b/components/tls/Cargo.toml @@ -47,5 +47,8 @@ thiserror = "1" log = "0.4" env_logger = "0.10" +# testing +rstest = "0.12" + # misc derive_builder = "0.12" diff --git a/compone...
5
5
1
[{"id": "G0", "claim": "The `assert!(processed <= received)` added in the select loop should be changed to `debug_assert!` (or its necessity explained).", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The server-close timeout uses tokio::time::sleep,...
null
tlsnotary__tlsn__341
tlsnotary/tlsn
341
defect
407fcb979bb687956b3273833c679a839281ca1f
e2c90fc576b1d1de09a14fa7d73e935ba98848a6
refactor: simplify verifier flow
This PR simplifies the API for non-interactive verifiers. It encapsulates some functionality into `tlsn-core` rather than pushing it out to another crate to handle. We should consider replacing the `Option<Signature>` in `SessionProof` and `SessionData` with just `Signature`. It seems there is no longer any reason w...
diff --git a/tlsn/examples/Cargo.toml b/tlsn/examples/Cargo.toml index 7ba2dd9f37..e7f0d1823c 100644 --- a/tlsn/examples/Cargo.toml +++ b/tlsn/examples/Cargo.toml @@ -28,7 +28,7 @@ tracing.workspace = true tracing-subscriber.workspace = true hyper = { version = "0.14", features = ["client", "http1"] } - +chrono = "...
1
1
0
[{"id": "G0", "claim": "The doc comment on the `session` field of `TlsProof` duplicates the word 'the' in 'commitments to the the transcript'.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tlsnotary__tlsn__355
tlsnotary/tlsn
355
defect
f73376ec93a36183ed991755a3d9209d2bb89a96
5741945266e1fbfde4d695e9209b9af5cba0aef1
Yamux send tls closenotify
Solves https://github.com/tlsnotary/tlsn/issues/288 Needs to merge https://github.com/privacy-scaling-explorations/mpz/pull/68 before this.
diff --git a/components/aead/Cargo.toml b/components/aead/Cargo.toml index 4dbfb723f9..5b2af794bd 100644 --- a/components/aead/Cargo.toml +++ b/components/aead/Cargo.toml @@ -27,7 +27,7 @@ tlsn-stream-cipher = { path = "../cipher/stream-cipher" } tlsn-universal-hash = { path = "../universal-hash" } mpz-core = { git =...
1
1
0
[{"id": "G0", "claim": "The doc comment on UidYamuxControl::close should not say it closes the TLS connection, since UidYamux is not aware of TLS; it should just say it closes the connection.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tlsnotary__tlsn__360
tlsnotary/tlsn
360
defect
1c7273143ed8e2b8d05a5bc53e630b98f64badb4
1dcfd2eb41fb162e9a7e142d29c623da46b7d79b
refactor: tlsn-verifier
This PR renames `tlsn-notary` to `tlsn-verifier` and encapsulates the notary specific functionality. This sets us up to support IZK for selective disclosure by branching to a different state instead of notarizing. # Changes - Rename to `tlsn-verifier` - Move verifier code into `tls` module - Introduce type sta...
diff --git a/components/tls/tls-mpc/src/follower.rs b/components/tls/tls-mpc/src/follower.rs index b7437bb3bc..3eedfae5a2 100644 --- a/components/tls/tls-mpc/src/follower.rs +++ b/components/tls/tls-mpc/src/follower.rs @@ -85,7 +85,7 @@ impl MpcTlsFollower { } /// Performs any one-time setup operations. - ...
5
4
1
[{"id": "G0", "claim": "Rename the Verifier::notarize convenience method to something like `execute_full_notarization` (or `setup_and_notarize`) so the name communicates that it runs the whole notary workflow, since another `notarize` function already exists.", "category": "maintainability", "verdict": "opposed", "prio...
null
tlsnotary__tlsn__368
tlsnotary/tlsn
368
defect
8783a62ea104ee7f5f1591f1dc51d1785128d8b8
e3fbe69361a556e654ea2620cb786f9f605c5822
Add auth middleware, info endpoint to notary server
This PR adds to notary server - auth middleware (optional module that can be turned off) - info endpoint that returns signing pub key and current version - removing session after one-time usage to prevent reuse
diff --git a/notary-server/Cargo.toml b/notary-server/Cargo.toml index 85cd9062ab..43b41fb54d 100644 --- a/notary-server/Cargo.toml +++ b/notary-server/Cargo.toml @@ -10,6 +10,8 @@ axum = { version = "0.6.18", features = ["ws"] } axum-core = "0.3.4" axum-macros = "0.3.8" base64 = "0.21.0" +chrono = "0.4.31" +csv = "...
9
5
3
[{"id": "G0", "claim": "The whitelist file is only loaded at startup, so adding or removing entries requires a server restart; a better solution such as a persistent DB that allows hot editing should be used in the future.", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": ...
null
tlsnotary__tlsn__387
tlsnotary/tlsn
387
defect
61528833cdd1016644453d3bd28ce82fcf8b6266
7476ebe4a0eb7dd52675107491878f394a2b9aca
Make tls optional between prover and notary.
To cater for the case when tls is handled by external setup like reverse proxy or in cloud environment.
diff --git a/notary-server/config/config.yaml b/notary-server/config/config.yaml index 9d917cfbee..7efd88b268 100644 --- a/notary-server/config/config.yaml +++ b/notary-server/config/config.yaml @@ -6,7 +6,8 @@ server: notarization: max-transcript-size: 16384 -tls-signature: +tls: + enabled: true private-key-...
3
3
0
[{"id": "G0", "claim": "The nested match/if structure handling the accepted prover connection is hard to read and should be flattened, e.g. with `if let` and/or `map_err`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The PR includes whitelist-...
null
tlsnotary__tlsn__416
tlsnotary/tlsn
416
defect
84bd7966fef6ed17feb0b789fdc0b62ff69aa991
54d8f263a76b705ba15ded459c290ed82d33e882
feat: deferred decryption
This PR implements so-called "deferred decryption", and advanced feature which significantly reduces upload bandwidth utilization by the Prover. This should provide much faster proving times. There is a remaining issue with this feature related to detecting when all the application data has been received while we ar...
diff --git a/components/tls/tls-backend/Cargo.toml b/components/tls/tls-backend/Cargo.toml index 9dc62221bf..8df8ba4f8a 100644 --- a/components/tls/tls-backend/Cargo.toml +++ b/components/tls/tls-backend/Cargo.toml @@ -17,3 +17,4 @@ name = "tls_backend" tlsn-tls-core = { path = "../tls-core" } async-trait.workspace =...
25
20
0
[{"id": "G0", "claim": "BackendNotify's FusedFuture impl always returns false from is_terminated, which the reviewer says violates the contract that it should return true once Poll::Ready has been returned.", "category": "correctness", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim"...
null
tlsnotary__tlsn__422
tlsnotary/tlsn
422
defect
f9f4a08b6ea08381d0bc6116aea3d06108532234
415bdc2ff11259562bc202d8adb0f56deb9553bf
Use logging filter, remove otel.
This addresses https://github.com/tlsnotary/tlsn/issues/412 - ~Switched from using config file to indicate log verbosity level to using RUST_LOG env var which is much more flexible~ - Removed opentelemetry setup code which is flooding the logs with `SpanData` struct because it was temporarily setup to export to std...
diff --git a/notary-server/Cargo.toml b/notary-server/Cargo.toml index a62e0b9dd8..766b01ac08 100644 --- a/notary-server/Cargo.toml +++ b/notary-server/Cargo.toml @@ -28,8 +28,7 @@ serde_yaml = "0.9.21" sha1 = "0.10" structopt = "0.3.26" thiserror = "1" -tlsn-verifier = { path = "../tlsn/tlsn-verifier" } -tlsn-tls-c...
2
2
1
[{"id": "G0", "claim": "The README section added by this PR should be called `Logging` instead of `Debugging`.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The notary's default logging filter directive shown in the README includes `tls_client_as...
null
tlsnotary__tlsn__451
tlsnotary/tlsn
451
defect
2372403d386d72cd98929e69ce0d025420de8882
e9cfeef80792d9df8f0d9d69d38ab215a391232a
interactive verifier example
Example for the interactive verifier. To the reviewers: please check the code, structure and comments. I expect people to copy this code and use it as a template for getting started.
diff --git a/components/tls/tls-client/src/backend/standard.rs b/components/tls/tls-client/src/backend/standard.rs index afd6b7adb0..bfa843e1dc 100644 --- a/components/tls/tls-client/src/backend/standard.rs +++ b/components/tls/tls-client/src/backend/standard.rs @@ -9,7 +9,7 @@ use p256::{ecdh::EphemeralSecret, Encoded...
6
6
1
[{"id": "G0", "claim": "The openapi.yaml descriptions for maxSentData and maxRecvData should say bytes, not bits.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The comments in the example should be formatted per the project style guide (capitalis...
null
tlsnotary__tlsn__458
tlsnotary/tlsn
458
defect
19e9c50f3578efb75072b8ad30d87e863791f311
746d3800daf772f811e3db634986ca409d9db680
Add api key whitelist hot reloading and small touch-up
This PR mainly adds hot reloading capability of api key whitelist, i.e. modification of the whitelist file will be automatically applied without needing to restart the server. There are also some small touchups on the code - Make static html returned from root endpoint configurable by notary server operator - Rem...
diff --git a/notary-server/Cargo.toml b/notary-server/Cargo.toml index 59aab50714..5215f19b12 100644 --- a/notary-server/Cargo.toml +++ b/notary-server/Cargo.toml @@ -17,6 +17,7 @@ futures = "0.3" futures-util = "0.3.28" http = "0.2.9" hyper = { version = "0.14", features = ["client", "http1", "server", "tcp"] } +no...
1
1
1
[{"id": "G0", "claim": "The authorization whitelist should use a sync mutex instead of an async one, since it is never held across an await point.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
tlsnotary__tlsn__489
tlsnotary/tlsn
489
defect
23450a3d38c751d859a34aadbd38e2637b1f738e
f8b0c9499f4d1c99b2f5bdb53afc73e2513610c7
Add notary client crate
Addressed https://github.com/tlsnotary/tlsn/issues/443, where - Examples and notary server integration test now use this notary client crate - Added a test in notary integration test to test auth module - Some unused dependencies are removed Another PR will follow to migrate this notary client crate to the nota...
diff --git a/notary-server/Cargo.toml b/notary-server/Cargo.toml index 865af7baa8..daccb6cf05 100644 --- a/notary-server/Cargo.toml +++ b/notary-server/Cargo.toml @@ -20,9 +20,7 @@ http-body-util = "0.1" hyper = { version = "1.1", features = ["client", "http1", "server"] } hyper-util = {version = "0.1", features = ["...
27
26
4
[{"id": "G0", "claim": "Make the crate's modules private and export the public structs at the lib root.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Make the client error opaque to the user (an opaque ClientError with a private error-kind enum) instead...
null
tlsnotary__tlsn__573
tlsnotary/tlsn
573
defect
d179150c39092c0ac60075c26699cc85528f842f
bbe16d952dca658dc4af787cb4a70ec71bda50b8
Make defer-decryption default
This PR makes defer-decryption default and introduces the necessary config changes.
diff --git a/crates/benches/bin/prover.rs b/crates/benches/bin/prover.rs index 48166e49b6..f4a8860dbe 100644 --- a/crates/benches/bin/prover.rs +++ b/crates/benches/bin/prover.rs @@ -117,11 +117,20 @@ async fn run_instance<S: AsyncWrite + AsyncRead + Send + Sync + Unpin + 'static> let start_time = Instant::now()...
5
5
4
[{"id": "G0", "claim": "The transcript size configs should default to 0 and the builder should return an error if both the online and deferred sizes are set to 0, making the benchmark's explicit `max_deferred_size(0)` unnecessary.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"},...
null
tlsnotary__tlsn__589
tlsnotary/tlsn
589
defect
3554db83e17b2e5fc98293b397a2907b7f023496
8429035b4dec24d96ed3763874e53734d9a24972
Make TLS and Authorization Configuration Fields Optional
This pull request fixes #565 where the TLSNotary server fails to start when specific configuration fields (`private_key_pem_path`, `certificate_pem_path`, and `whitelist_csv_path`) are missing, even when the corresponding features are disabled. Please review and provide feedback!
diff --git a/notary/integration-tests/tests/notary.rs b/notary/integration-tests/tests/notary.rs index bc9bb74e75..34f1712632 100644 --- a/notary/integration-tests/tests/notary.rs +++ b/notary/integration-tests/tests/notary.rs @@ -47,8 +47,8 @@ fn get_server_config(port: u16, tls_enabled: bool, auth_enabled: bool) -> N...
5
5
4
[{"id": "G0", "claim": "The new NotaryServerError::ConfigurationError variant is unnecessary for this configuration check; use `eyre!` (which is converted into `Unexpected`) instead, since these error enums are mainly for error scenarios after the notary server has booted.", "category": "design", "verdict": "supported"...
null
tlsnotary__tlsn__639
tlsnotary/tlsn
639
defect
b3f79a9e2b21dc24eb8d8762e536f5435f928315
994c4d4f8e8527e0bbc1043489369d0a9ed0b477
fix(notary): implement timeout for notarization
Putting a timeout for each notarization task to prevent it from hanging when prover doesn't notify notary to stop or err; else it might lead to unreleased memory piling up
diff --git a/crates/notary/server/src/service.rs b/crates/notary/server/src/service.rs index dd93d36157..c131ed8318 100644 --- a/crates/notary/server/src/service.rs +++ b/crates/notary/server/src/service.rs @@ -2,8 +2,6 @@ pub mod axum_websocket; pub mod tcp; pub mod websocket; -use std::sync::Arc; - use async_tra...
1
1
0
[{"id": "G0", "claim": "The hardcoded NOTARIZATION_TIMEOUT_SECONDS constant should be moved into the notary server's configuration.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tlsnotary__tlsn__719
tlsnotary/tlsn
719
defect
4d5102b6e141ecb84b8a835604be1d285ae6eaa5
9b8c89564e3d431751eeeddb796ea6ec6d17b1b0
Make logging format configurable
Log collector tools want to consume logs in JSON format. This PR adds support for it. You can now set logging.format to json in toml config file in notary server and instead of this: ``` 2025-03-10T10:34:03.339984Z DEBUG main ThreadId(01) run_server: notary_server::server: Loading notary server's signing key 2025-0...
diff --git a/crates/notary/server/Cargo.toml b/crates/notary/server/Cargo.toml index e2e1087e0e..12462eb836 100644 --- a/crates/notary/server/Cargo.toml +++ b/crates/notary/server/Cargo.toml @@ -45,7 +45,7 @@ tower-http = { version = "0.5", features = ["cors"] } tower-service = { version = "0.3" } tower-util = { vers...
2
2
1
[{"id": "G0", "claim": "Add a sentence to the notary-server README's Logging section mentioning the new `format` option added by this PR.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "crates/notary/tests-integration appears broken (its tests do n...
null
tlsnotary__tlsn__770
tlsnotary/tlsn
770
defect
93535ca9552a536618e5d1faedd697ce616c7de2
e7fac7d81bb0c9f32541f430a49321fd5c10754d
feat(notary): add concurrency limit
This PR adds adds a concurrency limit feature to the notary server allowing it to limit the number of concurrent notarizations. This PR does not implement any queueing mechanism. Instead the client retries the request until it is accepted. There are many ways to implement queueing with different trade-offs and I le...
diff --git a/crates/notary/client/Cargo.toml b/crates/notary/client/Cargo.toml index 1bcb32e1e3..e0314fcfab 100644 --- a/crates/notary/client/Cargo.toml +++ b/crates/notary/client/Cargo.toml @@ -3,6 +3,10 @@ name = "notary-client" version = "0.1.0-alpha.10-pre" edition = "2021" +[features] +# Exposes some API which...
9
9
3
[{"id": "G0", "claim": "The timeout and retry configuration should be exposed directly rather than hidden behind the test-api feature, since setting the durations seems useful.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The reviewer questions whether...
null
tlsnotary__tlsn__806
tlsnotary/tlsn
806
defect
9e0f79125b3c478e30e7c518c8e16797212e06ae
24005e4436c64a1f006b1470076f4effe596ce9a
chore: bump mpz to alpha.3
This PR bumps mpz to alpha.3 and fixes breaking changes.
diff --git a/Cargo.toml b/Cargo.toml index f27d7350d9..cd3aa84495 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,8 +8,8 @@ members = [ "crates/common", "crates/components/deap", "crates/components/cipher", - "crates/components/hmac-sha256", - "crates/components/hmac-sha256-circuits", + #"crates/...
2
1
0
[{"id": "G0", "claim": "The mpz dependencies should be pinned to a v0.1.0-alpha.3 tag rather than the alpha.3 branch, which can be created once the alpha.3 branch is merged back into mpz's dev branch.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim"...
null
tlsnotary__tlsn__819
tlsnotary/tlsn
819
defect
96d19fe65356f866e44901250211880b25c83f27
6c6ae69b6f4652a3f5d6f57adc0abd31849aed79
fixture removal + generate signing key
- generate signing key if not provided - migrate fixture to test crate - removes redundant code from tee module - derive pub key from provided signing key
diff --git a/crates/notary/server/Cargo.toml b/crates/notary/server/Cargo.toml index 8f4399bda0..0e37a22c3d 100644 --- a/crates/notary/server/Cargo.toml +++ b/crates/notary/server/Cargo.toml @@ -9,13 +9,7 @@ workspace = true [features] tee_quote = [ "dep:mc-sgx-dcap-types", - "dep:hex", - "dep:rand", - "dep:rand06-...
5
4
1
[{"id": "G0", "claim": "The quote call should pass `public_key.to_compressed_bytes()` instead of `public_key_bytes`.", "category": "correctness", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The ephemeral signing key's algorithm should be configurable through config rather th...
null
tlsnotary__tlsn__871
tlsnotary/tlsn
871
defect
33c4b9d16ff6500242d8934d80ea587452f453c3
10e9fdeec1593721851e9c1a07724cc75d857175
misc(notary): add common crate for server and client
Closes https://github.com/tlsnotary/tlsn/issues/777
diff --git a/Cargo.lock b/Cargo.lock index df03a5ac1a..8fd92318a3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1220,12 +1220,6 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" -[[package]] -name = "bas...
2
2
0
[{"id": "G0", "claim": "The new ClientType enum could derive Copy — asked whether that is wanted.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "NotarizationSessionRequest could likewise derive Copy, as suggested in reply to the ClientType Copy question....
null
tmc__langchaingo__1061
tmc/langchaingo
1,061
defect
238d1c713de3ca983e8f6066af6b9080c9b0e088
2589eec221a13953b7325a0e1d3b676d0e588cb9
tools: add perplexity AI
This PR enables AI Agents to use perplexity AI in order to retrieve data from the web. I'm not affiliated with Perplexity. ### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.c...
diff --git a/tools/perplexity/README.md b/tools/perplexity/README.md new file mode 100644 index 000000000..59628f175 --- /dev/null +++ b/tools/perplexity/README.md @@ -0,0 +1,62 @@ + +# Perplexity Tool Integration for Agents + +Use perplexity in your AI Agent to enrich it with data from the web. + +Full code example: +...
10
9
2
[{"id": "G0", "claim": "The package documentation in README.md should live in a doc.go file instead.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The exported struct should be named Tool instead of Perplexity to avoid perplexity.Perplexity red...
null
tmc__langchaingo__1086
tmc/langchaingo
1,086
defect
238d1c713de3ca983e8f6066af6b9080c9b0e088
50c4eae3d98d39d6ce68a12e24ea99c036aa0811
llms/mistral: Implementing embeddings.EmbedderClient for Mistral and an example with PGVector
This PR implements the embeddings.EmbedderClient interface for mistral, using the "mistral-embed" model. There is an example, heavily inspired by the `openai-embeddings-example` of how it can be used with pgvector. ### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blo...
diff --git a/examples/mistral-embedding-example/go.mod b/examples/mistral-embedding-example/go.mod new file mode 100644 index 000000000..01d1fe27e --- /dev/null +++ b/examples/mistral-embedding-example/go.mod @@ -0,0 +1,22 @@ +module github.com/tmc/langchaingo/examples/mistral-embedding-example + +go 1.22.0 + +toolchai...
7
6
0
[{"id": "G0", "claim": "The ConvertFloat64ToFloat32 helper does not need to be exported.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The inline \"empty embeddings\" error could be an exported error variable (var ErrEmptyEmbeddings).", "catego...
null
tmc__langchaingo__1121
tmc/langchaingo
1,121
defect
9173fef6ecd15230e46979f6613ddb88c3c99adc
1bea9fbb7c4257f40fcb327ffb5792089f3dba78
Add ReasoningContent field for deepseek-reasoner model
I added ReasoningContent field for deepseek-reasoner model based on these official DeepSeek docs: https://api-docs.deepseek.com/api/list-models ### PR Checklist - [X] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [X] Read the [Code of conduct documentation...
diff --git a/examples/deepseek-completion-example/deepseek-completion-example.go b/examples/deepseek-completion-example/deepseek-completion-example.go new file mode 100644 index 000000000..d1fee8f5e --- /dev/null +++ b/examples/deepseek-completion-example/deepseek-completion-example.go @@ -0,0 +1,50 @@ +package main + ...
2
2
1
[{"id": "G0", "claim": "The TestParseStreamingChatResponse_ReasoningContent test added by this pull request is failing and the author should look at it.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "The doc comments on the new ReasoningContent fiel...
null
tmc__langchaingo__1125
tmc/langchaingo
1,125
defect
0672790bb23a2c7e546a4a7aeffc9bef5bbd8c0b
b6ce64d497497fcb335c589cd769cbf107e440e2
llms: implement StreamingReasoningFunc for reasoning models
### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.com/tmc/langchaingo/blob/main/CODE_OF_CONDUCT.md). - [x] Name your Pull Request title clearly, concisely, and prefixed with the n...
diff --git a/llms/openai/internal/openaiclient/chat.go b/llms/openai/internal/openaiclient/chat.go index 74ca0d844c..42401eb440 100644 --- a/llms/openai/internal/openaiclient/chat.go +++ b/llms/openai/internal/openaiclient/chat.go @@ -67,6 +67,10 @@ type ChatRequest struct { // Return an error to stop streaming early...
2
1
1
[{"id": "G0", "claim": "The line appending the streamed reasoning content should use += on choice.Delta.ReasoningContent instead of overwriting it, and the reviewer asks the author to fix this typo.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The...
null
tmc__langchaingo__612
tmc/langchaingo
612
defect
fcd78c9e5301e089216169926787c41d37f13c83
29f06e922e1bc5d5c4bb18fca78e0eb50e1f9723
tool: sql_database generate sql-query filter redundant text
fix: using sql_database tool generate sql-query sometimes contain unexpected redundant text illusion information like this: ```md SQLQuery: SELECT MAX(code) AS max_code FROM example_table; SQLResult: 3 (illusion data) Answer: There are 3 data in the table. (illusion data) ``` It should only contain sql syntax as...
diff --git a/chains/sql_database.go b/chains/sql_database.go index 9a75608ad..215957947 100644 --- a/chains/sql_database.go +++ b/chains/sql_database.go @@ -112,7 +112,12 @@ func (s SQLDatabaseChain) Call(ctx context.Context, inputs map[string]any, optio if err != nil { return nil, err } - sqlQuery := strings.Tr...
2
2
1
[{"id": "G0", "claim": "The new SQL-query extraction logic added by the pull request needs a test case.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Instead of building test cases via named parameters (helper functions), the cases should be inlined wi...
null
tmc__langchaingo__668
tmc/langchaingo
668
defect
24cb833284c31f02f42603c84739ccc1a9fe216d
c75567294b845d7019253b3d5f61385c25c35b4c
documentloaders: add AssemblyAI document loader
This PR adds the AssemblyAI document loader from [LangChain](https://github.com/langchain-ai/langchain/blob/master/libs/community/langchain_community/document_loaders/assemblyai.py) and [LangChain JS](https://github.com/langchain-ai/langchainjs/blob/main/langchain/src/document_loaders/web/assemblyai.ts). Unfortunate...
diff --git a/.golangci.yaml b/.golangci.yaml index e972ef25f..860de57f3 100644 --- a/.golangci.yaml +++ b/.golangci.yaml @@ -30,6 +30,8 @@ linters: - ireturn # disabling temporarily linters-settings: + cyclop: + max-complexity: 12 funlen: lines: 90 depguard: diff --git a/documentloaders/assemblya...
2
2
1
[{"id": "G0", "claim": "The GitHub workflow does not use the .golangci.yaml configuration, so running it locally surfaces ~13 linter errors across the codebase; the dev/CI linting setup needs addressing.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "c...
null
tmc__langchaingo__679
tmc/langchaingo
679
defect
dc3e6f668603a8d63f99ef5bb3a47093ac2ae835
38decb3881799d1940dc3ddc9b1c051606bedc57
llms/cloudflare: Implement Cloudflare Workers AI LLM
### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.com/tmc/langchaingo/blob/main/CODE_OF_CONDUCT.md). - [x] Name your Pull Request title clearly, concisely, and prefixed with the n...
diff --git a/examples/ernie-function-call-example/ernie_function_call_example.go b/examples/ernie-function-call-example/ernie_function_call_example.go index 5f222a08a..b02f38ea8 100644 --- a/examples/ernie-function-call-example/ernie_function_call_example.go +++ b/examples/ernie-function-call-example/ernie_function_cal...
3
2
0
[{"id": "G0", "claim": "The PR touches unrelated files (formatting only) and the author asks whether to revert them to keep the change isolated to the new Cloudflare code.", "category": "maintainability", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The Client method receivers ...
null
tmc__langchaingo__762
tmc/langchaingo
762
defect
a47ef5033a91f6fbf32f89d8c57dee4da524b4d3
d588e19d3df1b36759bc066612cda56648966806
llms: Maritaca AI
### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.com/tmc/langchaingo/blob/main/CODE_OF_CONDUCT.md). - [x] Name your Pull Request title clearly, concisely, and prefixed with the n...
diff --git a/llms/maritaca/internal/maritacaclient/maritacaclient.go b/llms/maritaca/internal/maritacaclient/maritacaclient.go new file mode 100644 index 000000000..f523041b6 --- /dev/null +++ b/llms/maritaca/internal/maritacaclient/maritacaclient.go @@ -0,0 +1,150 @@ +package maritacaclient + +import ( + "bufio" + "by...
2
1
0
[{"id": "G0", "claim": "The doc comments on the option functions in llms/maritaca/options.go should start with the name of the function being documented.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The examples/maritaca-example should have a go...
null
tmc__langchaingo__787
tmc/langchaingo
787
defect
8707e51a48a1a85e4d3086a644a92b146a1623d2
4eb5217d09a1296fed48e8f531762d6250ad657e
feat(ollama): support 'keep_alive' parameter
### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.com/tmc/langchaingo/blob/main/CODE_OF_CONDUCT.md). - [x] Name your Pull Request title clearly, concisely, and prefixed with the n...
diff --git a/llms/ollama/internal/ollamaclient/types.go b/llms/ollama/internal/ollamaclient/types.go index fe6596270..87d1ecb7d 100644 --- a/llms/ollama/internal/ollamaclient/types.go +++ b/llms/ollama/internal/ollamaclient/types.go @@ -27,12 +27,13 @@ func (e StatusError) Error() string { } type GenerateRequest st...
1
1
0
[{"id": "G0", "claim": "The WithKeepAlive doc comment's example uses the wrong unit for hours: \"hr\" should be \"h\", since ollama rejects \"hr\" with a time parse error.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tmc__langchaingo__903
tmc/langchaingo
903
defect
6a285bf22b35dbd6b1d6ce289572982385274531
b286844bdae038073d6ed4a939988a15da24d0ac
llms/googleai: fix convert tool error
### PR Checklist - [x] Read the [Contributing documentation](https://github.com/tmc/langchaingo/blob/main/CONTRIBUTING.md). - [x] Read the [Code of conduct documentation](https://github.com/tmc/langchaingo/blob/main/CODE_OF_CONDUCT.md). - [x] Name your Pull Request title clearly, concisely, and prefixed with the n...
diff --git a/llms/googleai/googleai.go b/llms/googleai/googleai.go index 1d8f5bb1e..468c9a388 100644 --- a/llms/googleai/googleai.go +++ b/llms/googleai/googleai.go @@ -415,16 +415,21 @@ func convertTools(tools []llms.Tool) ([]*genai.Tool, error) { } if required, ok := params["required"]; ok { - ri := require...
2
1
1
[{"id": "G0", "claim": "The added []interface{} branch in convertTools is unnecessary and overcomplicated — a comma-ok assertion that `required` is a []string, returning an error otherwise, should be enough.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "P...
null
tmm1__rblineprof__5
tmm1/rblineprof
5
defect
ee7766dc654250f79b6a6969f7f5891f214e7fe4
f0b645a70d88e07299aad38321fc9ab8f8fd5b80
WIP — Start on 1.9 support
WIP, taking a fast crack at adding 1.9 support. cc @tmm1, please feel free to add shit to this at will
diff --git a/ext/extconf.rb b/ext/extconf.rb index 31e3c31..3ec759f 100644 --- a/ext/extconf.rb +++ b/ext/extconf.rb @@ -1,2 +1,40 @@ require 'mkmf' -create_makefile 'rblineprof' +require 'fileutils' + +if RUBY_VERSION >= "1.9" + begin + require "debugger/ruby_core_source" + rescue LoadError + require 'rubygem...
5
3
2
[{"id": "G0", "claim": "On Ruby 1.9 the profiler stores per-line times on different (shifted) lines than on 1.8.7, so line attribution in summarize_files is off.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The removed rb_source_filename(...) call...
null
tmux-python__tmuxp__639
tmux-python/tmuxp
639
defect
646985754ce1be6f5275c981d124feb27c103383
764f25167d459b09bf72459aad4afcb0b18cb508
Bug start directory
`start_directory` was not being passed through when creating a new session. Issue: https://github.com/tmux-python/tmuxp/issues/631
diff --git a/pyproject.toml b/pyproject.toml index 0f331e75f6..606c83f3f8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,7 @@ skip-string-normalization = true [tool.poetry] name = "tmuxp" -version = "1.5.7post0" +version = "1.5.7post1" description = "tmux session manager" license = "MIT" authors = [...
2
1
0
[{"id": "G0", "claim": "The release version should be 1.5.8 instead of 1.5.7post1, and tony also asks that CHANGES be updated so he can publish immediately.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "A test should be written for the new start_...
null
tmux-python__tmuxp__647
tmux-python/tmuxp
647
defect
88581798ed0d3541a7b4a3574614120d65f7ddeb
d6c138307d7c0f61fa606ca62bef7b09304d2d77
Add --log-file option to load command
Adding the `--log-file` option to the `load` command. (As discussed over email. There isn't a specific issue for the addition)
diff --git a/CHANGES b/CHANGES index fcc69453b0..a428aa4b3a 100644 --- a/CHANGES +++ b/CHANGES @@ -6,6 +6,7 @@ Here you can find the recent changes to tmuxp current ------- +- Adding option to dump `load` output to log file - *Insert changes/features/fixes for next release here* tmuxp 1.6.2 (2020-11-08) diff --...
4
3
0
[{"id": "G0", "claim": "Add an ability to control the log level, which the reviewer does not think is currently available.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The log file output contains ANSI color escape codes that make it hard to read as text...
null
tmux-python__tmuxp__845
tmux-python/tmuxp
845
defect
d63f9f55bcd5644ce2c0e63d4da64f1afa927e6e
3a3362d381121a7788cab325969218b74f63ea03
feat(builder): allow environments for windows and panes
This fixes #832. Open question: what's the intended/desired fallback behavior? 1. (Currently implemented) If a pane doesn't have a `environment` configuration it uses the `environment` configuration of the window. This means that in order to change one environment variable (compared to the window) the full `envir...
diff --git a/CHANGES b/CHANGES index 3261ec59af..78c152ec0e 100644 --- a/CHANGES +++ b/CHANGES @@ -17,7 +17,28 @@ $ pipx install --suffix=@next 'tmuxp' --pip-args '\--pre' --force ## tmuxp 1.19.x (unreleased) -- Notes on upcoming releases will be added here +### What's new + +- #845: allow to configure window and ...
4
3
2
[{"id": "G0", "claim": "To help users see the value of the contribution, add a configuration example, mention the new functionality in the changelog, and note that window/pane environments are only available in versions 1.19 and beyond.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "...
null
tmux-python__tmuxp__959
tmux-python/tmuxp
959
defect
425bf3c80eeba862fba2a1e912bfe16683a0b108
91cac7e009aa3cc728cd1d04e62c758985f6078e
Fix `run_before_script()` output capturing
tmuxp 1.52.0's before scripts print out a lot of newlines. ## Summary by Sourcery Bug Fixes: - Fix issue where before scripts output was not being captured correctly.
diff --git a/src/tmuxp/util.py b/src/tmuxp/util.py index 893b73d379..bac9093ed1 100644 --- a/src/tmuxp/util.py +++ b/src/tmuxp/util.py @@ -28,41 +28,72 @@ def run_before_script( script_file: str | pathlib.Path, cwd: pathlib.Path | None = None, ) -> int: - """Execute a shell script, wraps :meth:`subprocess...
1
1
0
[{"id": "G0", "claim": "Tests should be added where `isatty()` returns `False` for both stdout and stderr to ensure `run_before_script()` behaves correctly in non-interactive environments.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
tobgu__qframe__39
tobgu/qframe
39
defect
a7709325db65752c14bd333fd97f80b337d5668d
e2504b5e3c3d1d5c3d5ec7eea3e5425ae9feac70
WIP Enhance CSV Capabilities
Read CSVs with Empty column names Read CSVs with Duplicate Column names. This is to fix #34
diff --git a/config/csv/config.go b/config/csv/config.go index 6a8bf7f..9e5fcc0 100644 --- a/config/csv/config.go +++ b/config/csv/config.go @@ -33,6 +33,31 @@ func EmptyNull(emptyNull bool) ConfigFunc { } } +// MissingColumnNameAliasString set configs to rename empty column name with given string +// ,COL2 //...
17
16
3
[{"id": "G0", "claim": "The new config handling gives the user no control over how empty and duplicate column names are renamed (one opaque flag does both jobs and its name gives no hint), so the handling should move into caller-controlled configuration such as a policy function on Config, or a settable alias string fo...
null
tobgu__qframe__4
tobgu/qframe
4
defect
8f2cbf95077d3c541bce87f99310352ebf1d5e51
3dc2eceae07dc360ff4d54a3085a3fad19990e79
add primitive sql support
Hi -- Congratulations on writing such an awesome, well-designed, idiomatic Go library! I made an initial attempt at supporting IO from the standard `database/sql` library; there are definitely some things missing in the code as it exists now but wanted to create a PR and get some feedback. Thank you!
diff --git a/README.md b/README.md index e369e3a..232e216 100644 --- a/README.md +++ b/README.md @@ -25,8 +25,11 @@ in any way. For a complete description of all operations including more examples see the [docs](https://godoc.org/github.com/tobgu/qframe). ### IO -QFrames can currently be read from and written to CS...
14
14
3
[{"id": "G0", "claim": "Errors returned by the new SQL code should be annotated with the qframe errors package (e.g. errors.New(\"ReadSQL Columns\", err.Error())) instead of returned bare, and this should be applied everywhere errors are returned.", "category": "maintainability", "verdict": "supported", "priority": "P2...
null
tobgu__qframe__41
tobgu/qframe
41
defect
aedcf9a281591490987eddb54e11c41850fd77bf
d5fabfdeb100cb5604a948c5d790e7f280c94f1c
Support supplying args when executing query
Thank you for an awesome Go dataframe library to work with! While looking to create a QFrame via SQL, I noticed that queries did not support supplying arguments to prepared statements. As supplying arguments to prepared statements is one tool to help prevent against SQL injection, I could not use ReadSQL as it curre...
diff --git a/qframe.go b/qframe.go index 9b6d46a..c4fc98a 100644 --- a/qframe.go +++ b/qframe.go @@ -1067,6 +1067,11 @@ func ReadJSON(reader io.Reader, confFuncs ...newqf.ConfigFunc) QFrame { // ReadSQL returns a QFrame by reading the results of a SQL query. func ReadSQL(tx *sql.Tx, confFuncs ...qsql.ConfigFunc) QF...
1
1
0
[{"id": "G0", "claim": "The doc comment above ReadSQLWithArgs says \"ReadSQLPreparedreturns\", which does not match the actual function name.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
tobgu__qframe__47
tobgu/qframe
47
defect
6edc7a20da2c4e09738f26581adcaa1c66013afb
730e33f7ddb758991d6579a3de00f33e8058aeef
ToConfig with columns order for CSV
- Added new ToConfig to force order of columns in CSV. - Added tests for new ToConfig.
diff --git a/config/csv/config.go b/config/csv/config.go index 01207bb..199da06 100644 --- a/config/csv/config.go +++ b/config/csv/config.go @@ -141,3 +141,10 @@ func Header(header bool) ToConfigFunc { c.Header = header } } + +// Columns holds the order to write CSV columns. +func Columns(cols []string) ToConfigF...
1
1
0
[{"id": "G0", "claim": "The column-mapping loop in ToCSV could be shorter and more idiomatic: pre-set the slice length instead of appending, use a range expression instead of a counted for, and use camelCase for the column-name variable.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope"...
null
tobgu__qframe__6
tobgu/qframe
6
defect
f611467887a3d43a21ce37042603b63074830477
3b0576908a99636dc84590ecbc5c0d43865d87c4
Strong Typing & Misc Improvements
Hi -- I've made a few improvements to the QFrame library and added some new functionality. Happy to continue working on this branch based on feedback or potentially close it and take different approach. #### Stronger Typing I changed the code generation to propagate `types.DataType` constants when calling Colu...
diff --git a/Makefile b/Makefile index d5ef102..fef9039 100644 --- a/Makefile +++ b/Makefile @@ -23,4 +23,4 @@ deps: go get -t ./... dev-deps: deps - go get github.com/cheekybits/genny + go get github.com/mauricelam/genny diff --git a/examples_test.go b/examples_test.go index ac98ccf..5bca81a 100644 --- a/examples...
6
6
2
[{"id": "G0", "claim": "The doc comments on the new Columns, ColumnTypes and ColumnTypeMap methods are malformed: a blank line instead of '// ' separates the summary sentence from the comment, so the summary is not part of the doc comment.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope"...
null
tobymao__sqlglot__5796
tobymao/sqlglot
5,796
defect
eca65e8b79f65850b014a4cb7913ba4a5861dbe9
1ba98fb1e9869741311b67e53529a3df55049292
fix(hive): DATE_SUB to DATE_ADD use parens if needed
Fixes #5794
diff --git a/sqlglot/dialects/hive.py b/sqlglot/dialects/hive.py index 699751abe2..0f3d856fa0 100644 --- a/sqlglot/dialects/hive.py +++ b/sqlglot/dialects/hive.py @@ -194,6 +194,18 @@ def _build_to_date(args: t.List) -> exp.TsOrDsToDate: return expr +def _build_date_add(args: t.List) -> exp.TsOrDsAdd: + exp...
1
1
0
[{"id": "G0", "claim": "The DATE_SUB builder could simply use `expression * -1` (Expression::__mul__/_binop) instead of manually wrapping binary expressions in parens and constructing exp.Mul, since the magic method takes care of both.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduc...
null
tobymao__sqlglot__5804
tobymao/sqlglot
5,804
defect
faf9ef15e4096864de5faff15a0f499458a7b098
9b5219f9a61af5d20a7f3e681ef4f5b65e01c594
fix(duckdb): transpile joins without ON/USING to CROSS JOIN
Fixes #5795 ``` table1 = {id: int, pay1: string} populated with some values table2 = {id: int, pay2: string} empty DuckDB, Presto, Trino, Redshift, MySQL, Postgres, T-SQL: SELECT * FROM table1, table2; => no rows SELECT * FROM table1 LEFT JOIN table2; => not supported SELECT * FROM table1 LEFT JOIN table2 ON...
diff --git a/sqlglot/dialects/duckdb.py b/sqlglot/dialects/duckdb.py index e8361976d0..c4148be56d 100644 --- a/sqlglot/dialects/duckdb.py +++ b/sqlglot/dialects/duckdb.py @@ -1003,6 +1003,17 @@ def join_sql(self, expression: exp.Join) -> str: # DuckDB doesn't, but we can just add a dummy ON clause that...
3
2
0
[{"id": "G0", "claim": "The PR author will validate whether the `not expression.method` check added in the new DuckDB join handling is needed.", "category": "design", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Nit: drop the `kind` local variable and inline the check into li...
null
tobymao__sqlglot__5897
tobymao/sqlglot
5,897
defect
faba30905390e5efaf0ba9a05aab9ac2724b1b85
8bce48bbe0b8d7925abbe18be9dbfeacf9a91962
fix(snowflake): transpile BQ UNNEST with alias
Fixes #5895 ``` BigQuery: WITH foo AS (SELECT [1] AS arr_1) SELECT (SELECT unnested_arr FROM UNNEST(arr_1) AS unnested_arr) AS f FROM foo Snowflake (old output + wrong): WITH foo AS (SELECT [1] AS arr_1) SELECT (SELECT unnested_arr FROM TABLE(FLATTEN(INPUT => unnested_arr['arr_1'])) AS _t0(seq, key, path, inde...
diff --git a/sqlglot/dialects/snowflake.py b/sqlglot/dialects/snowflake.py index fd1b4ce818..96d3bffb79 100644 --- a/sqlglot/dialects/snowflake.py +++ b/sqlglot/dialects/snowflake.py @@ -378,6 +378,7 @@ def _qualify_unnested_columns(expression: exp.Expression) -> exp.Expression: taken_source_names = set(scop...
1
1
1
[{"id": "G0", "claim": "The guard added in _qualify_unnested_columns should stop find_ancestor at exp.Select and additionally check isinstance(ancestor_identifier, exp.Unnest), so a column whose nearest ancestor is the enclosing SELECT is not treated as an UNNEST column.", "category": "correctness", "verdict": "support...
null
tobymao__sqlglot__5921
tobymao/sqlglot
5,921
defect
6d0e3f8dcae7ed1a7659ece69b1f94cec5e7300e
0d7590321fe49de8209e20cbcaa7892897899391
fix(parser): NULLABLE as an identifier
Fixes #5919 This was caused by the refactor #4094
diff --git a/sqlglot/parser.py b/sqlglot/parser.py index 2ac59abbc5..38a6912930 100644 --- a/sqlglot/parser.py +++ b/sqlglot/parser.py @@ -5490,6 +5490,11 @@ def _parse_types( type_token = unsigned_type_token or type_token + # NULLABLE without parentheses can be a column (Presto/Trino) +...
1
1
1
[{"id": "G0", "claim": "The NULLABLE branch should check `expressions` and only retreat and return None when it is empty.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
tobymao__sqlglot__6029
tobymao/sqlglot
6,029
defect
db71a2023aaeca2ffda782ae7b91fdee356c402e
2a0fa69ab65628859b37729bfdf6cef214b4135b
fix(snowflake): transpile ARRAY_CONTAINS with VARIANT CAST
Fixes #6026 `ARRAY_CONTAINS` function in Snowflake, when the `ARRAY` argument is semi-structured, needs a `VARIANT` type as the searching value. This creates issues, when we transpile from a dialect like presto to snowflake. When the searching value isn't coercible to `VARIANT`, we must provide an explicit cast. ...
diff --git a/sqlglot/dialects/snowflake.py b/sqlglot/dialects/snowflake.py index 6d444e1c60..2ebc42a58c 100644 --- a/sqlglot/dialects/snowflake.py +++ b/sqlglot/dialects/snowflake.py @@ -1426,7 +1426,11 @@ class Generator(generator.Generator): exp.ArgMax: rename_func("MAX_BY"), exp.ArgMin: ren...
1
1
1
[{"id": "G0", "claim": "Snowflake-to-Snowflake transpilation should not emit the VARIANT cast the PR adds to ARRAY_CONTAINS, e.g. by using a parse-time arg instead.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
tobymao__sqlglot__6094
tobymao/sqlglot
6,094
defect
bef541cec36f8c4295f815c3f5cd22491738901b
839f1db7fe179416f264005887856225f84ae211
fix(parser)!: VALUES with ORDER BY/LIMIT/OFFSET
Fixes #6087
diff --git a/sqlglot/expressions.py b/sqlglot/expressions.py index 4a97cc7311..158e6264f3 100644 --- a/sqlglot/expressions.py +++ b/sqlglot/expressions.py @@ -3835,7 +3835,13 @@ def with_( class Values(UDTF): - arg_types = {"expressions": True, "alias": False} + arg_types = { + "expressions": True, + ...
2
1
0
[{"id": "G0", "claim": "Use `query_modifiers` in `values_sql` for generating the trailing modifiers instead of manually concatenating order/limit/offset.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Values.arg_types should perhaps include all QUERY_MOD...
null
tobymao__sqlglot__6151
tobymao/sqlglot
6,151
defect
0c5387499df19a77a3eb6a4e5f9332ab71c29391
b14263ab07654d2c2721d2c1355bc140f5b28d2c
fix(optimizer)!: simplify double negation only if the inner expr is BOOLEAN
Fixes #6129 This PR fixes the issue of double negation. The optimizer shouldn't by default remove the double negation. For `NOT(NOT(expr))` , we have to check if we can infer the inner type, because if it isn't boolean, the semantics of the query change.
diff --git a/sqlglot/optimizer/simplify.py b/sqlglot/optimizer/simplify.py index 8ce1ca8403a..cbee76fec11 100644 --- a/sqlglot/optimizer/simplify.py +++ b/sqlglot/optimizer/simplify.py @@ -125,7 +125,7 @@ def _simplify(expression): node.set(k, v) # Post-order transformations - ...
6
5
1
[{"id": "G0", "claim": "The PR should first check whether MySQL and SQLite are the only dialects affected by the existing double-negation logic, so that current behaviour can be preserved for every other dialect (the goal being to investigate coercion semantics in various engines).", "category": "correctness", "verdict...
null
tobymao__sqlglot__6173
tobymao/sqlglot
6,173
defect
dfe6b3c8e6db40e22e626e2d56e9a7008dd75c32
f121e4ba65d8bececb8f2775cb3765068a42513f
refactor: update `LIKE` operator when using functional syntax with spark dialect
Resolves #6172
diff --git a/sqlglot/dialects/spark.py b/sqlglot/dialects/spark.py index 973a8fbf79..efe9ae3712 100644 --- a/sqlglot/dialects/spark.py +++ b/sqlglot/dialects/spark.py @@ -23,6 +23,9 @@ move_partitioned_by_to_schema_columns, ) +if t.TYPE_CHECKING: + from sqlglot._typing import E + def _build_datediff(args:...
2
2
1
[{"id": "G0", "claim": "The new spark LIKE builder should use seq_get(args, 0) instead of args[0] and should take the escape parameter into account, similar to what Snowflake does.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Move Snowflake's buil...
null
tobymao__sqlglot__6374
tobymao/sqlglot
6,374
defect
6b7084d0c9f4735432afc12509c77c286cc50513
fea95fcbf5cda25767398d2b4396f0b2a22f4a94
Fix(oracle): properly support table alias in the `INSERT` DML
Fixes #6371
diff --git a/sqlglot/dialects/oracle.py b/sqlglot/dialects/oracle.py index 81abdd8a78..b449b8950e 100644 --- a/sqlglot/dialects/oracle.py +++ b/sqlglot/dialects/oracle.py @@ -276,6 +276,24 @@ def _parse_into(self) -> t.Optional[exp.Into]: def _parse_connect_with_prior(self): return self._parse_ass...
5
4
1
[{"id": "G0", "claim": "Rename `_parse_insert_alias` to `_parse_insert_table` and change its type hint to `t.Optional[exp.Expression]` for clarity and consistency, in both the base parser and the Oracle override.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "...
null
tobymao__sqlglot__6458
tobymao/sqlglot
6,458
defect
c111f643d61064280024b4cc5c0fc250581fbe55
0f5a174be92ba9c2ea173a5fcb2315782d354623
Fix!: REGEXP_EXTRACT position arg overflow
## Context `REGEXP_EXTRACT` extracts substrings based on a regex pattern (and is called `REGEXP_SUBSTR` in multiple dialects). In some dialects, `REGEXP_EXTRACT` has a `position` arg that specifies an index value for where in the string the matching should begin. This effectively means that a `SUBSTR` operation o...
diff --git a/sqlglot/dialects/duckdb.py b/sqlglot/dialects/duckdb.py index 7849379efd..3a523b4315 100644 --- a/sqlglot/dialects/duckdb.py +++ b/sqlglot/dialects/duckdb.py @@ -1448,7 +1448,10 @@ def regexpextract_sql(self, expression: exp.RegexpExtract) -> str: position = expression.args.get("position") ...
1
1
1
[{"id": "G0", "claim": "Hardcoding the NULLIF wrap (BigQuery's position-overflow semantics) into duckdb's REGEXP_EXTRACT generation assumes bq semantics for every source dialect, when the overflow behavior should be dialect-specific instead of hardcoded (e.g. snowflake needs '' passed through).", "category": "correctne...
null
tobymao__sqlglot__6699
tobymao/sqlglot
6,699
defect
29cff1fbe0011476b22e1b1442af857499f871a6
ce10bd2f21d59d03da959f843eff76cded45c1be
fix(spark, databricks): parse LTRIM/RTRIM
Fixes #6696 **DOCS** [LTRIM Spark](https://spark.apache.org/docs/latest/api/sql/index.html#ltrim) [RTRIM Spark](https://spark.apache.org/docs/latest/api/sql/index.html#rtrim) [LTRIM Databricks](https://docs.databricks.com/gcp/en/sql/language-manual/functions/ltrim) [RTRIM Databricks](https://docs.databricks.com/...
diff --git a/sqlglot/dialects/spark2.py b/sqlglot/dialects/spark2.py index d728decdc0..c6e4fe6d3e 100644 --- a/sqlglot/dialects/spark2.py +++ b/sqlglot/dialects/spark2.py @@ -14,6 +14,7 @@ ) from sqlglot.dialects.hive import Hive from sqlglot.helper import seq_get +from sqlglot.parser import build_trim from sqlglot...
2
2
2
[{"id": "G0", "claim": "Hive also supports two-argument LTRIM/RTRIM, so the LTRIM/RTRIM support the PR adds to spark2.py likely needs to be moved to hive.py instead.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new trim test cases in tests/dialects...
null
tobymao__sqlglot__6771
tobymao/sqlglot
6,771
defect
bc205323773ab443472362f875d8e487ae3906bd
daeddff6981f12a748ab08e724b73122ab916605
Feat(duckdb)!: avoid redundant cast when transpiling trunc from snowflake
Closes #6770
diff --git a/sqlglot/dialects/duckdb.py b/sqlglot/dialects/duckdb.py index 41e4995aef..5ea7d9f62c 100644 --- a/sqlglot/dialects/duckdb.py +++ b/sqlglot/dialects/duckdb.py @@ -583,7 +583,7 @@ def _json_extract_value_array_sql( def _cast_to_varchar(arg: t.Optional[exp.Expression]) -> t.Optional[exp.Expression]: - ...
2
1
0
[{"id": "G0", "claim": "In duckdb `_cast_to_varchar` the `arg.type and` check is redundant and should be dropped, leaving `if arg and not arg.is_type(*exp.DataType.TEXT_TYPES, exp.DataType.Type.UNKNOWN):`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "c...
null
tobymao__sqlglot__6804
tobymao/sqlglot
6,804
defect
ba1d99fc5da8b075c24554d57ed8b8092d56d58a
09aef201bb88c091d69ca57f32c517a2e4a3b69c
feat(starrocks): add full support for partitions
Fixes #6803 ### Description This PR adds comprehensive support for StarRocks partitioning syntax including: - **Expression-based partitioning** (`PARTITION BY expr1, expr2`): https://docs.starrocks.io/docs/table_design/data_distribution/expression_partitioning/ - **LIST partitioning** (`PARTITION BY LIST (co...
diff --git a/sqlglot/dialects/starrocks.py b/sqlglot/dialects/starrocks.py index 4576b3cead..d0dc545442 100644 --- a/sqlglot/dialects/starrocks.py +++ b/sqlglot/dialects/starrocks.py @@ -150,20 +150,73 @@ def _parse_partitioning_granularity_dynamic(self) -> exp.PartitionByRangePropert exp.PartitionByRa...
3
2
0
[{"id": "G0", "claim": "The partition parsing and generation logic added in starrocks.py duplicates doris.py (and covers syntax MySQL also supports), so the common implementation should be factored out by pushing it into the MySQL dialect (and the base class where patterns are shared) and inheriting in the derived dial...
null
tobymao__sqlglot__6972
tobymao/sqlglot
6,972
defect
1c5e1684dbb6f508f08b30e9ea96393b25ef0185
cd793f9318fff01e07220291b0d9e4c34fc73094
feat(parser)!: robust STAR with EXCLUDE (redshift)
Fixes #6963
diff --git a/sqlglot/dialects/redshift.py b/sqlglot/dialects/redshift.py index b988957c81..6bd2fd5fc3 100644 --- a/sqlglot/dialects/redshift.py +++ b/sqlglot/dialects/redshift.py @@ -133,6 +133,19 @@ def _parse_approximate_count(self) -> t.Optional[exp.ApproxDistinct]: self._retreat(index) ret...
6
6
2
[{"id": "G0", "claim": "The Redshift projection heuristic misinterprets EXCLUDE when it is used as an alias (e.g. `SELECT 1 exclude WHERE FALSE`, `SELECT * FROM (SELECT 1 exclude) t`, `SELECT 1 EXCLUDE, 2 foo`), retreating and popping a projection even though it is not an EXCLUDE clause.", "category": "correctness", "v...
null
tobymao__sqlglot__7184
tobymao/sqlglot
7,184
defect
427399151aa69ff934c802b3452bd4ad4f7010e7
65453b47e0bd227ac92e6df2653a19fa92ab8d76
fix(duckdb): parse FILE column
Fixes #7175
diff --git a/sqlglot/dialects/duckdb.py b/sqlglot/dialects/duckdb.py index 4edff0b63a..521ad19686 100644 --- a/sqlglot/dialects/duckdb.py +++ b/sqlglot/dialects/duckdb.py @@ -1558,6 +1558,9 @@ class Tokenizer(tokens.Tokenizer): class Parser(parser.Parser): MAP_KEYS_ARE_ARBITRARY_EXPRESSIONS = True + ...
2
1
1
[{"id": "G0", "claim": "The duckdb token set overrides could also be written with .copy() and .pop() instead of building new sets by subtraction.", "category": "maintainability", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "FILE is only relevant to Snowflake, so its support s...
null
tobymao__sqlglot__7463
tobymao/sqlglot
7,463
defect
2367eeb3d26c87991a771ac63db61b90de1bd05c
e85a4b3c4817c0b18e236a5e2abe236860ad3338
fix(bigquery): parse MODEL-first AI/ML GENERATE signatures
## Description: - add BigQuery parser hooks for MODEL-first GENERATE_* signatures (GENERATE_TEXT, GENERATE_TABLE, GENERATE_BOOL, GENERATE_INT, GENERATE_DOUBLE) - add generate-family expression types and SQL generation methods - add a BigQuery parser helper for generate signatures that supports table/query inputs a...
diff --git a/sqlglot/expressions/functions.py b/sqlglot/expressions/functions.py index 4f52069098..757ecbab58 100644 --- a/sqlglot/expressions/functions.py +++ b/sqlglot/expressions/functions.py @@ -329,6 +329,26 @@ class GenerateEmbedding(Expression, Func): arg_types = {"this": True, "expression": True, "params_s...
1
1
0
[{"id": "G0", "claim": "Nit: use a tuple instead of a set literal in the `elif prefix in {\"AI\", \"ML\"}:` membership check.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
tobymao__sqlglot__7464
tobymao/sqlglot
7,464
defect
2367eeb3d26c87991a771ac63db61b90de1bd05c
f5b2722f6537bea12662497d0f11682485875ce1
feat(snowflake): transpilation support for CONCAT_WS NULL semantics when transpiling to DuckDB
File: /Users/asha.shankar/Dev/sqlglot/sqlglot/generators/duckdb.py (lines 3736-3768) - Added concatws_sql method override in DuckDB generator - Handles NULL semantics differences between Snowflake and DuckDB - Converts binary types to || operator - Only wraps when explicit NULL expressions detected (NULL, N...
diff --git a/sqlglot-integration-tests b/sqlglot-integration-tests index 00390251ab..98d64be015 160000 --- a/sqlglot-integration-tests +++ b/sqlglot-integration-tests @@ -1 +1 @@ -Subproject commit 00390251ab054bc44d38e144f4d276ffe8ac9a00 +Subproject commit 98d64be015308a835b515506d343f32a88ede75c diff --git a/sqlglot/...
3
3
2
[{"id": "G0", "claim": "The guard returning super().concatws_sql when the separator expression is falsy is dead code because ConcatWs always has at least one expression and the first is always the separator.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", ...
null
tobymao__sqlglot__7467
tobymao/sqlglot
7,467
defect
576b5a8ae47e7108c69bdded53729c1e4cb3df1d
f643ca256a3c9631c68c7f28eab5373b9e2b54ef
feat(snowflake): parse and generate ROW ACCESS POLICY on views [CLAUDE]
## Summary - Adds parsing and generation support for Snowflake's `WITH ROW ACCESS POLICY` clause on `CREATE VIEW` statements - Extends `RowAccessProperty` expression to accept a policy name (`this`) and column list (`expressions`) - Updates the Snowflake generator to place the property in the `POST_SCHEMA` location - P...
diff --git a/sqlglot/expressions/properties.py b/sqlglot/expressions/properties.py index 143aeee5d2..3f34d81a21 100644 --- a/sqlglot/expressions/properties.py +++ b/sqlglot/expressions/properties.py @@ -334,7 +334,7 @@ class RollupIndex(Expression): class RowAccessProperty(Property): - arg_types = {} + arg_t...
1
1
1
[{"id": "G0", "claim": "The cross-dialect base generator now emits Snowflake-specific syntax (`WITH ROW ACCESS POLICY ... ON (...)`) for `RowAccessProperty` whenever `this` is set, which — given the property's default `POST_CREATE` location — would likely produce invalid SQL (e.g. `CREATE WITH ROW ACCESS POLICY ... VIE...
null
tobymao__sqlglot__7471
tobymao/sqlglot
7,471
defect
38357253ee1f2847bd14e0a7b68baf5a2c0a2228
0d33d571b2f56f6f1e9de1e6992aacc07f12d830
feat(duckdb): Add transpilation support for SUBSTR-SUBSTRING functions
This PR aims to resolve the following issues: **Issue 1** — Zero start position Snowflake `SUBSTR(str, 0, n)` treats 0 as 1. DuckDB returns a shorter string. Fix: clamp 0 → 1. **Issue 2** — Negative length Snowflake `SUBSTR(str, pos, -n)` returns ''. DuckDB silently returns wrong data. Fix: clamp negative → 0. ...
diff --git a/sqlglot-integration-tests b/sqlglot-integration-tests index 52937ac878..9f4f60a52a 160000 --- a/sqlglot-integration-tests +++ b/sqlglot-integration-tests @@ -1 +1 @@ -Subproject commit 52937ac8780c0aba9a9ce7df1164c8171915a628 +Subproject commit 9f4f60a52ad099041ba6552a2880f1b0b9b02882 diff --git a/sqlglot/...
2
2
1
[{"id": "G0", "claim": "substring_sql should not handle literals manually; it results in more complicated logic and sets an unwanted precedent, so it should be refactored to always inject the If node for start and length in this branch.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introdu...
null
tobymao__sqlglot__7479
tobymao/sqlglot
7,479
defect
38357253ee1f2847bd14e0a7b68baf5a2c0a2228
7f7b1f9b87112da02012b0e25e03479c002cb01a
feat(bigquery): add typed handling for AI scalar functions
## Description: - add typed expression nodes for BigQuery AI scalar calls: - AI.EMBED -> AIEmbed - AI.SIMILARITY -> AISimilarity - AI.GENERATE -> AIGenerate - keep SQL output backward compatible through explicit SQL names (EMBED, SIMILARITY, GENERATE) - preserve generic behavior for unqualified scalar nam...
diff --git a/sqlglot/expressions/functions.py b/sqlglot/expressions/functions.py index 757ecbab58..def4bf7542 100644 --- a/sqlglot/expressions/functions.py +++ b/sqlglot/expressions/functions.py @@ -321,6 +321,24 @@ class AIClassify(Expression, Func): _sql_names = ["AI_CLASSIFY"] +class AIEmbed(Expression, Fun...
4
4
4
[{"id": "G0", "claim": "arg_types should set \"expressions\" to True instead of False for AIEmbed, AISimilarity and AIGenerate, since at least one argument is expected.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The added _sql_names on AIEmbed, ...
null
tobymao__sqlglot__7482
tobymao/sqlglot
7,482
defect
38357253ee1f2847bd14e0a7b68baf5a2c0a2228
31bf7864a1266369409ce118478242fcf1dc1fac
fix(bigquery)!: support LOAD DATA FROM FILES syntax
## Summary: - add BigQuery parser support for LOAD DATA ... FROM FILES(...) syntax used in BigQuery docs - keep existing LOAD DATA ... INPATH ... parsing behavior by falling back to the base parser when FROM FILES is not matched - make LoadData.inpath optional and add optional files payload for BigQuery form - ad...
diff --git a/sqlglot/expressions/dml.py b/sqlglot/expressions/dml.py index 1aa31ee732..ed50983220 100644 --- a/sqlglot/expressions/dml.py +++ b/sqlglot/expressions/dml.py @@ -282,7 +282,8 @@ class LoadData(Expression): "this": True, "local": False, "overwrite": False, - "inpath": True,...
4
4
0
[{"id": "G0", "claim": "The BigQuery _parse_load override duplicates the base parser's logic and should instead be inlined into the base parser (matching FROM FILES there), so the override can be removed.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "cl...
null
tobymao__sqlglot__7489
tobymao/sqlglot
7,489
defect
38357253ee1f2847bd14e0a7b68baf5a2c0a2228
4934a876038487893bbe32419202dab2d41a7de3
fix(databricks)!: transpile TRY_DIVIDE to/from other dialects [CLAUDE]
## Summary Databricks' [`TRY_DIVIDE(a, b)`](https://docs.databricks.com/aws/en/sql/language-manual/functions/try_divide) returns `NULL` when the divisor is `0` (instead of raising an error). Previously it was left as `exp.Anonymous`, so it passed through untranspiled. `TRY_DIVIDE` also exists in Spark (https://spark....
diff --git a/sqlglot/generators/databricks.py b/sqlglot/generators/databricks.py index ead87f36e2..f535631717 100644 --- a/sqlglot/generators/databricks.py +++ b/sqlglot/generators/databricks.py @@ -4,8 +4,9 @@ from sqlglot import exp, transforms from sqlglot.dialects.dialect import ( date_delta_sql, - timest...
2
2
1
[{"id": "G0", "claim": "The Databricks parser's TRY_DIVIDE lambda should be replaced with exp.SafeDivide.from_arg_list.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "TRY_DIVIDE's parsing/generation logic should be pushed into the Spark dialect,...
null
tobymao__sqlglot__7491
tobymao/sqlglot
7,491
defect
38357253ee1f2847bd14e0a7b68baf5a2c0a2228
561603d5e989822e0f387d6f92ad00210a82b666
Fix(snowflake): parse GET_DDL #unknown_policy in ROW ACCESS POLICY [CLAUDE]
## Summary - Snowflake's `GET_DDL` outputs `#unknown_policy` (without an `ON` clause) when the user lacks privileges to see the actual row access policy name - Handle the `#` token prefix in the Snowflake parser so this syntax is parsed into a proper `Create` AST node instead of falling back to `Command` - Ensure `#unk...
diff --git a/sqlglot/generators/snowflake.py b/sqlglot/generators/snowflake.py index b36c56691f..9794e84752 100644 --- a/sqlglot/generators/snowflake.py +++ b/sqlglot/generators/snowflake.py @@ -863,8 +863,15 @@ def show_sql(self, expression: exp.Show) -> str: def rowaccessproperty_sql(self, expression: exp.RowAcc...
1
1
0
[{"id": "G0", "claim": "In the #unknown_policy branch of _parse_row_access_policy, the token should be parsed directly as a var (parse_var / _parse_var yielding exp.Var) instead of via _parse_id_var plus exp.to_identifier/exp.Var rewrapping of the id_var's name.", "category": "design", "verdict": "supported", "priority...
null