Susan Kare: Designing Icons & Graphics For the Original Mac
submitted by /u/Successful_Bowl2564 [link] [留言]
找到 2797 篇相关文章
submitted by /u/Successful_Bowl2564 [link] [留言]
In the previous part of this series, we built a tiny supervisor from scratch. When a worker crashed, the supervisor started a replacement. That replacement had a new PID: old worker -> #PID<0.102.0> new worker -> #PID<0.105.0> This reveals an important limitation of sharing PIDs as a public interface. A PID identifies one running incarnation of a process. It is excellent for sending a reply, setting up a monitor, or creating a link. It is not a stable address for a service that may stop and later be replaced. In this part, we'll use named processes to give a worker a discoverable address: :worker We'll build three small examples using: Process . register / 2 Process . whereis / 1 :global . register_name / 2 :global . whereis_name / 1 send / 2 No GenServer . No OTP Registry . The goal is to understand the lookup problem that registries solve before reaching for those abstractions. The PID-Sharing Problem Suppose one process starts a worker and gives its PID to a client: worker = spawn ( fn -> worker_loop () end ) send ( client , { :worker_started , worker }) The client can now send work directly: send ( worker , { :work , self (), "hello" }) This works while that particular worker process is alive. But process IDs are temporary. If the worker exits, the PID is no longer a route to the service: Client Worker holds #PID<0.102.0> #PID<0.102.0> | | | X exits | | send(#PID<0.102.0>, work) |------------------------------> no worker receives it Sending to a dead local PID does not raise an error and does not restart a process. The message is simply not delivered to a living worker. One answer is to tell every client about every new PID after a restart. That spreads lifecycle knowledge throughout the system. Another answer is to make clients depend on a name and resolve that name when sending. Registering a Local Name Our first worker waits for a stop message: defmodule Worker do def start do spawn ( fn -> receive do :stop -> :ok end end ) end end Starting it gives us a PID:
submitted by /u/goto-con [link] [留言]
submitted by /u/ImpressGreen7325 [link] [留言]
submitted by /u/UnConeD [link] [留言]
Hello, I'm Maneshwar. I'm building git-lrc, a Micro AI code reviewer that runs on every commit. It is...
AI coding agents are useful, but team collaboration around them can become messy very quickly. A common shortcut is to share an account, API key, or long-lived access token so another teammate can run a task. It may feel convenient, but it creates avoidable security, ownership, and review problems. A better approach is to separate the task from the account that executes it. The person requesting the work prepares a complete, portable task. The person running it uses their own authorized AI-agent subscription and returns the result with evidence. Here is a practical way to structure that workflow. Why shared AI accounts create problems When several people use the same AI account, it becomes difficult to answer basic operational questions: Who initiated a specific action? Which person approved the resulting changes? What project context was exposed? Who is responsible for reviewing the output? What happens when a teammate changes roles or leaves? Shared credentials also tend to spread. A password may end up in a private message, a token may be copied into a local configuration file, or a browser session may remain active on an unmanaged device. Even when everyone involved is trusted, the process itself is difficult to audit. The goal should not be to share access more efficiently. It should be to share the work without transferring the account. Treat the task as a portable unit A useful AI task should make sense outside the original conversation in which it was created. Someone receiving the task should be able to understand: the desired outcome; the relevant project context; the boundaries of the work; the evidence required for completion; the decisions that still need human review. This turns the request into a portable unit of work rather than a fragment of chat history. For example, instead of writing: Update the import flow. Write something closer to: When a user uploads a CSV containing duplicate email addresses, show a validation summary before importing any re
The Quest Begins (The "Why") I still remember the first time our API started choking under a sudden traffic spike. It was a Friday afternoon, the kind where you’re just about to log off, and the monitoring dashboard lit up like a Christmas tree. Requests were piling up, latency shot through the roof, and our users began seeing those dreaded “429 Too Many Requests” errors. We had a naive rate limiter in place—a simple fixed‑window counter that reset every minute. It worked fine when traffic was steady, but as soon as a burst hit, the counter would either let too many through (because we hadn’t hit the limit yet) or block everything for the whole minute (because we’d already exhausted the quota). It felt like trying to hold back a tsunami with a sandbag. Honestly, I was frustrated. I knew there had to be a smarter way to smooth out those bursts without penalizing honest users or over‑protecting the system. That’s when I dove into the world of rate‑limiting algorithms, and the token bucket caught my eye like a shiny loot drop in a dungeon. The Revelation (The Insight) The token bucket is deceptively simple, yet it solves the exact pain points we were experiencing. Imagine a bucket that holds a fixed number of tokens. Tokens drip into the bucket at a steady rate (say, 10 tokens per second). Each incoming request consumes a token. If the bucket is empty, the request is denied or delayed; if there’s a token, the request proceeds and the token is removed. Why does this beat the fixed‑window counter? Burst tolerance – The bucket can store up to its capacity, allowing a short burst of requests up to that limit without waiting for the next window. Smooth throttling – Because tokens are added continuously, the limiter adapts to the actual request rate rather than resetting abruptly at arbitrary intervals. Memory‑light – We only need to track two numbers: the current token count and the last time we refilled the bucket. No arrays of timestamps per key. Here’s a quick ASCII sket
You budgeted six months. It took fourteen. You wanted one thing; you got three things that almost do it. And somewhere between the first sprint and the final invoice, you stopped understanding what you were even paying for. If that sounds familiar, this is the breakdown no one gave you before you started. What custom software development actually means Custom software development is building software from the ground up for your specific business, not configuring Salesforce, not installing a plugin. You're solving a problem your operations have, the way your operations actually work. What trips people up: "custom" doesn't mean "built entirely from scratch." Good dev teams use frameworks, libraries, and third-party services. What's custom is the logic of how your data flows, how business rules are enforced, how users interact. Scope range is huge: Custom dev covers everything from a lightweight internal dashboard to a full-scale multi-tenant SaaS platform. This is why cost estimates vary so wildly. 3 things nobody tells you before you sign 1. Scope creep is almost always the client's fault "Users should be able to manage their accounts" sounds simple. It actually contains dozens of decisions: can they change their email? What verification is required? Can they delete their account? Each one is a feature. Each feature has a cost. The fix: Run a discovery phase (2–4 weeks) before writing a single line of production code. It costs money upfront. It saves far more mid-project. 2. The cheapest bid rarely wins long-term A $40k quote and a $180k quote for the same project both happen. The $40k team isn't lying; they're optimistic, underbidding to win work, or scoping something different. What actually happens: you hit $40k, and you're 40% done. Higher bids from experienced teams often include architecture planning, documentation, testing infrastructure, and post-launch support things the cheap bid omitted. These aren't extras. They're what make the software maintainable in t
Can't believe I spent 2 weeks writing this. Last week, I gave a talk at a Cursor community event...
Most write-ups on this subject are about technique. This one is about the three decisions you should make before you write any code, because in my experience every project that went badly went badly for a reason that was decided on day one and not noticed until much later. I have built this kind of collection twice, for competitive analysis and for a partner-vetting workflow. Neither of them needed to touch anything behind a login, and I want to explain why that turned out to be the useful constraint rather than the limiting one. Line one: the login wall is a boundary A login wall is a statement about who the content is for. Treating it as an engineering obstacle to be routed around is the decision that puts a project on the wrong side of everything: terms of service, the platform's own detection, and in several jurisdictions the law. So the first line is simply: if it requires an account to see, it is out of scope. Not "hard," not "for later." Out of scope. I am not going to discuss techniques for getting past one, and I would be sceptical of any article that does. The interesting engineering question here is not how to see more. It is how much you can actually do with what is openly published, and the honest answer is: considerably more than people assume before they check. This constraint also has a practical benefit that is easy to miss. A pipeline built only on openly available data does not break when authentication changes, does not require credential management, and does not put an account at risk. Mine has survived two platform changes that took down colleagues' authenticated collectors. Line two: public does not mean unrestricted The second line is the one developers get wrong most often, and it has nothing to do with access. Data being publicly visible says nothing about whether you may store it, for how long, or what you may do with it. In the EU and UK, information about an identifiable person is personal data whether or not they published it themselves
I'm currently learning JavaScript and recently came across the Map and Set data structures. I understand that Set stores unique values and Map stores key-value pairs, but I'm wondering what advantages they actually provide over the existing Array and Object structures. What are some practical situations where you would choose Map or Set instead of an Array or Object? I'd especially appreciate real-world examples that make the differences clear. submitted by /u/hamzafullstack [link] [留言]
Polars hits the sweet spot between Pandas’ ease and Spark’s scale. If you’ve ever waited on a groupby or cursed a memory error, this cheat sheet is for you. I’ve pulled the patterns that save time in real pipelines, not just toy examples. Bookmark this before your next ETL run. Setup and Basics First, get Polars and a dataset. The lazy API is the default now, so you’ll rarely need to call .lazy() explicitly. Start with a CSV or Parquet file, or create a DataFrame from scratch. pip install polars pyarrow import polars as pl df = pl.read_csv('data.csv') # or pl.read_parquet() df = pl.DataFrame({'a': [1, 2], 'b': ['x', 'y']}) Selecting and Filtering Polars uses expressions, not strings. This feels odd at first but pays off when you chain operations. The syntax is consistent: every column is an expression you can transform, filter, or aggregate. df.select(['a', 'b']) # columns by name df.select(pl.col('a').alias('renamed')) df.filter(pl.col('a') > 10) df.filter(pl.col('b').is_in(['x', 'z'])) df.filter(pl.col('a').is_null()) Transforming Data Polars expressions are composable. You can nest them, reuse them, and even store them in variables. This is where the library shines over Pandas. df.with_columns(pl.col('a').cast(pl.Float64)) df.with_columns(pl.col('a').fill_null(0)) df.with_columns((pl.col('a') * 2).alias('a_doubled')) df.with_columns(pl.col('b').str.to_uppercase()) df.with_columns(pl.col('a').is_between(10, 20)) Grouping and Aggregations Groupbys in Polars are lazy by default. This means you can stack multiple aggregations without materializing intermediate results. The syntax is clean, but watch out for the order of operations. df.group_by('b').agg(pl.col('a').sum()) df.group_by('b').agg([pl.col('a').mean(), pl.col('a').max()]) df.group_by('b').agg(pl.col('a').quantile(0.9)) df.group_by_dynamic('timestamp', every='1d').agg(pl.col('a').sum()) Joins and Concatenation Joins in Polars are explicit. You’ll specify the join type and the columns to join on. Concatenatio
With the new release of 3.10.2 I wanted to look a bit more closely into Pandoc and all those different markup languages out there - and what converts with how much "loss". Maybe you also had to recently convert Markdown to HTML, or the other way around. In my case even different textual files into PDFs. One key finding: Modern languages that work with an AST are definitely competitive here. Maybe you find it also interesting. I actually didn't know most of those languages. Fun fact: The author of Pandoc is also one of the original Markdown standardization authors 15 years ago (well, if you can call it that, since it evolved still into quite the chaos) - as well as Djot, which is now only a few years old and supposed to be a markdown successor of sorts. I am mainly interested in shaping "the" markup language of the future, that is a good compromise of readability and writeability for humans, but also consumable for machines, contains all the important elements to express relevant documents from offline to online. As a programmer I am also a big fan (and in need) of dogfooding, of course :) submitted by /u/dereuromark [link] [留言]
How to keep APIs secure, consistent, compliant, and manageable as your organization grows. I've...
It all started with a bug: it turned out that 7.5 % 2 gives 1.5 in JavaScript and 1 in PHP. And it got me thinking: how many more differences like this are there? I don't want them to catch me off guard again. Since I couldn't find a list of the divergences I was looking for, I did what any reasonable person would do: put eight AIs to work on it. So far, they found 143 semantic divergences… and that's only among the data types JSON deals with: numbers, strings, arrays, maps, and booleans. For example: Math.round(-2.5): -2 in JS and Python… -3 in PHP Math.round(2.5): 3 in JS and PHP… 2 in Python "😀".length: 2 in JS (UTF-16)… 1 in Python… 4 in PHP (bytes) "10" < "9" → true in JS and Python… false in PHP sort(): [1, 10, 2] in JS (lexicographical by default)… [1, 2, 10] in Python split(""): ["a","b","c"] in JS and PHP… ValueError in Python "a" || "b": "a" in JS and Python… true in PHP And that's without even mentioning our beloved 0.1 + 0.2 = 0.30000000000000004 in every language using 64-bit floats. The full list is linked in the post (it's basically a compilation video of programming accidents). And if you're curious, have a look around the rest of the repo. It's like JSON, but for business logic. It already compiles itself to JS and PHP, with more targets coming. Demo: https://jsol.bustelo.com.ar/ Maybe you'll think it's an abomination. Maybe you'll find it useful. Let me know :) submitted by /u/santiagobustelo [link] [留言]
submitted by /u/nanochess [link] [留言]
Robin Williams' children are taking over their father's Instagram account after his daughter spoke out against the use of his AI likeness, as reported earlier by The Wrap. In a post on Tuesday, Zak, Zelda, and Cody Williams write that they want the late actor's Instagram profile to be a "safe, trusted place where the […]
Within minutes of this post going live, this laptop goes back to the company. Work is handed over....
submitted by /u/gingerbill [link] [留言]