
У Битрикса есть официальная обёртка для REST API — класс CRest, который лежит в каждом примере приложения и который все копируют к себе в проект. Он умещается в один файл и работает — ровно до того момента, пока приложение не выходит в реальную эксплуатацию с несколькими порталами и фоновыми воркерами.
Один баг стокового CRest однажды стоил мне шести суток простоя приложения, и причина была в одной строке: file_put_contents без блокировки. При обрыве записи settings.json оставался обрезанным, парсинг JSON падал, и приложение считало себя неустановленным — переставало отвечать на события и затирало валидные токены.
Я переписал CRest с нуля под то, как приложения Bitrix24 работают на самом деле:
— атомарная запись через rename() вместо file_put_contents — читатель видит либо старый файл целиком, либо новый, обрезка невозможна физически; — гонкоустойчивый refresh: одноразовый refresh_token больше не сжигается дважды, когда два воркера одновременно ловят протухший токен; — ключ портала — member_id, а не домен, поэтому переезд портала на другой домен больше не теряет токены; — drop-in совместимость со стоковым CRest: меняется одна строка use, весь остальной код остаётся как есть.
Ноль зависимостей, PHP 8.1, работает на любом шареде и коробке — в отличие от официального b24phpsdk с его symfony-стеком. Разбираю каждую граблю с кодом, показываю, чем это чинится, и честно очерчиваю нишу: типизированные обёртки по методам API — territory официального SDK, у меня их осознанно нет.
Исходный код открыт.
Читать далееHungary and Romania face energy crisis as record-low river levels force atomic power plants to reduce output
Romanian naval forces carried out a controlled explosion to help redirect vital cooling water from the drought-hit Danube to the country’s last working nuclear reactor, while neighbouring Hungary said it may be able to eke out two more days of power from its only atomic plant.
Hungary and Romania have been forced to shut down nuclear reactors cooled by the Danube for the first time, as record-low water levels deepen fears of an energy crisis across the region.
Continue reading...Hungary and Romania face energy crisis as record-low river levels force atomic power plants to reduce output
Romanian naval forces carried out a controlled explosion to help redirect vital cooling water from the drought-hit Danube to the country’s last working nuclear reactor, while neighbouring Hungary said it may be able to eke out two more days of power from its only atomic plant.
Hungary and Romania have been forced to shut down nuclear reactors cooled by the Danube for the first time, as record-low water levels deepen fears of an energy crisis across the region.
Continue reading...
Четыре месяца, 1823 коммита и около 200 000 строк кода: мобильное приложение для изучения английского, почти целиком написанное через LLM-агента. Я формулировал задачи, ревьюил и принимал архитектурные решения, но код руками набирал редко.
Статья не про то, как здорово, что нейросети пишут код. Она про два места, где эта схема ломается насмерть. Первое — энтропия: локально агент пишет аккуратный код, но через двести коммитов в проекте три способа поднять модалку и четыре файла с константами анимаций. Второе — физическая реальность и невысказанные инварианты: 109 коммитов ушло на одно движение шторки над клавиатурой, а на то, чтобы «забудь» в памяти питомца работало честно, понадобилась отдельная спецификация.
Внутри: конституция проекта в CLAUDE.md, четыре слоя храповиков (включая обёртку над git, которая не даёт обойти хуки), разбор пяти причин, почему анимация рвалась на реальном Android, и слоистая память на pgvector с локальными эмбеддингами.
Читать далееNow you’ve seen the new Spidey, let’s talk about new baddies (or are they goodies?), X-Men alumni, painful relationships and a potential Spidey-pig
• This article contains spoilers for Spider-Man: Brand New Day
There was a danger that Spider-Man: Brand New Day might amount to little more than a palate cleanser between the multiversal excesses of No Way Home and the all-star chaos of Avengers: Doomsday. Why not just keep it small: a more grounded tale of New York crime-fighting, to keep the Marvel machine rolling before the inevitable return of world-ending stakes? Instead, the studio, once again in partnership with Spider-Man rights holder Sony, has produced a gamechanging comic book epic whose effects will continue being felt for years to come.
The film’s biggest twist is significant enough on its own, but Brand New Day keeps widening the implications long after the initial shock has started to wear off. Characters who seemed to exist for one purpose gradually reveal another. Throwaway conversations acquire unexpected significance. New gadgets, strange abilities and apparently routine subplots all hint at much broader shifts taking place beneath the familiar web-slinging adventure. By the time the credits have rolled, the film has answered some longstanding questions, raised several more, and left audiences with a surprisingly clear idea of where the Marvel Cinematic Universe (MCU) could be heading next.
Continue reading...
The United States and Japan have coordinated to prop up the yen after the currency fell to a 40-year low against the dollar.
In a statement Monday morning, Japan’s Finance Minister Satsuki Katayama said the action was taken “pursuant to the U.S.-Japan Finance Ministers' Joint Statement issued in September 2025 and countered excessive volatility and disorderly movements in the Japanese yen in recent months.”
The two countries “will not hesitate to conduct further joint intervention,” she emphasized, reflecting on the action carried out Friday.
The rare move marks the first joint intervention since 2011, after Japan was struck by a devastating earthquake and tsunami and the U.S. joined other G7 nations in coordinated action to weaken the yen.
The yen is historically weak largely due to Japan having notably lower central bank interest rates than other major economies.
According to Bloomberg analysis of central bank data, Japan most likely used around $34 billion intervening in the currency market to support the yen. TIME has been unable to independently verify these figures.
“Economic security is national security. And the U.S.-Japan alliance is built on both,” said U.S. Treasury Secretary Scott Bessent on Sunday.
Bessent also indicated the U.S. may consider increasing the size of the Federal Reserve's repurchase facility providing temporary dollar liquidity. “The FIMA Repo Facility is an important backstop. We would encourage it to be upsized in the coming months,” he said.
When asked why the United States intervened to support the Japanese currency, U.S. President Donald Trump told reporters aboard Air Force One over the weekend that the U.S. is “always there” for Japan.
"They have a weakening yen, and they wanted a little bit of help,” he said. When questioned over what the U.S. is “getting out of that arrangement,” Trump replied “financial benefit,” but emphasized it’s also “good for the world economy.”
This is not the first time that the Trump Administration has intervened in another country’s currency. In October 2025, Bessent announced U.S. financial support for Argentina, which included a $20 billion currency swap framework with Argentina’s central bank.
Japan had already expressed “serious concern” over the yen's rapid depreciation in March and conducted unilateral intervention between April 28 and May 27.
Despite those efforts, the currency continued to weaken, with the yen sliding to 163.73 per dollar on Thursday before rebounding to 157.57 on Friday.
One reason a stronger yen matters is Japan's dependence on imported energy. According to the International Energy Agency, Japan remains heavily reliant on imported oil and gas, particularly from the Middle East.
A summary of opinions at the Bank of Japan's Monetary Policy Meeting in January warned that while the yen's “depreciation pushes up the profits and wages of large firms, it pushes down those of small and medium-sized firms—coupled with the yen's depreciation pushing up prices, this could lead to wider inequality.”
As for how the yen depreciated, Japan's comparatively low interest rates have remained a key factor weighing on the currency. The Bank of Japan’s 1% rate remains below the Federal Reserve’s 3.5% to 3.75% target rate, the International Monetary Fund has previously said the yen-dollar exchange rate has been driven by shifts in these interest rates differentials.
The Bank of Japan was slow to raise rates across the 2000s and 2010s in fear that it could curb efforts to break out of the country’s “structural deflation"—a multi-decade economic stagnation, says Brad Setser, a senior fellow at the Council on Foreign Relations who served as a senior advisor to the U.S. Trade Representative from 2021 to 2022.
“The core reason why the yen is weak is that nominal Japanese policy rates, the rates set by the central banks, are well below that of the Fed, which creates an incentive to hold dollars, and it's also below inflation,” he tells TIME.
However, a weaker yen has meant that investors are less likely to invest in the country, which in turn has further contributed to the depreciation of the currency.
“Japan both has a low [interest] rate, and a rate that's below the rate of inflation, so that has disincentivized investors from wanting to hold a lot of yen-denominated assets, and that's one of the big factors behind the yen's weakness,” says Setser.
An Oxford Economics report shared with TIME determined that the U.S.-Japan coordinated intervention will likely have a longer-lasting effect compared to Japan’s previous unilateral interventions, but predicted it will still not be enough to reverse the trend of yen weakness.
“The coordinated intervention will likely temporarily halt the yen’s depreciation, but it won’t cure all that ails it,” researchers argued. “Intervention over the past several years has led to movements in the yen in the short run but has failed to durably reverse the underlying depreciation trend and a similar pattern is likely to play out this time.”
Setser similarly argues that the main goal of this intervention is likely just to “keep the yen at this level, around this range, until the Bank of Japan has its next meeting."
There are various factors the U.S. may have considered ahead of coordinating in propping up Japan’s currency, experts say.
A weaker yen would “encourage firms globally to invest in Japan... rather than invest in the U.S,” Setser argues, elaborating on potential financial reasoning.
“That's what a weak currency does, it says you're going to make more money producing here, and so it creates a disincentive for investing in the U.S.”
A persistently weak yen could also trigger the selling of U.S. bonds held by Japan, placing additional pressure on the bond market, at a time when both the U.S. and Japan deal with rising government borrowing costs, he says.
The burgeoning alliance between Trump and Japan’s first female Prime Minister Sanae Takaichi is another factor to consider.
“Trump is a political animal, he likes Takaichi, and Takaichi wanted a stronger currency,” Setser tells TIME.
Takaichi hosted Trump in October 2025, where delegations from both countries held a signing ceremony to mark the bilateral framework agreement on critical minerals and trade.
During an address to U.S. forces aboard the U.S.S. George Washington in Yokosuka, Japan, Trump invited Takaichi to join him on stage to tout the strong bond between the two countries.
“The cherished alliance between the United States and Japan is one of the most remarkable relationships in the entire world,” he said. “Born out of the ashes of a terrible war, our bond has grown over eight decades into the beautiful friendship that we have—a foundation of peace and security.”
In February 2026, Trump endorsed Takaichi ahead of the country’s snap election. She ultimately led her party to a landslide victory.
A month later, when hosting Takaichi at the White House, Trump described her as a “very popular, powerful woman” and once again praised the “tremendous” relationship between the U.S. and Japan.

Открыть ТОО в Казахстане можно быстро. Сложнее понять, как это ТОО будет принимать платежи от клиентов из США и Европы.
Читать далее
Привет, мы производим детские игрушки для бренда JackoToys, хотя большинство игроков на рынке просто закупает их из Китая. Но качественные китайские игрушки стоят от 5 тысяч рублей, а в масс-маркете импортёру приходится закладывать в цену доставку и пошлины, поэтому он экономит на сырье. Свои сложности есть и у нас, за последнее время маржа упала с 30% до 10%. И даже в такой ситуации мы продолжаем упаковывать игрушки в две коробки, и вот почему мы это делаем.
Читать далее
Лет 6 назад я мог убить вечер в документации или в исходниках фреймворка ради одного метода. Докапывался до ядра, находил способ заменить 15 строк на 3 и ходил довольный неделю. Это был спорт: я знаю платформу глубже, чем ее среднестатистический разработчик.
Сейчас я пишу агенту: подними xhprof на дев-стенде, прогони сценарий оформления заказа, агрегируй, покажи топ виновников. И иду наливать кофе
Читать далее
Пользователи не читают ваши страницы — они их сканируют. Взгляд прыгает по подзаголовкам, как по слоям пирога, и от того, что он там находит, зависит, останется человек или уйдёт. Разбираю паттерн layer-cake, F-паттерн и почему всё решается на этапе вёрстки, а не редизайном.
Читать далее
Spokane Mayor Lisa Brown says nearly half of the city's neighborhoods have either been evacuated or are at risk as the fires remain uncontained.
(Image credit: Young Kwak)

TL;DR
Железо: 2× NVIDIA DGX Spark (GB10, SM121), 128 GB unified номинально и около 122 GiB видимых системе на ноду, QSFP 200G / RoCEv2, TP=2, драйвер 580.159.03.
Основную часть расхождения объяснила смена runtime‑образа. Переход со сборки на базе vLLM 0.21.1 на образ с 0.25.2 дал около +22% на том же чекпоинте. Конкретный коммит или компонент я не изолировал: поменялся весь пакет.
Механика неочевидная: новый образ снизил расчётную частоту verification‑шагов примерно на 17%, но поднял число выходных токенов за шаг с 3.27 до 4.80.
Главная находка в конфиге: --moe-backend flashinfer_b12x не выбирается режимом auto. Явное включение дало +13.3% по среднему пяти прогонов на card‑like профиле (59.7 против 67.6) и +16.6% по медиане.
B12X работает иначе: поднимает SSE‑derived частоту verification‑шагов на 16–18%, при этом выходные токены за шаг снижаются примерно на 2.5% в обоих профилях. Итоговый прирост клиентской decode‑метрики составил 13.3–14.6% по средним и 15.6–16.6% по медианам.
Итог: 67.6 tok/s на одиночном запросе, 260 tok/s суммарно на 12 параллельных запросов.
Отрицательные результаты, погрешности и границы применимости вынесены в отдельные разделы.
Читать далееBayreuth festival theatre, Bayreuth
For the festival’s 150th anniversary, the creative team have turned to AI to generate visuals reflecting Wagner’s tetralogy’s past, present – and future. The hyperactive result is a dismal, mindless mess
Unveiled the same week in which tech company Anthropic admitted that its AI model Claude had gone rogue during testing, Bayreuth festival’s new AI-generated staging of Wagner’s four-part Ring of the Nibelungen is at least timely. But anyone who assumes that the cycle’s obsession with knowledge, power and possession might make it an ideal forum for reflection on AI as a major contemporary frontier will be disappointed, as will anyone hopeful about AI’s creative potential within opera.
Commissioned to mark the festival’s 150th anniversary, the production is “curated” – emphatically not “directed” – by a team led by German stage director Marcus Lobbes. He apparently spent weeks in dialogue with AI models about possible interpretations of the Ring. According to the programme book, “power structures, capitalism, mythology, gender roles, nationalism”, all came up. So far, so mainstream Wagner reception. But if these human-machine exchanges were revelatory, you wouldn’t know it from the resulting staging, which uses AI “as an extension of a cultural memory that is never complete”.
Continue reading...
Привет, Хабр! Go специально сделали маленьким языком. Ключевых слов немного, конструкций мало, за неделю осваиваешь синтаксис и начинаешь писать. Именно из-за этой простоты возникает ложное ощущение, что тут негде ошибиться — код компилируется, значит всё правильно.
А потом оказывается, что компилятор пропускает целый класс вещей, которые в других языках он бы отловил или которые просто устроены не так, как ты привык. Цикл, который выдаёт не те значения. Слайс, который меняется сам собой. Горутина, которая молча теряет ошибку. Всё это компилируется и запускается, а ведёт себя не так, как ожидаешь.
Собрал восемь ошибок, через которые проходит примерно каждый, кто приходит в Go из другого языка. Все — реальные, все встречаются в чужом (и своём) коде постоянно.
Читать далееJuan Jesús Vivas says influx seen as ‘at least encouraged or permitted’ by Rabat, as Spain demands EU solidarity
A growing chorus of voices has accused Morocco of helping to fuel the crisis in Ceuta, with the leader of the Spanish enclave describing last week’s border crossings as an attack on Spain’s territorial integrity that was seen as being “if not orchestrated, at least encouraged or permitted by Morocco”.
Spanish officials said on Monday that an estimated 69,500 people who had arrived late last week in Ceuta, a tiny Spanish territory in north Africa, had returned to Morocco in recent days. About 2,500 people who had made the crossing were believed to still be in Ceuta.
Continue reading...Police credited Jordan Salinas with limiting number of victims in attack on restaurant in Twin Falls, Idaho
A healthcare worker returning fire on a 24-year-old gunman who killed three people and wounded several others an In-N-Out Burger in Twin Falls, Idaho, has said his impulse to confront the attacker was “automatic” and “mechanical”.
That description from 35-year-old Jordan Salinas came in an interview with the Idaho Statesman that was published on Sunday, providing a detailed account of actions that police credited with limiting the number of victims in the attack a day earlier.
Continue reading...Juan Jesús Vivas says influx seen as ‘at least encouraged or permitted’ by Rabat, as Spain demands EU solidarity
A growing chorus of voices has accused Morocco of helping to fuel the crisis in Ceuta, with the leader of the Spanish enclave describing last week’s border crossings as an attack on Spain’s territorial integrity that was seen as being “if not orchestrated, at least encouraged or permitted by Morocco”.
Spanish officials said on Monday that an estimated 69,500 people who had arrived late last week in Ceuta, a tiny Spanish territory in north Africa, had returned to Morocco in recent days. About 2,500 people who had made the crossing were believed to still be in Ceuta.
Continue reading...Tributes paid across industry to provocative journalist who died after short illness
The writer and broadcaster Rod Liddle, a prominent columnist for the Sunday Times and the Sun, has died after a short illness. He was 66.
Liddle, whose provocative style attracted praise and criticism, also wrote for the Spectator magazine and earlier in his career edited BBC Radio 4’s Today programme.
Continue reading...A new book, Homes for Our Time, by Philip Jodidio, showcases the quiet revolution in green residential architecture
Continue reading...