(candidates: PythonEntrypoint[])
| 212 | } |
| 213 | |
| 214 | function renderCandidateSuggestion(candidates: PythonEntrypoint[]): string { |
| 215 | const lines = candidates.map( |
| 216 | c => ` ${c.entrypoint} (variable: ${c.variableName})` |
| 217 | ); |
| 218 | const suggested = candidates[0]; |
| 219 | const moduleAttr = `${entrypointToModule(suggested.entrypoint)}:${suggested.variableName}`; |
| 220 | return ( |
| 221 | `but found potential entrypoints:\n${lines.join('\n')}\n\n` + |
| 222 | `Add this to your pyproject.toml:\n\n` + |
| 223 | `[tool.vercel]\n` + |
| 224 | `entrypoint = "${moduleAttr}"` |
| 225 | ); |
| 226 | } |
| 227 | |
| 228 | async function resolveModuleAttrEntrypoint( |
| 229 | workPath: string, |
no test coverage detected