fix: update bundled DeepSeek Harness to rc.8
GoodBuddy Agents / Validate Agent source (push) Canceled after 0s
GoodBuddy Agents / Build Linux arm64 Agent (push) Canceled after 0s
GoodBuddy Agents / Build Linux x64 Agent (push) Canceled after 0s
GoodBuddy Agent Release / Authorize Agent release (push) Canceled after 0s
Cross-platform packages / Validate source (push) Canceled after 0s
Cross-platform packages / windows x64 (push) Canceled after 0s
Cross-platform packages / Publish GitHub and OSS release (push) Canceled after 0s
GoodBuddy Agent Release / Build Linux arm64 compound package (push) Canceled after 0s
GoodBuddy Agent Release / Build Linux x64 compound package (push) Canceled after 0s
GoodBuddy Agent Release / Sign cumulative Agent catalog (push) Canceled after 0s
GoodBuddy Agent Release / Publish Agent to GitHub and OSS (push) Canceled after 0s
Cross-platform packages / Authorize desktop packaging (push) Canceled after 0s
Cross-platform packages / linux arm64 (push) Canceled after 0s
Cross-platform packages / macos arm64 (push) Canceled after 0s
Cross-platform packages / windows arm64 (push) Canceled after 0s
Cross-platform packages / linux x64 (push) Canceled after 0s
Cross-platform packages / macos x64 (push) Canceled after 0s
GoodBuddy Agents / Validate Agent source (push) Canceled after 0s
GoodBuddy Agents / Build Linux arm64 Agent (push) Canceled after 0s
GoodBuddy Agents / Build Linux x64 Agent (push) Canceled after 0s
GoodBuddy Agent Release / Authorize Agent release (push) Canceled after 0s
Cross-platform packages / Validate source (push) Canceled after 0s
Cross-platform packages / windows x64 (push) Canceled after 0s
Cross-platform packages / Publish GitHub and OSS release (push) Canceled after 0s
GoodBuddy Agent Release / Build Linux arm64 compound package (push) Canceled after 0s
GoodBuddy Agent Release / Build Linux x64 compound package (push) Canceled after 0s
GoodBuddy Agent Release / Sign cumulative Agent catalog (push) Canceled after 0s
GoodBuddy Agent Release / Publish Agent to GitHub and OSS (push) Canceled after 0s
Cross-platform packages / Authorize desktop packaging (push) Canceled after 0s
Cross-platform packages / linux arm64 (push) Canceled after 0s
Cross-platform packages / macos arm64 (push) Canceled after 0s
Cross-platform packages / windows arm64 (push) Canceled after 0s
Cross-platform packages / linux x64 (push) Canceled after 0s
Cross-platform packages / macos x64 (push) Canceled after 0s
The desktop runtime still pinned the rc.6 Harness family. It now uses the coherent rc.8 package set, adapts the revised image-attachment limits and error contract, and derives release checks from the lockfile. The managed SSH Agent package remains unchanged. Release note: 内置 DeepSeek Harness 已升级至 0.1.0-rc.8,并适配新版图片附件限制;托管 SSH Agent 包不受影响。
This commit is contained in:
@@ -8,6 +8,7 @@ const canvas = createCanvas(1, 1)
|
||||
const transparentPng = canvas.toBuffer('image/png')
|
||||
const jpeg = canvas.toBuffer('image/jpeg')
|
||||
const secondPng = createCanvas(2, 1).toBuffer('image/png')
|
||||
const overwidePng = createCanvas(8_193, 1).toBuffer('image/png')
|
||||
|
||||
describe('GoodBuddy Harness attachment store', () => {
|
||||
it('decodes, stores, verifies, and releases inline images', async () => {
|
||||
@@ -32,12 +33,18 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
const stored = await store.readImage(first)
|
||||
expect(stored.ref).toBe(first)
|
||||
expect(Buffer.from(stored.data).equals(transparentPng)).toBe(true)
|
||||
await expect(
|
||||
store.readImage({
|
||||
...first,
|
||||
width: first.width + 1
|
||||
})
|
||||
).rejects.toMatchObject({ code: 'INVALID_ATTACHMENT_REF' })
|
||||
|
||||
store.releaseImage(first)
|
||||
await expect(store.readImage(first)).resolves.toBeDefined()
|
||||
store.releaseImage(second)
|
||||
await expect(store.readImage(first)).rejects.toMatchObject({
|
||||
code: 'NOT_FOUND'
|
||||
code: 'ATTACHMENT_NOT_FOUND'
|
||||
})
|
||||
|
||||
const jpegRef = await store.saveImage({
|
||||
@@ -62,7 +69,7 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
data: transparentPng,
|
||||
mediaType: 'image/jpeg'
|
||||
})
|
||||
).rejects.toMatchObject({ code: 'INVALID_IMAGE' })
|
||||
).rejects.toMatchObject({ code: 'IMAGE_TYPE_MISMATCH' })
|
||||
await expect(
|
||||
store.saveImage({
|
||||
data: Buffer.from([
|
||||
@@ -81,6 +88,14 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
mediaType: 'image/png'
|
||||
})
|
||||
).rejects.toMatchObject({ code: 'INVALID_IMAGE' })
|
||||
await expect(
|
||||
store.saveImage({
|
||||
data: overwidePng,
|
||||
mediaType: 'image/png'
|
||||
})
|
||||
).rejects.toMatchObject({
|
||||
code: 'IMAGE_DIMENSION_TOO_LARGE'
|
||||
})
|
||||
|
||||
await store.saveImage({
|
||||
data: transparentPng,
|
||||
@@ -91,7 +106,7 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
data: secondPng,
|
||||
mediaType: 'image/png'
|
||||
})
|
||||
).rejects.toMatchObject({ code: 'STORAGE_LIMIT' })
|
||||
).rejects.toMatchObject({ code: 'ATTACHMENT_WRITE_FAILED' })
|
||||
})
|
||||
|
||||
it('does not retain a partial batch when capacity is exceeded', async () => {
|
||||
@@ -104,7 +119,7 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
{ data: transparentPng, mediaType: 'image/png' },
|
||||
{ data: jpeg, mediaType: 'image/jpeg' }
|
||||
])
|
||||
).rejects.toMatchObject({ code: 'STORAGE_LIMIT' })
|
||||
).rejects.toMatchObject({ code: 'ATTACHMENT_WRITE_FAILED' })
|
||||
await expect(
|
||||
store.saveImage({
|
||||
data: jpeg,
|
||||
@@ -130,4 +145,21 @@ describe('GoodBuddy Harness attachment store', () => {
|
||||
height: 1
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
it('enforces the upstream per-message image count', async () => {
|
||||
const store = new GoodBuddyHarnessAttachmentStore(new Context())
|
||||
const input = {
|
||||
data: transparentPng,
|
||||
mediaType: 'image/png' as const
|
||||
}
|
||||
|
||||
await expect(
|
||||
store.saveImages(
|
||||
Array.from(
|
||||
{ length: store.imageLimits.maxImagesPerMessage + 1 },
|
||||
() => input
|
||||
)
|
||||
)
|
||||
).rejects.toMatchObject({ code: 'TOO_MANY_IMAGES' })
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user