ruby / ruby/net-http

Failed to open TCP connection to test.s3.amazonaws.com:443 (Too many open files - socket(2) - udp)

Open
#67 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
148
Forks
95
Avg merge
10h 54m
Merged PRs (30d)
4

Description

Hello. I am trying to fetch against an s3 URL on an M1 mac, and am running into an error.

Implementation:

response = Net::HTTP.get_response(URI(fetch_url))

if response.is_a?(Net::HTTPSuccess)
  JSON.parse(response.body)
else
  raise Error, "Failed to fetch manifest from #{fetch_url}"
end

Error

Failed to open TCP connection to test.s3.amazonaws.com:443 (Too many open files - socket(2) - udp)

This issue hasn't been reported by anyone else in my org, and seems to be machine specific. I can go to the URL i'm trying to fetch manually, and it is accessible. I tried this page to look at my ulimit stuff, but it's essentially the same settings as other folks who this code is working for.

Any help appreciated!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The report names no repository file or test; begin with the Net::HTTP.get_response(URI(fetch_url)) call and reproduce the socket(2) error on the stated M1 Mac. Compare the failing environment with machines where the request works, and consider the issue complete when the machine-specific cause and a reproducible fix or clear project guidance are established.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, ruby
Domain
networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.