SShortSingh.
Back to feed

Why Direct Browser Thumbnail Uploads Fail: CORS, Private Buckets, and Presigned Limits

0
·23 views

A browser upload to private object storage can fail even with a valid presigned URL, because the browser enforces CORS and the uploaded image still needs authorized delivery. The article advises presigning direct uploads only where the bucket's browser policy is already verified, and otherwise accepting files on the backend and generating thumbnails there. It explains that a presigned URL grants temporary access but does not configure CORS, create a public image URL, or resize images. It also stresses testing the authorization request and the byte transfer separately, and checking the browser preflight, since command-line success does not prove browser compatibility. Finally, it notes that private upload and private display are separate authorizations, with thumbnails served through signed reads or backend proxying.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Designing a Vehicle Pass System: Data Model and Edge Cases

A DEV Community article explains that building vehicle access software for residential communities involves more complexity than it first appears. It outlines core entities, including residents linked to units, vehicles with plate and ownership details, passes with issue and expiry dates, and gate logs recording movement. The piece highlights edge cases such as vehicle sales, tenant move-outs with active passes, temporary guest or delivery passes, duplicate or mistyped plates, and per-unit vehicle limits. It recommends keeping passes separate from vehicles so they can be revoked or renewed without losing historical records.

0
ProgrammingDEV Community ·

Claude Builds a Small Language Model From an Empty Folder, With Mixed Results

An experiment gave Claude an empty folder and no budget, tasking it with building a language model that could beat GPT-2 small using only free Kaggle hardware. Claude designed its own tokenizer, data pipeline and training recipe, and recorded predictions and pass marks before each run. Its first level was generating children's stories, where it added a custom 'narrative clock' idea that improved endings by about 7%. The first full run produced only four of ten required passing stories, falling short of its predicted seven. A retry with a larger model also missed its target, and the author ultimately chose to move on from that level.

0
ProgrammingDEV Community ·

alltradingapi Python client released on PyPI for Quotex market data

Quotex does not offer an official developer API, forcing traders to rely on headless browsers or unstable WebSocket connections. The independent alltradingapi package is now available on PyPI as a zero-dependency Python client for the All Trading API gateway. It provides access to candlestick data for OTC and currency pairs, supporting use cases such as trading bots, backtesting, and payout monitoring. The library includes a synchronous client, an asynchronous client for high-concurrency use, and built-in exponential backoff for rate limiting. It is MIT licensed and includes full type hints.

0
ProgrammingDEV Community ·

Paul Brenneke Fraud Allegations Highlight Need for Reliable Financial Calculation Software

A DEV Community article uses the investor lawsuit against Paul Brenneke and the Sortis Income Fund as context for discussing accuracy in financial software. The lawsuit, reported by Willamette Week on November 4, 2026, alleges the fund made loans to businesses tied to the Sortis network and raises questions about loan balances, disclosures, and management fees. Sortis disputes the allegations, and no court has yet found fraud or wrongdoing. The article notes the case does not establish that any software calculation failure occurred. It then offers developer guidance, such as using decimal arithmetic instead of floating-point numbers and separating loan components and idempotent payment processing to prevent errors.