All Issues
24,993 verified issues
The API returns citations that don't pass the API's own validation.
Here is a text block from an API response. [code block] Playing this content block back to the model yields a `400` with: `{ "type": "invalid_request_error", "message": "messages.1.content.10.text.citations.1.web_search_result_location.title: Value should have at most 255 items after validation, not 336" }` The title referred to in the error message (below) is in fact 336 characters long. > "Amazon.com: St. Elsewhere - Season 1 : Ed Flanders, David Birney, G.W. Bailey, Ed Begley Jr., Terence Knox, Howie Mandel, David Morse, Christina Pickles, Kavi Raz, Cynthia Sikes, Denzel Washington, William Daniels, Allan Arkush, Bruce Paltrow, Kevin Hooks, Mark Tinker, Thomas Carter, Victor Hsu, Victor Lobl, Andrew Laskos: Movies & TV" If the API is doing validation on input, it really should be yielding valid data on output.
Tool Stream Mode Unicode Issue
[ Problem ] When using Stream mode using Tool, it is printed normally in English, but languages such as Korean, etc.. are returned to Unicode. In the case of stream mode that is not using Tool, it outputs normally, but it seems like it is a bug to return to Unicode numbers when it is Tool. [ I Want ] I want to receive the result value parsed like normal Stream mode, not Unicode, even in Tool Stream mode. [ English Tool Stream Mode ] [code block] [ Response ] [code block] [ Korean Tool Stream Mode ] [code block] [ Response ] [code block] [ Korean Non-Tool Stream Mode ] [code block] [ Response ] [code block]
Delta type not exported like other types
When implementing a type hinted SDK I was able to import all types directly from anthropic.types with the exception of Delta. Looks like this is just missing from types.__init__.py.
Difference b/w `TypedDict` versions and `BaseModel` versions for content types?
Why does the SDK provide both TypedDict and BaseModel versions for each content type? Which one should be used and when? Example: TextBlockParam (TypedDict) vs TextBlock (BaseModel) Also noticed missing `cache_control` field in the `BaseModel` versions.
Exception is thrown with large `max_tokens`.
Hello, I am trying to use a model with `max_tokens=64000`. However, an exception gets thrown, saying that, with a large `max_tokens`, streaming is strongly recommended. In particular, from where the exception is thrown and from the text of the exception it seems like this should be a warning instead? In my use case, I do not need streaming, and I am fine with not using it, even if the expected time to get a completion is long. Thank you in advance!
Bug: async _check_and_compact() ignores tool_use filtering, causes BadRequestError
Bug When using the async tool runner with compaction enabled, `_check_and_compact()` sends unfiltered `tool_use` blocks to the API, causing a `BadRequestError`. Error: [code block] Root Cause In `src/anthropic/lib/tools/_beta_runner.py`, the async `_check_and_compact()` method (line ~472) uses `self._params["messages"]` instead of the filtered local `messages` variable when building the summarization request. The filtering logic (lines ~457-469) correctly removes assistant messages containing only `tool_use` blocks, but the result is discarded because `self._params["messages"]` is used instead: [code block] Reproduction Gist with standalone reproduction (no API key needed): https://gist.github.com/fede-kamel/175f0e99abdb53a380ded3f41236e7dd Fix PR #1124 β one-line change: replace `self._params["messages"]` with `messages` on line ~472. The PR also fixes a similar issue in `append_messages` (line ~120) where a lambda captures `self._params["messages"]` at definition time instead of using `params["messages"]` at call time.
Model responses may violate input schema in tool specifications
Issue Description I've noticed a significant issue with using tool specifications with the Claude 3 Sonnet model through the AWS Bedrock Runtime API. The main problem is that the model's responses sometimes don't follow the input schema outlined in the tool specification. This situation raises important questions about the reliability and intended use of the tool specification feature. Most developers likely don't realize that the system currently does not perform schema verification. This lack of clarity underscores the need for better documentation about schema validation and adherence, which are critical for developing robust and predictable applications. Key Points of Concern 1. The current behavior suggests a lack of strict enforcement of the input schema, which may lead to unpredictable results and increased complexity in error handling for developers. 2. There is a need for clear documentation and best practices on how to handle and validate responses that may not conform to the specified schema. Example To illustrate this issue, I've implemented a nested tool specification for a "WorkoutPlan" model. This example demonstrates one way in which the model's output can deviate from the specified schema: [code block] And here's an example output: [code block] Notice that the output skips some 'required' parameters. For example this output is missing several `duration` fields. This example shows that the model's output can omit fields marked as "required" in the
iOS WKWebView blocks requests to localhost API in development builds
A React Native app using WKWebView (or Expo WebView) cannot make HTTP requests to a local development API (http://localhost:3000) on a physical iOS device. iOS enforces App Transport Security (ATS) which blocks all cleartext HTTP connections. Simulators work because they share the Mac's loopback interface, but physical devices cannot reach the Mac's localhost.
WebSocket connections get 502 Bad Gateway from Nginx after exactly 60 seconds idle
WebSocket clients behind an AWS Application Load Balancer (ALB) + Nginx receive a 502 Bad Gateway error and disconnect after exactly 60 seconds of connection idle time. The ALB default idle timeout is 60 seconds. The ALB closes the TCP connection, Nginx returns 502 to the client, and the WebSocket is terminated. Long-lived WebSocket connections require increasing the ALB idle timeout and configuring Nginx proxy timeouts.
Let's Encrypt certificate renewal fails with DNS problem: NXDOMAIN
Certbot DNS-01 challenge renewal fails with 'DNS problem: NXDOMAIN'. The TXT record for _acme-challenge.example.com is visible in dig output from your local resolver but ACME validation still fails. Let's Encrypt uses Google's 8.8.8.8 and Cloudflare's 1.1.1.1 as DNS validators. These may see a different DNS state due to authoritative DNS replication lag or a previous cached NXDOMAIN response.
SSL mismatch is silent on server β only visible via curl -v from outside
An HTTPS server appears healthy: status page is green, no 5xx errors, nginx logs are clean. But users report SSL errors in their browsers. The root cause is a load balancer or reverse proxy serving the wrong SSL certificate for the requested domain (e.g. a wildcard cert for *.domain-a.com being served for domain-b.com). The server itself never errors β the TLS handshake completes with the wrong cert and the browser rejects it client-side.
how do I echo $something >> file.txt without carriage return?
When I , a new line will be append to the file. What if I want to append without a new line?
How to prevent Gnome-shell's Alt+Tab from grouping windows from similar apps?
I love pretty much everything about how Gnome Shell handles app-switching through Alt+Tab. My one gripe with it, though, is how it forces the user to use Alt+` (or Alt+ whatever key above the Tab key for non-US keyboard layouts) to switch between windows of the same app. This is very annoying for me, because now I have to keep in mind if the last window I was using belonged to the same app as the current window or not. Definitely a nuisance for power users who thinks in terms of "windows I'm working with" instead of "applications I'm working on". I've tried the AlternateTab extension, but it's looks way too ugly for me. Not to mention that in the end all I want is to remap Alt+(key above tab) to Alt+Tab on this application. I guess one option would be to just tweak Gnome-shell. My guess is that I should tinker with the file at , but the file is too long and overwhelming for someone like me, who doesn't know JavaScript. Does anyone know how I can make Gnome Shell stop grouping windows β¦
How can I check the temperature of my CPU in Windows?
Does Windows provide a means to check my CPU temperature natively? If not, are there any software tools which can reveal this information?
Who provides the Internet service to Internet Service Providers (ISPs)?
I've been wondering recently about how the infrastructure of the Internet really works. I know that I have an Internet Service Provider (ISP) that supplies my connection to the Internet. But what I don't know is: Who provides the Internet to the ISP? And who supplies it to them? Is there a never-ending loop that eventually connects us all together?
How can I identify what application is using a given file?
I'm trying to delete some folder but this error is preventing from doing it: Cannot delete [FileName]: It is being used by another person or program. Close any programs that might be using the file and try again. How can I identify what application is using the file? I want to end the application using a Task Manager, but I didn't know what application is using it. The folder is not shared and my user account is an administrator.
Easiest way to find out if user has either Windows 7 or Vista (through telephone support)?
If you have to provide some initial troubleshooting support by phone [or email], and you don't have access to the user's PC itself, what is the easiest and most foolproof question one can ask of the user to find out if the 'dumb' user is using either Windows 7 or Windows Vista? For example: determining if the user has either Windows XP or Windows Vista/7 is easy. Just ask the user if the button at the left bottom corner is (a) either square with the word 'Start' on it, or (b) it is a round button. But how do you determine the difference between Vista and 7? Edit: For all the existing answers the user has to type something, and do it correctly. Sometimes even that is already hard for a computer illiterate user. My XP example just requires looking. If it exists (although I am afraid it doesn't), I think a solution that is just based on something this is visually different between Vista and 7 would stand above all others. (Which makes Dan's suggestion to turn over the box and look at theβ¦
tmux exits with [exited] on mac os x
I just installed tmux (a terminal multiplexer) with homebrew. When I try to run it, it always exits with Nothing shows up. When I try to run I get an error: failed to connect to server: Connection refused I tried running , but again nothing happens. What can I do?
How can I search a file by its name and partial path?
Often I have a file name and it's partial path, e.g. "content/docs/file.xml". Is there a simple way to search for that file, without manually cutting into parts its name to provide directory name and file name separately? It'd be great if worked in that way, so I could run , but unfortunately it doesn't.
Can you GPG sign old commits?
Git now has the ability to sign commits with , which is great, but sometimes I forget the flag to , and sometimes I mail myself patches which I apply with , and that command doesn't have a flag for signing. Is there a way to add a signature to an already recorded commit?