TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #281 · 18 авг.

Что-то вы гоните насчет "привычного вида формата 755 и 644". Я вот вообще не понял что это!😳 Действительно, что означают цифры которые мы получили в прошлом посте? Это кодировка, заключающая в себе режимы доступа к файлу. Подробней можно почитать в статье про chmod. Там можно увидеть альтернативное обозначение того же самого с помощью символов r w x, что значит чтение, запись, исполнение. Чтобы преобразовать восьмеричное число в такое обозначение в Python есть готовая функция >>> stat.filemode(0o755) '?rwxr-xr-x' Мы видим 3 группы по 3 символа, дающие 3 типа доступа для 3 типов юзеров. А что за знак вопроса в начале? Давайте передадим в эту функцию необрезанное значение от os.stat >>> stat.filemode(os.stat(path).st_mode) 'drwxr-xr-x' Это данные, которые мы безжалостно обрезали в прошлый раз😼 Первый символ обозначает тип объекта. Это может быть файл (-), директория (d) или симлинк (l). Вот простая схема данной кодировки [1][3][3][3] │ │ │ │ │ │ │ └──> Others Permissions │ │ └─────> Group Permissions │ └────────> Owner Permissions └───────────> File Type (разверните экран если вы с телефона) Если вы попробуете получить пермишены для симлинка то получите пермишены для файла >>> path = '.venv/bin/python3' >>> stat.filemode(os.stat(path).st_mode) '-rwxr-xr-x' Чтобы получить свойства именно симлинка, нужно это явно указать >>> stat.filemode(os.stat(path, follow_symlinks=False).st_mode) 'lrwxrwxrwx' #tricks#basic

Резултати

Пронајдени 2 слични објави

Пребарај: #accommodation

当前筛选 #accommodation清除筛选

🏨Recommended hotels for the RAREMET-2026 participants Dear participants of the RAREMET-2026 Congress! The Congress website contains information about hotels that are ready to receive you on special terms during the event. In this section you will find addresses, promo codes for reservations and their validity periods. 📌 Details are available on our website. 🗓Dates of the Congress: RAREMET-2026 will be held on May 20-22 in Moscow at the RTU MIREA. The organizer is Giredmet JSC. 📱 Subscribe to our channels: Telegram: t.me/raremet2026 MAX: max.ru/id7707072637_gos22 See you at the main forum of the rare metal industry! #RAREMET2026#RAREMET2026#hotels#accommodation#participants

🏨 ACCOMMODATION SECRETS: ETHIOPIA'S HIDDEN GEMS | ድንቅ የሆኑ የኢትዮጵያ ማረፊያ ቦታዎች 🌟 From royal palaces to mountain hideaways - discover where legends stay in the Horn of Africa. 🏨 LUXURY HOTELS | ቅንጡ ሆቴሎች • Sheraton Addis: $200-300/night, presidential suite where Obama stayed • Hyatt Regency: $150-250/night, rooftop views of Entoto Mountains • Radisson Blu: $120-200/night, modern amenities in heart of city • Four Points Sheraton: $100-180/night, business traveler favorite 🏡 TRADITIONAL GUESTHOUSES | ባህላዊ እንግዳ ማረፊያዎች • Yod Abyssinia: $60-80/night, authentic Ethiopian architecture • Taitu Hotel: $40-70/night, historic charm in Piazza district • Local family homestays: $15-30/night, genuine cultural immersion • Traditional tukuls: $25-50/night, round stone houses with thatched roofs 🏔️ ECO-LODGES & WILDERNESS | ተፈጥሮ ተስማሚ ስፍራዎች • Simien Lodge: $180-250/night, gelada monkeys at your doorstep • Buska Lodge (Omo Valley): $120-200/night, tribal cultural experience • Danakil camping: $40-80/night, sleep under Milky Way in Mars landscape • Lalibela mountain lodges: $80-150/night, rock churches views 💰 BUDGET ACCOMMODATIONS | የእርስዎን በጀት ያማከሉ ማረፊያዎች • Backpacker hostels: $8-15/night, shared dorms with Wi-Fi • Pension houses: $12-25/night, family-run, breakfast included • Government rest houses: $5-12/night, basic but clean • Church compounds: $3-8/night, unique spiritual experience 📱 BOOKING PLATFORMS & TIPS • Best platforms: Booking.com, Agoda, local Ethiopian sites • Direct booking: Often 10-20% cheaper, call hotels directly • Peak seasons: Christmas (Jan 7), Timkat (Jan 19), Meskel (Sept) • Negotiation: Always possible except peak times 💡 INSIDER SECRETS: Book mountain lodges 2+ months ahead. Many hotels accept USD directly. Traditional coffee ceremony often included. Ask for "faranji price" vs local rate. 🏆 From $3 sacred sanctuaries to $300 presidential suites - Ethiopia accommodates every dream! #EthiopiaHotels#ኢትዮጵያ#Accommodation#TravelSecrets#HiddenGems