fix: expand language IDs, fix AtCoder submit, normalize logging
Problem: AtCoder submit used a cookie fast-path that silently failed on stale sessions; `_LANGUAGE_ID_EXTENSION` only covered 2 of 116 languages; `LANGUAGE_VERSIONS` was incomplete for AtCoder, CF, and Kattis; AtCoder `prolog` and `racket` entries had wrong IDs. Raw `vim.notify` calls throughout bypassed `logger.log`, producing inconsistent or missing `[cp.nvim]:` prefixes. Solution: Remove cookie persistence from AtCoder login/submit — always use a fresh login within a single session. Increase `BROWSER_SUBMIT_NAV_TIMEOUT["atcoder"]` to 40s and switch to in-memory buffer upload with the correct per-language extension. Expand `LANGUAGE_VERSIONS` with all 116 AtCoder languages, 15 new CF languages with full version variants (java8/21, kotlin 1.7/1.9/2.2, rust 2021/2024, etc.), and 50+ Kattis languages. Fix AtCoder `prolog` ID (`6079`→`6081`, was Pony) and remove non-existent `racket` entry. Replace all raw `vim.notify` calls with `logger.log`.
This commit is contained in:
parent
0329c802a6
commit
ab67270472
13 changed files with 276 additions and 112 deletions
|
|
@ -142,7 +142,7 @@ local function discover_nix_submit_cmd()
|
|||
|
||||
local plugin_path = M.get_plugin_path()
|
||||
vim.cmd.redraw()
|
||||
vim.notify('Building submit environment...', vim.log.levels.INFO)
|
||||
logger.log('Building submit environment...', { level = vim.log.levels.INFO, override = true, sync = true })
|
||||
vim.cmd.redraw()
|
||||
local result = vim
|
||||
.system(
|
||||
|
|
@ -209,7 +209,7 @@ local function discover_nix_python()
|
|||
end
|
||||
|
||||
local plugin_path = M.get_plugin_path()
|
||||
vim.notify('[cp.nvim] Building Python environment with nix...', vim.log.levels.INFO)
|
||||
logger.log('Building Python environment with nix...', { level = vim.log.levels.INFO, override = true, sync = true })
|
||||
vim.cmd.redraw()
|
||||
local result = vim
|
||||
.system(
|
||||
|
|
@ -263,7 +263,7 @@ function M.setup_python_env()
|
|||
if not on_nixos and vim.fn.executable('uv') == 1 then
|
||||
local plugin_path = M.get_plugin_path()
|
||||
logger.log('Python env: uv sync (dir=' .. plugin_path .. ')')
|
||||
vim.notify('[cp.nvim] Setting up Python environment...', vim.log.levels.INFO)
|
||||
logger.log('Setting up Python environment...', { level = vim.log.levels.INFO, override = true, sync = true })
|
||||
vim.cmd.redraw()
|
||||
|
||||
local env = vim.fn.environ()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue