今日已更新 346 条资讯 | 累计 28250 条内容
关于我们

AI 资讯

AI人工智能最新资讯、模型发布、研究进展

14916
篇文章

共 14916 篇 · 第 453/746 页

Reddit r/programming

Bingo da Copa

I built a simple mobile World Cup Bingo game and would love some feedback. The idea is simple: - Create your own World Cup bingo card - Follow the matches during the tournament - Earn points as events happen - Compete against friends - Check the final leaderboard when the tournament ends There's a free version and an optional Pro upgrade (R$4.90) that removes ads, unlocks exclusive themes, allows unlimited cards and gives up to 3 free swaps per game. I built it mainly because I wanted something more casual and social than fantasy football apps. Would love to hear what football fans think: https://bingo-da-copa.vercel.app/ submitted by /u/No_Net_1962 [link] [留言]

/u/No_Net_1962 2026-06-20 03:56 👁 5 查看原文 →
Dev.to

Synthetic Monitoring vs Real User Monitoring (RUM): The Difference

Two monitoring approaches answer two different questions. Synthetic monitoring answers "would the checkout flow work right now if someone tried it?" Real user monitoring answers "what did the checkout flow actually do for the 4,000 people who tried it today?" The first is a robot testing a path on a schedule; the second is instrumentation recording reality as it happens. Teams reach for one when they need the other, then conclude monitoring "doesn't work." The fix is understanding what each is structurally good at — and where each is blind. Synthetic monitoring: proactive, scripted, continuous Synthetic monitoring runs scripted checks against your application from the outside, on a fixed schedule. An HTTP check hits an endpoint and asserts on the response; a browser check drives a headless Chromium through a journey — log in, add to cart, pay — and asserts on what the user would see. The defining property is that it does not need real traffic. The check runs every 30 seconds whether or not anyone is using the app, from datacenters you choose, testing exactly the journeys you scripted. When a deploy breaks checkout at 3 AM, a synthetic check catches it at 3 AM — not at 9 AM when the first customer wakes up. Real user monitoring: passive, real, traffic-dependent RUM instruments your actual frontend with a JavaScript snippet that reports back what real visitors experience: page load times, Core Web Vitals (LCP, INP, CLS), JavaScript errors, the device and network and geography of every session. It is a recording of reality with perfect fidelity — these are real people, real conditions, real outcomes. The cost of that fidelity is that RUM is entirely traffic-dependent and entirely retrospective. It can only report on paths real users took, after they took them. A page nobody visited generates no RUM data. A broken deploy at 3 AM is invisible to RUM until a real user hits it and the error is recorded. The core difference, side by side Dimension Synthetic monitoring Real

DevHelm 2026-06-20 02:49 👁 14 查看原文 →
Dev.to

Synthetic Monitoring Best Practices: What to Monitor and How Often

Most synthetic monitoring setups fail in one of a few predictable ways. They monitor everything and alert on nothing useful. They assert on status code 200 and miss the empty response body. They run flaky browser checks that page someone at 2 AM for a problem that fixed itself by 2:01. Or they go stale — the checkout flow changed three months ago and the check has been failing-then-being-ignored ever since. These are not exotic failures. They are the default outcome of setting up synthetic monitoring without a discipline. Here is the discipline. 1. Monitor the journeys that cost money, not everything Every browser check costs compute and, more importantly, costs maintenance. A check on a path that does not matter is worse than no check — it generates noise that trains your team to ignore alerts. Rank your journeys by cost of silent failure and monitor the top of the list: Authentication — login, signup. The gate to everything else. The revenue path — checkout, upgrade, add payment method. The core product action — the one thing your product exists to do. Critical third-party handoffs — OAuth redirects, payment iframes, SSO. Leave static pages, read-only endpoints, and admin screens to cheaper uptime and API checks . A good rule: if a path breaking would not generate a support ticket or lose revenue, it does not need a browser check. 2. Assert on what the user sees, not just the status code The entire point of synthetic monitoring is catching the failure that a 200 OK hides. So your assertions have to go past the status code. // Weak: passes even when the page renders an error await page . goto ( " https://shop.example.com/checkout " ); expect ( page . url ()). toContain ( " /checkout " ); // Strong: asserts the user can actually complete the action await page . getByRole ( " button " , { name : " Pay now " }). click (); await expect ( page . getByText ( " Order confirmed " )). toBeVisible ({ timeout : 10000 , }); await expect ( page . getByTestId ( " order-number "

DevHelm 2026-06-20 02:49 👁 14 查看原文 →
Dev.to

Playwright Monitoring: Turn E2E Tests Into Production Monitors

You already have Playwright tests. They run in CI on every pull request, they assert that login works and checkout completes, and then they stop — because CI only runs them against a branch, at merge time. The moment the code is in production, those tests go silent. A third-party script breaks checkout at 3 AM and your perfectly good test suite says nothing, because nothing triggered it. Playwright monitoring closes that gap: you take the same browser tests and run them on a schedule against production, turning your end-to-end suite into a synthetic monitoring system that watches real user journeys continuously. Prerequisites Node.js 18+ and an existing project ( npm install -D @playwright/test , then npx playwright install chromium ). A deployed production (or staging) URL to run checks against. A dedicated synthetic test account — never a real customer's credentials. A secret store for that account's credentials (GitHub Actions secrets, or your platform's equivalent). Never hard-code them. Step 1 — Write a check that asserts on what the user sees A monitor-grade check is not "did the page load." It is "could a user complete the thing they came to do." Assert on the outcome, with a generous timeout for real-world latency: import { test , expect } from " @playwright/test " ; test ( " checkout reaches confirmation " , async ({ page }) => { await page . goto ( " https://shop.example.com " ); await page . getByRole ( " button " , { name : " Add to cart " }). click (); await page . getByRole ( " link " , { name : " Checkout " }). click (); await page . getByLabel ( " Email " ). fill ( process . env . SYNTHETIC_EMAIL ! ); await page . getByLabel ( " Card number " ). fill ( " 4242424242424242 " ); await page . getByRole ( " button " , { name : " Pay now " }). click (); // The assertion a 200 OK can never make for you: await expect ( page . getByText ( " Order confirmed " )). toBeVisible ({ timeout : 15000 , }); }); Credentials come from process.env , not the source. The t

DevHelm 2026-06-20 02:48 👁 11 查看原文 →
Dev.to

Best Synthetic Monitoring Tools in 2026: Honest Comparison

Synthetic monitoring tools all promise the same thing — catch the broken checkout before your users do — and then bill you in seven different ways for it. The hard part of choosing one is not the feature checklist; it is predicting what you will actually pay when a single browser check running every 30 seconds from three regions turns into 259,200 runs a month. We compared seven synthetic monitoring tools on what separates them in practice: browser engine and fidelity, how you author checks (code, recorder, or AI), location coverage, alerting and on-call, failure forensics, and — the one that surprises teams — the pricing model. Every price below was verified against official pricing pages in June 2026. For the concepts behind these tools, start with what synthetic monitoring is . TL;DR comparison Tool Best for Browser engine Authoring Pricing model Browser price Checkly Code-first teams running Playwright suites Chromium (+ suite) Code (TypeScript) Per-run, 3 separate bills ~$4–6.50 / 1k Datadog Enterprises that want APM correlation Chrome/FF/Edge Recorder + code Per-run × freq × locations ~$12–18 / 1k Grafana Cloud / k6 OSS-leaning teams, best free tier Chromium (k6) Code (k6) + convert Per-execution ~$50 / 10k Better Stack Bundled monitoring + on-call Chromium Code + codegen paste Per-minute + per-seat ~$1 / 100 PW-min New Relic Broad type matrix + compliance Selenium (Chrome/FF) No-code step + code Per-check + seats + ingest ~$50 / 10k Sematext Predictable per-monitor pricing Chromium Code Per-monitor / month ~$7 / browser monitor Site24x7 No-code recorder + many locations Chrome/FF Recorder Pooled "advanced checks" ~$10 / 10k runs How we evaluated Real synthetic monitoring is more than a scheduled ping, so we scored each tool on six dimensions. Browser fidelity : does it run a modern engine (Playwright/Chromium) or older Selenium, and how faithfully does it reproduce a real user? Authoring mode : can you write checks as code, record them point-and-click, or gen

DevHelm 2026-06-20 02:48 👁 11 查看原文 →
Dev.to

Qwen3.6-27B + vLLM + Hermes on 24GB VRAM: May 2026 Recipe

If you want to reproduce my current local Hermes Agent + Qwen3.6-27B setup, this is the shape I would start from. Target One local coding agent. One 24GB GPU. Long context. Tools enabled. Thinking enabled. No child agents fighting the main request. The goal is not peak tok/s on a short prompt. The goal is: can the same agent session keep working after hours of tool calls without losing prefix locality, timing out during prefill, or getting wrecked by auxiliary requests? Model This setup is intentionally text-only. I am not serving the multimodal GGUF variant here. The working configuration uses groxaxo/Qwen3.6-27B-GPTQ-Pro-4bit through vLLM with --language-model-only . That choice matters. On a 24GB RTX 3090, the text-only GPTQ-Marlin path gave the best balance I found between long context, prefix caching, stable agent behavior and usable decode speed. Vision should be handled by a separate service/model if needed. vLLM The useful shape: CUDA_VISIBLE_DEVICES = 0 vllm serve groxaxo/Qwen3.6-27B-GPTQ-Pro-4Bit \ --served-model-name qwen3.6-27b-gptq-pro-4bit \ --dtype float16 \ --quantization gptq_marlin \ --tensor-parallel-size 1 \ --max-model-len 131072 \ --max-num-seqs 1 \ --kv-cache-dtype fp8_e5m2 \ --enable-prefix-caching \ --reasoning-parser qwen3 \ --enable-auto-tool-choice \ --tool-call-parser qwen3_coder \ --gpu-memory-utilization 0.95 \ --max-cudagraph-capture-size 32 \ --language-model-only I used a recent vLLM nightly, not an old stable image ( 0.20.1rc1.dev16+g7a1eb8ac2 ). The two flags people will want to argue about: --max-num-seqs 1 --max-model-len 131072 I use max_num_seqs=1 deliberately. With an agent, parallelism is not free. Title generation, context compression, retries, browser checks, tool calls and side jobs can all steal KV/cache locality from the main request. On one 24GB GPU I prefer one useful request over two requests sabotaging each other. 131k context is tight, but workable here. If your service OOMs, reduce context before adding MTP or enf

Xavier Rey-Robert 2026-06-20 02:47 👁 10 查看原文 →
Dev.to

Docker for Beginners: Why Containers Changed Software Development Forever

If you've ever heard the phrase "it works on my machine", you already understand the exact problem Docker was built to solve. Before Docker existed, deploying software was painful. Developers would spend hours — sometimes days — configuring servers, managing dependencies, and debugging environment-specific issues. Docker changed all of that by packaging applications and their dependencies into lightweight, portable units called containers. What Exactly Is a Container? Think of a container like a shipping container in the real world. No matter what's inside — electronics, furniture, food — it fits on any ship, truck, or train. In software, a Docker container holds your application code, runtime, libraries, and configuration, all bundled together so it runs identically anywhere: your laptop, a staging server, or a cloud provider. This is fundamentally different from virtual machines (VMs). While VMs emulate an entire operating system — making them heavy and slow to start — containers share the host OS kernel and start in milliseconds. They use far less memory and disk space, making them ideal for modern microservices architectures. The Core Docker Concepts You Need to Know Image : A read-only template used to create containers. Think of it as a recipe. You define it in a Dockerfile, and Docker builds it into an image. Container : A running instance of an image. You can run multiple containers from the same image simultaneously. Dockerfile : A plain text file with instructions for building a Docker image. Every command in the file adds a new layer to the image. Docker Hub : A cloud registry where you can find and share Docker images. It's like GitHub, but for container images. Docker Compose : A tool for defining and running multi-container applications using a YAML file. Your First Docker Commands Getting started with Docker is simpler than most developers expect. After installing Docker Desktop on your machine, you can run your first container with a single command:

Fabricio Artur 2026-06-20 02:46 👁 10 查看原文 →
Dev.to

My API Responded in 4 ms, but Navigation Still Felt Slow

I was debugging an internal project management application built with SvelteKit and a Rust API. Locally, navigation felt almost instant. On the VPS, opening the Tickets, Timeline, and OpenSpec docs pages felt noticeably slower. Clicking a ticket also took too long before the preview panel became useful. My first assumption was infrastructure: Maybe the VPS was underpowered. Maybe PostgreSQL queries were slow. Maybe the reverse proxy added latency. Maybe SvelteKit SSR was taking too long. The measurements pointed somewhere else. The Baseline I started with the feature list endpoint used by both Tickets and Timeline. For a project with 52 tickets: Metric Result API response time ~4 ms Response size 353,956 bytes Number of tickets 52 The API was not slow. But it was returning around 354 KB for a list of only 52 items. The SvelteKit route payload showed the same pattern: Route Data payload Tickets 349,857 bytes Timeline 354,731 bytes This explained why local testing was misleading. On localhost, transferring and parsing a few hundred kilobytes is easy to miss. Once the app runs behind a VPS, reverse proxy, TLS, and a real network connection, the payload becomes much more visible. What Was Inside the Payload? I broke down the feature response by field. The descriptions alone accounted for: 296,177 bytes That was more than 80% of the complete response. The list endpoint was returning something similar to this for every ticket: interface FeatureListItem { id : string ; title : string ; status : string ; priority : string ; storyPoints : number | null ; dueDate : string | null ; description : string | null ; checkoutCommand : string | null ; openSpecCommand : string | null ; } The problem was not that these fields were useless. They were useful on the ticket detail panel. They were not useful when rendering the initial list. Timeline was even more wasteful. It used ticket status, dates, dependencies, and assignees, but still downloaded every full Markdown description. The D

Awaliyatul Hikmah 2026-06-20 02:35 👁 9 查看原文 →
Dev.to

No user verification leading to subscription bypass and pre-register

For security reasons, we consider "Target app", as the target we practiced on, and the real name won't be disclosed in this post. The target app, was a niche music streaming platform, available in web and mobile PWA, meaning the structure is same but access is easier for cross platform. The app worked in this way : You register using an account, 3rd party like google or via email After that you can use the app for free with a 3 day window (3 day trial) After the 3 day you gotta buy subscription to continue listening The flaw, existed in the first step, when you register using an email, no verification happens! You could enter any type of string@something.com , a random password and start your free trial. So what happens is that first I use string1@something.com , for 3 days. When the time runs out, I use string2@something.com for another 3 days. And since the app's trial and actual subscription don't have any difference, and the 3 day time window is the only limitation, the user with such knowledge from the app doesn't need to buy any subscriptions while such flaw exists! Mitigation : Apply email verification step after user input, so they have to use the received link to verify their address Blacklist "temporary email" service's address or IPs, so users won't generate any email to register after their trial has expired. This way, the registration process isn't too complex while keeps app from attackers avoiding a "For ever free" usage on the app.

Bijan 2026-06-20 02:30 👁 10 查看原文 →
Dev.to

Metadata Routing

Stop Fighting Scikit-Learn Pipelines: How Metadata Routing Fixes Sample Weights & Groups A couple of months ago, I stumbled upon this video by Vincent D. Warmerdam about metadata routing in scikit-learn. I'll be honest, I had no idea what "metadata routing" even meant, but Vincent's explanation completely changed how I think about building ML pipelines. The video showed me that one of the most frustrating problems in scikit-learn; passing sample weights and groups through complex pipelines finally had an elegant solution. It piqued my curiosity enough that I dove deep into the feature, tested it extensively, and honestly, I was surprised by how little coverage this gets in technical blogs and articles. So I figured, why not write about it myself and share what I learned? If you've ever struggled with imbalanced datasets, grouped cross-validation, or just wanted to pass custom information through your pipelines, this article is for you. Let's start from the very beginning. What is "Metadata" in Machine Learning? Let's start with a concrete example. You're building a credit card fraud detection model with this data: # Your training data X = transaction_features # Amount, merchant, time, location, etc. y = is_fraud # 0 = legitimate, 1 = fraud # But you also have additional information: sample_weights = [ 1.0 , 1.0 , 10.0 , 1.0 , ...] # Fraud transactions weighted 10x customer_ids = [ 101 , 102 , 101 , 103 , ...] # Which customer made each transaction Metadata is the "extra information" beyond your features (X) and labels (y): sample_weight : How important is each transaction? (Fraud = 10x more important) groups : Which customer does each transaction belong to? (For proper cross-validation) Custom metadata : Transaction timestamps, confidence scores, data quality flags, etc. Why Metadata Matters: The Credit Card Fraud Problem Imagine you're building a fraud detection system for a financial company. You have: Imbalanced data : 99% legitimate transactions, 1% fraudulent T

Akshay Dev Karama 2026-06-20 02:28 👁 13 查看原文 →
Dev.to

Pro File Uploads in Rails 8: Speed and Scalability with Direct Uploads

Imagine a user trying to upload a 100MB video or a high-resolution photo to your app. If you use the standard Rails file upload, that file travels from the user's browser to your Rails server, and then your server sends it to S3 or Google Cloud. This is a terrible way to do it. While that 100MB file is transferring, your Rails worker (Puma) is frozen. It can't handle other users. If three people upload large files at once, your whole app will stop responding. In 2026, the professional way to handle this is Direct Uploads . With Direct Uploads, the file goes directly from the user's browser to your cloud storage (S3, R2, etc.). Your Rails server only handles a tiny bit of metadata. It is faster for the user and much safer for your server. Here is how to set it up in Rails 8. STEP 1: Configure Your Storage First, make sure you aren't using the local disk for production. You need a cloud provider like AWS S3 or Cloudflare R2. In your config/storage.yml : amazon : service : S3 access_key_id : <%= ENV['AWS_ACCESS_KEY_ID'] %> secret_access_key : <%= ENV['AWS_SECRET_ACCESS_KEY'] %> region : us-east-1 bucket : my-app-uploads # Crucial for Direct Uploads! public : true Note: You must configure CORS in your S3/R2 dashboard to allow requests from your domain. If you don't do this, the browser will block the upload. STEP 2: The Rails Form Rails makes the backend part incredibly easy. You just add one attribute to your file field: direct_upload: true . <!-- app/views/users/_form.html.erb --> <%= form_with ( model: user ) do | f | %> <div class= "field" > <%= f . label :avatar %> <%= f . file_field :avatar , direct_upload: true %> </div> <%= f . submit "Save Profile" %> <% end %> When you add direct_upload: true , Rails automatically includes a JavaScript library that handles the "handshake" with S3. STEP 3: Adding a Progress Bar (The UX Win) Direct uploads can take a few seconds. If nothing happens on the screen, the user will think your app is broken. We can use the built-in Ac

Zil Norvilis 2026-06-20 02:28 👁 11 查看原文 →
Dev.to

When automation meets simplicity over Python or Ansible

We constantly hear that Ansible and Python are apparently the only ways to automate networks, today I even listen in a conversation "Python is the industry standard" probably I missed the RFC document or probably the guy was referring to a sales standard, but back to us what happens when the framework, the platform or the software we are using becomes heavier than the problem to solve? There is a moment where automation becomes necessary, not because we want to look modern, not because every task deserves a framework and not simply because adding automation automatically means we are doing things better. It becomes necessary because repeating the same command collection manually across many devices is slow, risky, boring and almost impossible to diff and validate properly especially under pressure. For this reason I built the Cisco Go Collector during a real migration activity with a very practical goal: collect configuration and command outputs from Cisco devices in an easily repeatable way, without forcing every colleague involved in the process to become developers or to install an automation stack just to run a super simple flow. The idea was simple: define the devices in a CSV which is the comfort zone for everyone define the commands in the same CSV file, super simple and organized to manage one row per device run a portable Go binary against that CSV file collect the outputs in organized text files archive the result as operational evidence that can be easily diff That is it! super lightweight to run no Python virtual environment no Ansible playbook structure no inventory hierarchy no framework onboarding no additional runtime or software on corporate managed workstations just a CSV file and a compiled binary The automation and AI trap when the solution is heavier than the problem to solve I love automation and I fully support AI if used the proper way, but we have to find a balance and recognize when to choose one tool over the other and specially one progra

Tia Zanella 2026-06-20 02:21 👁 10 查看原文 →