Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,14 @@
"image": "mcr.microsoft.com/devcontainers/go:1-bookworm",
"customizations": {
"vscode": {
"extensions": ["golang.go", "GitHub.copilot-chat", "GitHub.copilot", "github.vscode-github-actions", "astro-build.astro-vscode", "DavidAnson.vscode-markdownlint"]
"extensions": [
"golang.go",
"GitHub.copilot-chat",
"GitHub.copilot",
"github.vscode-github-actions",
"astro-build.astro-vscode",
"DavidAnson.vscode-markdownlint"
]
},
"codespaces": {
"repositories": {
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/dictation-prompt.lock.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions actions/setup/js/check_permissions_utils.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,19 @@ async function checkBotStatus(actor, owner, repo) {
return { isBot: true, isActive: true };
} catch (botError) {
// If we get a 404, the bot is not installed/active on this repository
// @ts-expect-error - Error handling with optional chaining
if (botError?.status === 404) {
core.warning(`Bot '${actor}' is not active/installed on ${owner}/${repo}`);
return { isBot: true, isActive: false };
}
// For other errors, we'll treat as inactive to be safe
// @ts-expect-error - Error handling with optional chaining
const errorMessage = botError?.message ?? String(botError);
core.warning(`Failed to check bot status: ${errorMessage}`);
return { isBot: true, isActive: false, error: errorMessage };
}
} catch (error) {
// @ts-expect-error - Error handling with optional chaining
const errorMessage = error?.message ?? String(error);
core.warning(`Error checking bot status: ${errorMessage}`);
return { isBot: false, isActive: false, error: errorMessage };
Expand Down Expand Up @@ -102,6 +105,7 @@ async function checkRepositoryPermission(actor, owner, repo, requiredPermissions
core.warning(`User permission '${permission}' does not meet requirements: ${requiredPermissions.join(", ")}`);
return { authorized: false, permission };
} catch (repoError) {
// @ts-expect-error - Error handling with optional chaining
const errorMessage = repoError?.message ?? String(repoError);
core.warning(`Repository permission check failed: ${errorMessage}`);
return { authorized: false, error: errorMessage };
Expand Down