yncli 1.1.4__tar.gz → 1.1.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {yncli-1.1.4 → yncli-1.1.6}/PKG-INFO +1 -1
- {yncli-1.1.4 → yncli-1.1.6}/pyproject.toml +1 -1
- {yncli-1.1.4 → yncli-1.1.6}/setup.py +1 -1
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tui.py +20 -8
- {yncli-1.1.4 → yncli-1.1.6}/yncli/update_checker.py +15 -12
- yncli-1.1.6/yncli/version.py +1 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/PKG-INFO +1 -1
- yncli-1.1.4/yncli/version.py +0 -1
- {yncli-1.1.4 → yncli-1.1.6}/README.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/setup.cfg +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/__init__.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/agent.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/architect.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/code_review.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/debug_oracle.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/debugger.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/polyglot.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/refactor_master.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/security_auditor.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/system_architect.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/test_runner.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/built_in_skills/ultrabrain.md +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/clean_text.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/client.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/config.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/language_detector.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/main.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/mention_resolver.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/skills_manager.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/system_prompt.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tools/__init__.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tools/file_tools.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tools/polyglot_tools.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tools/search_tools.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/tools/system_tools.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/workspace_memory.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli/workspace_scanner.py +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/SOURCES.txt +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/dependency_links.txt +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/entry_points.txt +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/requires.txt +0 -0
- {yncli-1.1.4 → yncli-1.1.6}/yncli.egg-info/top_level.txt +0 -0
|
@@ -6,7 +6,7 @@ long_description = (this_directory / "README.md").read_text(encoding="utf-8") if
|
|
|
6
6
|
|
|
7
7
|
setup(
|
|
8
8
|
name="yncli",
|
|
9
|
-
version="1.1.
|
|
9
|
+
version="1.1.6",
|
|
10
10
|
description="Autonomous Polyglot AI Coding Agent & TUI",
|
|
11
11
|
long_description=long_description,
|
|
12
12
|
long_description_content_type="text/markdown",
|
|
@@ -100,9 +100,11 @@ class TerminalUI:
|
|
|
100
100
|
# If pasted text is multiline or long (>= 2 lines or > 120 chars)
|
|
101
101
|
if line_count >= 2 or len(data) > 150:
|
|
102
102
|
paste_id = f"PASTE_BLOCK_{len(self._pasted_blocks) + 1}"
|
|
103
|
-
self._pasted_blocks[paste_id] =
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
self._pasted_blocks[paste_id] = {
|
|
104
|
+
"token": f"[ pasted {line_count} lines ]",
|
|
105
|
+
"data": data
|
|
106
|
+
}
|
|
107
|
+
event.current_buffer.insert_text(f"[ pasted {line_count} lines ]")
|
|
106
108
|
else:
|
|
107
109
|
event.current_buffer.insert_text(data)
|
|
108
110
|
|
|
@@ -425,7 +427,10 @@ class TerminalUI:
|
|
|
425
427
|
|
|
426
428
|
elif cmd in ("/update", "/upgrade"):
|
|
427
429
|
from yncli.update_checker import perform_self_update
|
|
428
|
-
perform_self_update()
|
|
430
|
+
success = perform_self_update()
|
|
431
|
+
if success:
|
|
432
|
+
self.console.print("\n[bold green]Pembaruan selesai! Silakan jalankan kembali:[/bold green] [bold cyan]yncli[/bold cyan]\n")
|
|
433
|
+
sys.exit(0)
|
|
429
434
|
return True
|
|
430
435
|
|
|
431
436
|
elif cmd == "/save":
|
|
@@ -468,10 +473,17 @@ class TerminalUI:
|
|
|
468
473
|
continue
|
|
469
474
|
|
|
470
475
|
if getattr(self, "_pasted_blocks", None):
|
|
471
|
-
for pid,
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
476
|
+
for pid, pinfo in list(self._pasted_blocks.items()):
|
|
477
|
+
tok = pinfo.get("token", "")
|
|
478
|
+
raw_data = pinfo.get("data", "")
|
|
479
|
+
if tok and tok in user_input:
|
|
480
|
+
user_input = user_input.replace(tok, f"\n```\n{raw_data}\n```\n", 1)
|
|
481
|
+
else:
|
|
482
|
+
# Fallback if user edited whitespace around token
|
|
483
|
+
import re
|
|
484
|
+
def _repl(match):
|
|
485
|
+
return f"\n```\n{raw_data}\n```\n"
|
|
486
|
+
user_input = re.sub(r'\[\s*pasted\s+\d+\s+lines?\s*\]', _repl, user_input, count=1)
|
|
475
487
|
self._pasted_blocks.clear()
|
|
476
488
|
|
|
477
489
|
self.execute_turn(user_input)
|
|
@@ -99,7 +99,7 @@ def perform_self_update() -> bool:
|
|
|
99
99
|
|
|
100
100
|
print("\n[YNCLI] Mengunduh dan menginstal pembaruan...")
|
|
101
101
|
|
|
102
|
-
# 1. Update Python module via pip
|
|
102
|
+
# 1. Update Python module via pip with retry (handling PyPI index propagation delay)
|
|
103
103
|
pip_cmd = [
|
|
104
104
|
sys.executable, "-m", "pip", "install",
|
|
105
105
|
"--upgrade", "--no-cache-dir",
|
|
@@ -108,21 +108,24 @@ def perform_self_update() -> bool:
|
|
|
108
108
|
]
|
|
109
109
|
|
|
110
110
|
res = subprocess.run(pip_cmd)
|
|
111
|
+
|
|
112
|
+
# Retry once after short sleep if specific tag failed due to index propagation
|
|
113
|
+
if res.returncode != 0:
|
|
114
|
+
time.sleep(2)
|
|
115
|
+
# Fallback to general --upgrade
|
|
116
|
+
fallback_cmd = [
|
|
117
|
+
sys.executable, "-m", "pip", "install",
|
|
118
|
+
"--upgrade", "--no-cache-dir",
|
|
119
|
+
"--disable-pip-version-check",
|
|
120
|
+
"yncli"
|
|
121
|
+
]
|
|
122
|
+
res = subprocess.run(fallback_cmd)
|
|
123
|
+
|
|
111
124
|
if res.returncode == 0:
|
|
112
125
|
print("\n[SUCCESS] YNCLI berhasil diperbarui ke versi terbaru!")
|
|
113
|
-
print("[YNCLI] Memulai ulang
|
|
126
|
+
print("[YNCLI] Memulai ulang sesi baru...\n")
|
|
114
127
|
# Clear update cache
|
|
115
128
|
CACHE_FILE.unlink(missing_ok=True)
|
|
116
|
-
|
|
117
|
-
# Automatically restart current process with same arguments
|
|
118
|
-
try:
|
|
119
|
-
import os
|
|
120
|
-
# Close old process and replace with new python instance
|
|
121
|
-
os.execv(sys.executable, [sys.executable, "-m", "yncli.main"] + sys.argv[1:])
|
|
122
|
-
except Exception:
|
|
123
|
-
# Fallback for Windows where execv might spawn
|
|
124
|
-
subprocess.run([sys.executable, "-m", "yncli.main"])
|
|
125
|
-
sys.exit(0)
|
|
126
129
|
return True
|
|
127
130
|
else:
|
|
128
131
|
print("\n[ERROR] Gagal memperbarui via pip. Coba jalankan manual:")
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "1.1.6"
|
yncli-1.1.4/yncli/version.py
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "1.1.4"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|