Вторая по частоте future-функция, которую я использовал, это абсолютный импорт
from __future__ import absolute_import
Что она делает?
Изменения, которые вносит эта инъекция описаны в PEP328
Покажу простой пример.
Допустим, есть такой пакет:
/my_package
/__init__.py
/main.py
/string.py
Смотрим код в my_package/main.py
# main.py
import string
Простой пример готов) Вопрос в том, какой модуль импортируется в данном случае? Есть два варианта:
1. модуль в моём пакете my_package.string
2. стандартный модуль string
И вот тут вступает в дело приоритет импортов. В Python2 порядок следующий: помимо иных источников, раньше ищется модуль внутри текущего пакета, а потом в стандартных библиотеках. Таким образом мы импортнём my_package.string.
Но в Python3 это поведение изменилось. Если мы указываем просто имя пакета, то ищется именно такой модуль, игнорируя имена в текущем пакете. Если мы хотим импортнуть именно подмодуль из нашего пакета то, мы должны теперь явно это указывать.
from my_package import string
или относительный импорт, но с указанием пути относительно текущего модуля main
from . import string
Еще одной неоднозначностью меньше 😎
Подробней про импорты здесь:
https://docs.python.org/3/tutorial/modules.html
#2to3#pep#basic
News: Demonstration held in #Kobo town, #Amhara region, supporting House of Federation decision; IDPs allege pressure to participate
A public demonstration was held on Saturday in Kobo town, #North_Wollo Zone of the Amhara Region, in support of a decision by the House of #Federation and the National Election Board of #Ethiopia allowing elections to be conducted in disputed areas of the Raya zone outside the administration of the Tigray Region.
However, internally displaced people (#IDPs) and residents who participated in the gathering told Addis Standard they were warned that failure to take part could affect their access to humanitarian assistance.
On 23 February 2026, it was reported that Ethiopia’s House of Federation had ordered the upcoming federal parliamentary elections in five electoral districts previously under the Tigray regional state to be conducted outside the Tigray administration’s oversight until the “ownership claim is resolved.”..........
Read more: https://addisstandard.com/?p=55671
#Ethiopia: Over 1,000 teachers resign in #Amhara region, many reportedly migrating to Arab states – Report
Around 1,020 teachers in three zones of the Amhara Region resigned during the 2025/26 academic year, with officials and educators attributing much of the exodus to migration to #Arab_states in search of better pay and living conditions, according to a report by Deutsche Welle (DW).
The departures were recorded in #South_Wollo, #North_Wollo, and the #Oromo Special Zone, where local education authorities say the trend is worsening existing challenges in the education sector.
Teachers interviewed by DW cited the rising cost of living and salaries that no longer match market realities as key factors behind their decisions to leave.
In districts such as #Kobo and #Habru in North Wollo, as well as #Bati woreda in the Oromo Special Zone, including Saint, Wagdi and Albko woredas, teachers have increasingly resigned to pursue opportunities abroad, the report....
Read more: https://addisstandard.com/?p=55405
News: Flights to #Tigray remain suspended, affecting even Interim Administration president’s scheduled Addis visit
The continued suspension of #Ethiopian Airlines flights to Tigray has disrupted official travel, with Tigray Interim Administration President Tadesse Worede confirming that his planned visit to #Addis_Abeba did not take place due to the flight cancellations.
Asked by Addis Standard whether his visit was hindered by the suspension of flights, President Tadesse responded, “Yes.”
Flights to airports in Tigray, including #Mekelle, #Axum, #Shire, and #Humera, remained suspended on Friday, with Ethiopian Airlines yet to provide an official explanation for the disruption.
An Addis Standard reporter on the ground confirmed airline ticket office, however, remained open...
Meanwhile, road transportation in parts of Southern Tigray has also been disrupted. Transport movement along the #Woldiya–#Kobo–#Alamata corridor remains limited, while displacement
Read more: https://addisstandard.com/?p=54856