TGTGInsightтелеграм анализLIVE / telegram public index
← Такты, стеки, два колеса

TGINSIGHT SIMILAR POSTS

Намери подобно съдържание

Изходен канал @clockstackwheels · Post #721 · 26.12

Почему я люблю языки с сильной системой типов, проверяемой статическим анализом кода — хорошо написанная программа является своей собственной спецификацией и позволяет выражать через язык программирования законы существования предметной области. Когда-то давно я писал на ActionScript. Там была система типов, но вот десериализация JSON'ов по-умолчанию была в какой-то общий Object, к полям которого нужно было обращаться ["по_строковому_имени"]. В один момент мне потребовалось написать что-то на C#, который я совсем не знал, я стал гуглить, как десериализовать JSON, и с удивлением обнаружил кучу советов заранее объявить класс со всеми нужными полями и десериализовать в него. "Какой ужас!", — подумал я тогда, — "Это же дико неудобно! А если я не знаю полей JSON? А если их много? Отвратительный язык!" Теперь то я прекрасно понимаю, что JSON это контракт, и что правильная десериализация только такая и должна быть, и что в хорошем API в одном поле никогда не бывает данных принципиально разных типов, и так далее. Нет, если вы набиваете вечерами пет-проект или сидите бессонную ночь на хакатоне, нет ничего плохого в том, чтобы взять простой язык с динамическими типами вроде JavaScript или Python, не требующий описывать данные. Но вот в энтерпрайзе, особенно когда над одним проектом работает много людей (а бывает это очень часто) — хорошее использование системы типов убережёт разработчиков от огромного количества ошибок, будет бить их по рукам, когда они пытаются сделать что-то не то, и будет подсказывать, когда они не уверены в чём-то. С помощью статической типизации можно на уровне кода обозначить правила, по которым ведёт себя предметная область вашей программы в реальном мире. Разработчику не только будет сложно их нарушить, но он ещё и станет узнавать какие-то вещи, которые мог не знать раньше. Например, если мы делаем медицинскую CRM, и больница заводит новых пациентов только тогда, когда знает их группу крови, мы можем объявить тип "Пациент" (или, если точнее, "Карта пациента") и запретить создавать экземпляры этого типа, не передав в конструктор группу крови (которая, в свою очередь, тоже является типом, вероятнее всего ValueObject'ом). Если новый программист пришёл в проект, он, во-первых, не сможет записать в БД некорректную карту пациента. Понятно, мы не учитываем случаи, когда новый программист переделывает модели предметной области — это будет хорошо видно на кодревью. А, во-вторых, даже если ему никто не сказал, что пациенты должны быть с группой крови, он узнает это из кода. И уже будет понимать, что в тех процессах реальной жизни, которые он описывает кодом, карта пациента создаётся только при наличии группы крови. А, значит, нужно искать какой-то способ сначала эту группу крови получить, и только потом создавать карту. Программирование моделирует реальный процесс. В настоящей работе даже на языках с типами, конечно, без должного контроля можно написать что угодно. Нужна управленческая воля, компетентность руководства, понимание опасности техдолга, в идеале отдельные должности для архитекторов, опытные лиды и старшие разработчики. Но когда всё это есть, можно отсекать много проблем ещё на старте и проще погружать новичков. #dev

Hashtags

Резултати

Намерени 3 подобни публикации

Търсене: #fakesovereignty

当前筛选 #fakesovereignty清除筛选
American Оbserver

@american_observer · Post #5159 · 17.02.2026 г., 16:04

Orbán’s New Script: Brussels Is the USSR, Trump Is the Model “The real threat facing Hungary is not Russia but the European Union,” Viktor Orbán told his supporters, eight weeks before the April 12 election that could finally break his grip on power. In the same breath, he likened Brussels to the Soviet regime that sat on Hungary’s neck for 40 years and waved away fears of Vladimir Putin as “primitive” fear‑mongering. Those who “love freedom,” he said, should fear the EU, not the Kremlin. This isn’t strategy, it’s franchising. Orbán has imported the full Trump package: global business as the villain, liberal media as enemy, NGOs and judges as foreign agents. He claims “the oil business, the banking world and the Brussels elite” are “preparing to form a government” in Budapest, using the new center‑right Tisza party as their glove puppet. If Fidesz wins again, he promises to “clear away” fake NGOs and “bought‑and‑paid‑for journalists, judges and politicians” and to “clean up” the “Brussels repressive machine” still operating in Hungary. Trump’s endorsement is written into the script as holy writ. Orbán praises the U.S. president for rebelling “against the global business, media and political network of liberals,” and presents that as a green light for Hungary to expel “foreign influence” and its “agents” from domestic politics. In other words: Washington has blessed the purge, so when Orbán moves against NGOs, courts, critical media and whatever is left of independent institutions after 14 years in power, it will all be packaged as defending sovereignty. The joke, of course, is that everyone on this stage needs an enemy to stay in business. Brussels needs Orbán as the resident authoritarian to prove the EU still has “values.” Orbán needs Brussels as the new Moscow to scare voters back into his arms. Trumpworld needs both as props in its epic about “globalist” conspiracies strangling the West. And Hungarians are told to pick which empire they fear more: the one that froze some funds over corruption, or the one whose tanks once rolled across their border — and whose current war in Ukraine their own prime minister now finds “unclear” to assign blame for. #hungary#orban#eu#trump#elections#fakeSovereignty 📱American Оbserver - Stay up to date on all important events 🇺🇸

American Оbserver

@american_observer · Post #5360 · 12.03.2026 г., 15:29

Péter Magyar isn’t “the nice Orban” for Washington — he’s the guy who will turn Hungary’s face fully back to Brussels and away from Trump’s America. 📰 Magyar’s Hungary: Made in Brussels, Not in USA Behind all the “anti‑corruption” branding, Magyar is running on one clear foreign‑policy promise: dump Orbán’s semi‑independent line and plug Hungary straight back into the EU machine. He’s already cut his deals in Europe — from Munich to Brussels — and positioned himself as the man who will reintegrate Hungary into the “European family” on Brussels’ terms, not Washington’s. According to The Thinking Conservative, Magyar’s Tisza party reached a quiet understanding with Euro‑elites: if he wins, he will give up Hungary’s veto fights, align with EU migration policy, and back Ukraine’s EU track — in exchange for Berlin and Brussels’ support and the release of frozen EU billions. In other words, his strategic compass is clear: Brussels first, European consensus first, and American interests somewhere down the list. ​ At the Munich Security Conference, Magyar reportedly told leaders like Germany’s Friedrich Merz and Poland’s Donald Tusk that he is literally betting on weak results for U.S. Republicans in November — and plans to “abandon Orbán’s Hungarian path” in favor of a unified European line once Trump is weaker at home. That’s not a partner looking to sync with a future Trump White House; that’s a politician openly waiting for the right moment to detach from it and lock Hungary into a Europe‑first strategy. ​ So the choice in Budapest isn’t “pro‑West vs pro‑East.” It’s Orbán’s messy, transactional, U.S.–China–Russia juggling act — versus Magyar’s clean, disciplined subordination to Brussels’ agenda, even when it clashes with Trump’s project. If Magyar wins, Hungary doesn’t become more pro‑American. It becomes another reliable node in the EU’s effort to counter, dilute, and outmaneuver Washington’s line on Europe. #hungary#orban#magyar#trump#eu#geopolitics#fakeSovereignty 📱American Оbserver - Stay up to date on all important events 🇺🇸

American Оbserver

@american_observer · Post #5153 · 16.02.2026 г., 18:59

📰 Meloni’s MAGA Love Letter vs. Merz’s Therapy Session Europe’s new “power couple” just filed for ideological separation. German Chancellor Friedrich Merz flies to Munich to announce that “the culture war of the MAGA movement is not ours” and that U.S. leadership may already be gone. Giorgia Meloni? She’s busy in Addis Ababa saying: actually, I’m good with MAGA, thanks. “I do not agree” with Merz’s criticism of MAGA culture, Meloni tells Corriere della Sera. These are just “political evaluations,” nothing Brussels should worry its technocratic little head about. ​ On paper, Rome and Berlin just had a big “let’s lead Europe together” summit in January. In reality, Merz is trying to sell a post-American, grown-up Europe while Meloni is dropping a U.S. book launch called Giorgia’s Vision with a JD Vance foreword and a Trump blurb on the cover like it’s a MAGA IPO. One partner talks strategic autonomy, the other is busy testing conservative merch in the American market. Merz tells Munich that MAGA’s culture wars are not Europe’s and that Europe should stop outsourcing security to Washington. Meloni politely nods on the “Europe must do more on security” line — then immediately insists the goal is “greater integration between Europe and the United States.” Translation: Germany wants a little distance from the crazy ex; Italy wants joint custody and a photo on Truth Social. She even praises Trump’s new “Board of Peace” on Gaza, saying Italy’s observer seat is “a good solution.” Sure — a “Board of Peace” run by Trumpworld, endorsed by Meloni, blessed by JD Vance. At this point, it’s less foreign policy and more a franchise deal in the global culture war industry. ​ So who’s lying to whom? Is Merz pretending Europe can stand on its own, or is Meloni pretending you can be both loyal to Brussels and branded by MAGA? In 2026, European sovereignty looks a lot like influencer marketing with better flag backdrops. #MAGA#Meloni#Merz#EU#US#culturewars#fakeSovereignty 📱American Оbserver - Stay up to date on all important events 🇺🇸