Skip to content

Commit 7df3b27

Browse files
committed
add alert to the create workspace page
No logic or api interaction yet. Just checking presentation and enumerating error cases.
1 parent e72d58b commit 7df3b27

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

site/src/pages/CreateWorkspacePage/CreateWorkspacePageView.tsx

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,29 @@ export const CreateWorkspacePageView: FC<CreateWorkspacePageViewProps> = ({
305305
</FormSection>
306306
)}
307307

308+
<FormSection title="" description="">
309+
<FormFields>
310+
{/* TODO (SasSwart):
311+
Is this a scenario that can occur for free-tier users? They have a default organisation and no external provisioners as far as I know.
312+
Nothing stops them from using a template with tags defined. Will those tags interfere with job selection on internal provisioners?
313+
*/}
314+
{/* TODO (SasSwart):
315+
There are multiple error scenarios here. Do they each need specific copy, or is a general message fine?
316+
* Could there be no provisioners whatsoever, or do we always expect at least the internal provisioners to run?
317+
* There may be provisioners, but none with the requisite tags.
318+
* There may be provisioners with the requisite tags, but they may not have been seen by coderd for more an unacceptable duration
319+
and therefore be considered stale.
320+
* There may be provisioners with the requisite tags that have been recently seen and are actively processing jobs, but what if the queue for jobs is long?
321+
Should we warn about expected delays?
322+
*/}
323+
{/* TODO (SasSwart): Considering the above, do we want to keep the alert simple here, but provide a link to the provisioner list page and show alerts there? */}
324+
{/* TODO (SasSwart): Do we need a stuck jobs page which lists the jobs queue with an alert for why each may be stuck? */}
325+
<Alert variant="outlined" severity="error">
326+
This organization does not have any provisioners compatible with this workspace. Before you create a template, you'll need to configure a provisioner.
327+
</Alert>
328+
</FormFields>
329+
</FormSection>
330+
308331
<FormFooter
309332
onCancel={onCancel}
310333
isLoading={creatingWorkspace}

0 commit comments

Comments
 (0)