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
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ source venv/bin/activate
pip install uv

# Build Project
uv pip install -e .
uv pip install --native-tls -e .

# Add tool chain
uv install pre-commit
uv install --native-tls pre-commit
pre-commit install

# Run Program
Expand Down Expand Up @@ -152,4 +152,4 @@ The project's documentation is built using Jekyll and hosted on GitHub Pages. To
bundle exec jekyll serve
```

The built documentation will be available in the `aider/website/_site` directory.
The built documentation will be available in the `aider/website/_site` directory.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ pip install aider-ce
or

```bash
uv pip install aider-ce
uv pip install --native-tls aider-ce
```

The package exports an `aider-ce` command that accepts all of Aider's configuration options

### Tool Installation
```bash
uv tool install --python python3.12 aider-ce
uv tool install --native-tls --python python3.12 aider-ce
```

Use the tool installation so aider doesn't interfere with your development environment
Expand Down
2 changes: 1 addition & 1 deletion aider/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from packaging import version

__version__ = "0.89.4.dev"
__version__ = "0.89.5.dev"
safe_version = __version__

try:
Expand Down
6 changes: 6 additions & 0 deletions aider/args.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,12 @@ def get_parser(default_config_files, git_root):
default=True,
help="Verify the SSL cert when connecting to models (default: True)",
)
group.add_argument(
"--native-tls",
action=argparse.BooleanOptionalAction,
default=True,
help="Use system defined ssl certificates, instead of python's defaults (Default: True)",
)
group.add_argument(
"--timeout",
type=float,
Expand Down
8 changes: 6 additions & 2 deletions aider/coders/base_coder.py
Original file line number Diff line number Diff line change
Expand Up @@ -1381,7 +1381,7 @@ async def input_task(self, preproc):
self.io.ring_bell()
await self.io.recreate_input()

await asyncio.sleep(0.01) # Small yield to prevent tight loop
await asyncio.sleep(0.1) # Small yield to prevent tight loop

except KeyboardInterrupt:
self.io.set_placeholder("")
Expand Down Expand Up @@ -1439,7 +1439,7 @@ async def output_task(self, preproc):
await self.io.stop_output_task()

await self.auto_save_session()
await asyncio.sleep(0.01) # Small yield to prevent tight loop
await asyncio.sleep(0.1) # Small yield to prevent tight loop

except KeyboardInterrupt:
self.io.stop_spinner()
Expand Down Expand Up @@ -2996,6 +2996,10 @@ async def show_send_output_stream(self, completion):
received_content = False

async for chunk in completion:
if self.args.debug:
with open(".aider/logs/chunks.log", "a") as f:
print(chunk, file=f)

# Check if confirmation is in progress and wait if needed
while self.io.confirmation_in_progress:
await asyncio.sleep(0.1) # Yield control and wait briefly
Expand Down
17 changes: 17 additions & 0 deletions aider/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
from dataclasses import fields
from pathlib import Path

import truststore

try:
import git
except ImportError:
Expand All @@ -19,6 +21,10 @@
import importlib_resources
import shtab
from dotenv import load_dotenv

if sys.platform == "win32": # Windows asyncio fix. set_event_loop_policy deprecated in 3.16
if hasattr(asyncio, "set_event_loop_policy"):
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
from prompt_toolkit.enums import EditingMode

from aider import __version__, models, urls, utils
Expand Down Expand Up @@ -488,6 +494,14 @@ def custom_tracer(frame, event, arg):


def main(argv=None, input=None, output=None, force_git_root=None, return_coder=False):
# Asyncio run workaround for Windows in Python 3.12+. Required from 3.16+
if sys.platform == "win32":
if sys.version_info >= (3, 12) and hasattr(asyncio, "SelectorEventLoop"):
return asyncio.run(
main_async(argv, input, output, force_git_root, return_coder),
loop_factory=asyncio.SelectorEventLoop,
)

return asyncio.run(main_async(argv, input, output, force_git_root, return_coder))


Expand Down Expand Up @@ -528,6 +542,9 @@ async def main_async(argv=None, input=None, output=None, force_git_root=None, re
return await graceful_exit(None, 1)
raise e

if args.native_tls:
truststore.inject_into_ssl()

if args.verbose:
print("Config files search order, if no --config:")
for file in default_config_files:
Expand Down
2 changes: 1 addition & 1 deletion aider/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def report_github_issue(issue_text, title=None, confirm=True):
:param confirm: Whether to ask for confirmation before opening the browser (default: True)
:return: None
"""
version_info = f"Aider version: {__version__}\n"
version_info = f"Aider-CE version: {__version__}\n"
python_version = f"Python version: {sys.version.split()[0]}\n"
platform_info = f"Platform: {platform.platform()}\n"
python_info = get_python_info() + "\n"
Expand Down
Loading
Loading