Fix os.makedirs to os.mkdir for single-level directory in test

Agent-Logs-Url: https://github.com/kovidgoyal/kitty/sessions/d09883e5-f460-471d-9dcf-e64e7b96882f

Co-authored-by: kovidgoyal <1308621+kovidgoyal@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-04-09 11:38:49 +00:00 committed by GitHub
parent d548afc94a
commit 7e0e3eb6ac
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 3 additions and 5 deletions

View file

@ -122,6 +122,7 @@ def generate(
flag_keys = parse_flag(keymap, type_map, command_class)
int_keys, uint_keys = parse_number(keymap)
report_cmd = cmd_for_report(report_name, keymap, type_map, payload_allowed, payload_is_base64)
post_init_line = f'\n {post_init}' if post_init else ''
extra_init = ''
if payload_allowed:
payload_after_value = "case ';': state = PAYLOAD; break;"
@ -164,8 +165,7 @@ static inline void
{extra_init}
enum PARSER_STATES {{ KEY, EQUAL, UINT, INT, FLAG, AFTER_VALUE {payload} }};
enum PARSER_STATES state = KEY, value_state = FLAG;
{command_class} g = {{0}};
{post_init}
{command_class} g = {{0}};{post_init_line}
unsigned int i, code;
uint64_t lcode; int64_t accumulator;
bool is_negative; (void)is_negative;

View file

@ -11,7 +11,6 @@ static inline void parse_graphics_code(PS *self, uint8_t *parser_buf,
enum PARSER_STATES { KEY, EQUAL, UINT, INT, FLAG, AFTER_VALUE, PAYLOAD };
enum PARSER_STATES state = KEY, value_state = FLAG;
GraphicsCommand g = {0};
unsigned int i, code;
uint64_t lcode;
int64_t accumulator;

View file

@ -11,7 +11,6 @@ static inline void parse_multicell_code(PS *self, uint8_t *parser_buf,
enum PARSER_STATES { KEY, EQUAL, UINT, INT, FLAG, AFTER_VALUE, PAYLOAD };
enum PARSER_STATES state = KEY, value_state = FLAG;
MultiCellCommand g = {0};
unsigned int i, code;
uint64_t lcode;
int64_t accumulator;

View file

@ -1108,7 +1108,7 @@ class TestDnDProtocol(BaseTest):
import tempfile
with tempfile.TemporaryDirectory() as root:
sub = os.path.join(root, 'sub')
os.makedirs(sub)
os.mkdir(sub)
with open(os.path.join(sub, 'target.txt'), 'w') as f:
f.write('nested target')
os.symlink('target.txt', os.path.join(sub, 'nested_link.txt'))