Skip to content

Commit 10408f6

Browse files
authored
Merge pull request #5780 from snyk/chore/revert-rollback-poetry-v2
revert: rollback poetry v2 support
2 parents 89161df + 7da2d8c commit 10408f6

File tree

6 files changed

+16
-215
lines changed

6 files changed

+16
-215
lines changed

binary-releases/RELEASE_NOTES.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ The Snyk CLI is being deployed to different deployment channels, users can selec
1111
* **container:** adds kaniko support ([bfb69c8](https://github.com/snyk/snyk/commit/bfb69c83ddda560b2940ee1eb771da665737eb42))
1212
* **general:** display a unique interactionID alongside each error ([960a71c](https://github.com/snyk/snyk/commit/960a71c81f17f0b5743e5ebd61cbf1b88c7d0c40))
1313
* **test:** python support for local wheel files specifiers ([42675eb](https://github.com/snyk/snyk/commit/42675eb4da17307ad8ab6a090b761fd3ab9a8a2f))
14-
* **test:** add support for poetry v2 ([52e31e0](https://github.com/snyk/snyk/commit/52e31e0e9ab6326b759933ec7ee5d5c5925c3823))
1514
* **test:** dep-graph json file output ([90f24ec](https://github.com/snyk/snyk/commit/90f24ecdba80b431fb8db4116a82f3fb6db45f80))
1615
* **test:** print legacy tree with json file output ([b256937](https://github.com/snyk/snyk/commit/b2569378135e3156eca44b27902dc799def1e430))
1716
* **test:** display all applicable maven unmanaged identities ([ebf6ba1](https://github.com/snyk/snyk/commit/ebf6ba1f832f1416adc9d5501081e8a681b1ff5f))

package-lock.json

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@
127127
"snyk-nuget-plugin": "2.7.15",
128128
"snyk-php-plugin": "1.10.0",
129129
"snyk-policy": "4.1.4",
130-
"snyk-python-plugin": "2.5.0",
130+
"snyk-python-plugin": "2.5.2",
131131
"snyk-resolve-deps": "4.8.0",
132132
"snyk-sbt-plugin": "2.18.1",
133133
"snyk-swiftpm-plugin": "1.4.1",

test/acceptance/workspaces/poetry-v2-app/poetry.lock

Lines changed: 0 additions & 95 deletions
This file was deleted.

test/acceptance/workspaces/poetry-v2-app/pyproject.toml

Lines changed: 0 additions & 16 deletions
This file was deleted.

test/jest/unit/python/snyk-test-pyproject.spec.ts

Lines changed: 0 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -91,93 +91,6 @@ describe('snyk test for python project', () => {
9191
}),
9292
);
9393

94-
const expectedResultObject = {
95-
vulnerabilities: [],
96-
ok: true,
97-
dependencyCount: 0,
98-
org: 'test-org',
99-
policy: undefined,
100-
isPrivate: true,
101-
licensesPolicy: null,
102-
packageManager: 'poetry',
103-
projectId: undefined,
104-
ignoreSettings: null,
105-
docker: undefined,
106-
summary: 'No known vulnerabilities',
107-
severityThreshold: undefined,
108-
remediation: undefined,
109-
filesystemPolicy: false,
110-
uniqueCount: 0,
111-
targetFile: 'pyproject.toml',
112-
projectName: undefined,
113-
foundProjectCount: undefined,
114-
displayTargetFile: 'pyproject.toml',
115-
platform: undefined,
116-
hasUnknownVersions: false,
117-
path: fixturePath,
118-
};
119-
expect(result).toMatchObject({
120-
result: JSON.stringify(expectedResultObject, null, 2),
121-
});
122-
});
123-
it('should scan poetry v2 vulnerabilities', async () => {
124-
const fixturePath = getWorkspacePath('poetry-v2-app');
125-
126-
const plugin = {
127-
async inspect() {
128-
return {
129-
plugin: {
130-
targetFile: 'pyproject.toml',
131-
name: 'snyk-python-plugin',
132-
runtime: 'Python',
133-
},
134-
package: {},
135-
};
136-
},
137-
};
138-
139-
// this is for 'enablePnpmCli' feature flag
140-
mockedMakeRequest.mockImplementationOnce(() => {
141-
return Promise.resolve({
142-
res: { statusCode: 200 } as NeedleResponse,
143-
body: {
144-
code: 200,
145-
ok: false,
146-
},
147-
});
148-
});
149-
mockedLoadPlugin.mockImplementationOnce(() => {
150-
return plugin;
151-
});
152-
mockedMakeRequest.mockImplementationOnce(() => {
153-
return Promise.resolve({
154-
res: { statusCode: 200 } as NeedleResponse,
155-
body: {
156-
result: { issuesData: {}, affectedPkgs: {} },
157-
meta: { org: 'test-org', isPublic: false },
158-
filesystemPolicy: false,
159-
},
160-
});
161-
});
162-
163-
const result: CommandResult = await test(fixturePath, {
164-
json: true,
165-
_: [],
166-
_doubleDashArgs: [],
167-
});
168-
169-
expect(mockedLoadPlugin).toHaveBeenCalledTimes(1);
170-
expect(mockedLoadPlugin).toHaveBeenCalledWith('poetry');
171-
172-
expect(mockedMakeRequest).toHaveBeenCalledTimes(2);
173-
expect(mockedMakeRequest).toHaveBeenCalledWith(
174-
expect.objectContaining({
175-
body: expect.objectContaining({
176-
displayTargetFile: 'pyproject.toml',
177-
}),
178-
}),
179-
);
180-
18194
const expectedResultObject = {
18295
vulnerabilities: [],
18396
ok: true,

0 commit comments

Comments
 (0)