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

Резултати

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

Търсене: #khartoum

当前筛选 #khartoum清除筛选
Addis Standard

@addisstandardeng · Post #21065 · 14.01.2026 г., 05:51

#Sudan police unveil Khartoum security plan as government returns Sudan’s police on Tuesday outlined a sweeping security plan to protect the seven localities of #Khartoum state, hours before the cabinet and most federal ministries complete their relocation from the wartime seat of Port Sudan. Brigadier-General Fath al-Rahman Mohamed al-Tom told Sudan Tribune the force will deploy additional officers, reactivate criminal-investigation units and relaunch the “999” emergency call centre to handle civilian complaints. “Public facilities, bridges and river crossings are priority targets for protection,” al-Tom said, adding that patrols, fixed checkpoints and daily raids had already “dismantled a major cell in East Nile” and delivered “a measurable drop in crime”. He said the police command had introduced “modern technology” to monitor deployments and pledged “immediate disciplinary action” against any officer found in violation of regulations.... https://sudantribune.com/article/309333

Addis Standard

@addisstandardeng · Post #21272 · 02.02.2026 г., 06:41

News: #Khartoum airport receives first scheduled flight since start of Sudan war The international airport in Khartoum has received its first scheduled commercial flight in more than two years as the #Sudanese government continues to assert its control over Sudan’s capital city after years of fighting. The Sudan Airways flight travelled to Khartoum from the Red Sea city of Port Sudan on Sunday, carrying dozens of passengers. Reporting from near the runway where the flight had landed, Al Jazeera’s Taher Almardi described scenes of jubilation following the arrival of the plane. He said the reopening of the airport will help connect the capital to other regions in Sudan, with officials saying the facility is now ready to welcome as many as four flights daily. Sudan Airways said in a statement that the flight, which was announced on Saturday with ticket prices starting at $50, .... https://web.facebook.com/AddisstandardEng/posts/pfbid021sHpU1gGTz2SZF2qejYi6G1D3siDnLwXXK2hcCEsiHW1Qb8ADaaB8tGA4kq2MvEZl

Addis Standard

@addisstandardeng · Post #21506 · 24.02.2026 г., 05:04

#Khartoum resumes school year after three-year war-induced hiatus Schools in Khartoum state reopened this week after a three-year hiatus caused by #Sudan’s civil war, as officials scramble to repair hundreds of damaged buildings and accommodate a surge in returning students. The Khartoum State Ministry of Education said on Monday that approximately 280 schools in the capital were damaged or destroyed during the conflict, which broke out in April 2023 between the Sudanese army and the paramilitary Rapid Support Forces (#RSF). Many schools were repurposed as shelters for displaced families or occupied by warring factions, while the displacement of teachers & students led to a total collapse of the city’s educational system. Qariballah Mohammed Ahmed, Khartoum’s director of education, told Sudan Tribune that more than one million students are expected to enrol this year as families gradually return to the capital’s relatively stable neighbourhoods. “The number of... https://sudantribune.com/article/311035

Addis Standard

@addisstandardeng · Post #21184 · 26.01.2026 г., 05:31

#Sudan hospital welcomes first patients after war forced it shut At a freshly renovated hospital in #Khartoum the medical team are beaming: nearly three years after it was wrecked and looted in the early days of Sudan's war, the facility has welcomed its first patients. The Bahri Teaching Hospital in the capital's north was stormed by the paramilitary Rapid Support Forces in April 2023, soon after fighting broke out between the #RSF and Sudan's army. Bahri remained a war zone until an army counteroffensive pushed through Khartoum last year, recapturing the area from the RSF in March. "We never thought the hospital would reopen," said Dr Ali Mohamed Ali, delighted to be back in his old surgical ward. "It was completely destroyed, there was nothing left," he told AFP. "We had to start from scratch." Ali fled north from Khartoum in the early days of the war, working in a makeshift... https://web.facebook.com/AddisstandardEng/posts/pfbid0XGAcYjM8H8QZz4QCfQg6MRikKWJ89wV7gkm8xnEGntQfyvMvQBw2BsjXo8pPYgDQl

Addis Standard

@addisstandardeng · Post #21585 · 02.03.2026 г., 19:56

News: #Sudan government alleges drone attacks originated ‘from #Ethiopian territory,’ warns of action to defend sovereignty Sudan has accused Ethiopian authorities of allowing #drones to enter its airspace from Ethiopian territory and strike locations inside the country, warning of consequences and asserting its right to defend its sovereignty and territorial integrity. In a press release issued on Monday, 02 March 2026, the Ministry of Foreign Affairs and International Cooperation said the Government of Sudan had been monitoring what it described as the “entry of drones from within Ethiopian territory” throughout February and early March. #Khartoum warned Ethiopian authorities of what it called the consequences of such acts and reaffirmed Sudan’s right to defend its sovereignty “by all means necessary” to counter the alleged attacks. The ministry characterized the reported incidents as “hostile behavior” that …. Read more: https://addisstandard.com/?p=55508

Addis Standard

@addisstandardeng · Post #21041 · 12.01.2026 г., 06:49

#Sudanese gov't returns to #Khartoum after nearly 3 years of war Sudanese Prime Minister Kamil Idris on Sunday announced the return of the government to the capital, Khartoum, for the first time since the outbreak of war on April 15, 2023, after nearly three years of running state affairs from the eastern city of #Port_Sudan. "The government has returned to the national capital," Idris said in a speech to a crowd following his arrival in Bahri, north of Khartoum. He pledged to improve basic services, particularly in the health and education sectors, and to rebuild hospitals and rehabilitate schools and universities, foremost among them the University of Khartoum. The prime minister added that 2026 would be "the year of peace in Sudan," pointing to plans for reconstruction and development, as well as efforts to improve the economic situation by increasing gross national product, reducing inflation, and stabilizing the exchange .... https://english.news.cn/20260111/57d8cfd50a314aa4bcd1e90564c45698/c.html

Addis Standard

@addisstandardeng · Post #22111 · 25.04.2026 г., 08:28

Regional coalition in #Khartoum calls for peace, dialogue across #Sudan, #Eritrea, #Ethiopia Addis Abeba - A regional coalition bringing together representatives from Sudan, Eritrea, and Ethiopia has called for “peace, coexistence, and an end to ongoing conflicts”, during a public gathering held in Khartoum on 23 April, according to Sudan News Agency. The alliance, identified as the Coalition of the Peoples of Eritrea, Sudan, and Ethiopia, said the meeting reflected “the aspirations of the region’s peoples to live in peace and stability,” while promoting “the values of coexistence” and rejecting “hatred and conflict,” the outlet reported. Speakers and representatives drawn from various communities, including #Tigray, #Amhara, #Oromo, and #Somali constituencies, alongside delegates from Sudan and Eritrea, expressed a “unified stance against continued violence”. https://www.facebook.com/AddisstandardEng/posts/pfbid02sbMgZToVXPCPWfPjK8AQZCYEPVV7SZnsgP8oymTw5Hoajfw75J6qukUrXuV3oLShl

Addis Standard

@addisstandardeng · Post #21576 · 01.03.2026 г., 14:32

#Updates: #Sudan condemns #Iranian missile strikes but excludes #UAE; Trump Threatens with ‘Force Never Seen Before’ if Tehran Retaliates #Khartoum has issued a sharp diplomatic rebuke of Iran’s recent ballistic missile assault on #Gulf states — condemning attacks on #Qatar, #Bahrain, #Kuwait and #Jordan while conspicuously excluding the United Arab Emirates amid strained ties — as #US President Donald #Trump warned that Iran would face a level of force “never seen before” should it pursue further retaliation following the reported death of Supreme Leader Ali Khamenei. #Israel and the United States launched fresh waves of intensive strikes across Iran on the second day of their military campaign, escalating a confrontation that has plunged the Middle East into a rapidly widening regional conflict with no clear timeline or outcome. Sudan’s Ministry of Foreign Affairs on Saturday ..... https://web.facebook.com/AddisstandardEng/posts/pfbid0Akn9sXbPsGrVeyGeKmTrs5TUWEEWyvD83ttZhBmRbcUXNFyYkFBG4VmHmjAAvJzpl

Addis Standard

@addisstandardeng · Post #21964 · 07.04.2026 г., 12:56

News: Federal police charge suspected trafficking kingpin linked to deaths, abuse of migrants Addis Abeba —#Ethiopian Federal Police said it has referred to prosecutors the case of human trafficking kingpin #Yitbarek_Dawit (Kibrom) and nine accomplices, accused of orchestrating a cross-border network that trafficked more than 3,000 people and was linked to over 100 deaths and the rape of more than 50 women. In a statement, police said the suspect, described as an internationally wanted fugitive, was arrested in #Shire town in the #Tigray region following a coordinated operation conducted with the Regional Operational Centre in support of the #Khartoum Process. Authorities said the investigation involved extensive intelligence-sharing across multiple countries. Police said the suspect used multiple identities to evade capture, including names such as #Yitbarek Dawit Alemu, #Paulos Dawit Wolday, and aliases including #Adhanom, #Ahmed, #Munir, and Read more: https://web.facebook.com/share/p/1Arn3MFntC/