Conversation
Originally authored by: Alex Weininger Cherry-picked for use by: Matthew Fisher
| import { TreeItemStateStore } from './tree/TreeItemState'; | ||
|
|
||
| export async function activateInternal(context: vscode.ExtensionContext, perfStats: { loadStartTime: number; loadEndTime: number }, ignoreBundle?: boolean): Promise<void> { | ||
| export async function activate(context: vscode.ExtensionContext, perfStats: { loadStartTime: number; loadEndTime: number }, ignoreBundle?: boolean): Promise<void> { |
There was a problem hiding this comment.
For web bundled code, the entry point has to be the extension.bundle so I changed the names of the functions to activate and deactivate. The main.js file is still used by desktop.
| export async function getReposForNamespace(context: IActionContext, namespace: string, nextUrl?: string | null): Promise<DockerHubV2ApiResponse<DockerHubV2Repository>> { | ||
| const url = nextUrl || `https://hub.docker.com/v2/repositories/${namespace}`; | ||
| return <DockerHubV2ApiResponse<DockerHubV2Repository>>(await sendRequestWithTimeout(context, { url, method: 'GET' }, 5000, undefined)).parsedBody; | ||
| return <DockerHubV2ApiResponse<DockerHubV2Repository>>JSON.parse((await sendRequestWithTimeout(context, { url, method: 'GET' }, 5000, undefined)).bodyAsText as string); |
There was a problem hiding this comment.
When I changed the Azure REST pipeline stuff, it changed the response body a little bit, so that is to just to account for that.
There was a problem hiding this comment.
I think I can revert this back with the new changes to tools.
|
This is currently broken due to the |
@nturinski can we replace with |
|
Unfortunately not. I found a solution with vscode's proposed API: https://github.com/microsoft/vscode/blob/1d60909d1f273d3a4fdbfaba656048856057d36f/src/vs/vscode.proposed.d.ts#L89-L96 But the main issue here is that we're using |
|
I think I'm done committing to this PR. As mentioned, will resolve the fs-extra thing in another PR. |
I'll leave comments on various weird things that I had to do.
TODO:
Creating container apps still doesn't work in browser, but it is being worked on by the service team. I was able to test it still by manually deleting headers before the requests were sent out and confirmed it works.
Remove creating container apps from DockerHub. It has the same CORS issues and I doubt we'll be able to resolve that.Re-enable experimental service