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

Резултати

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

Пребарај: #weddingrituals

当前筛选 #weddingrituals清除筛选
Google Facts™ [ ️@googlefactss🌎]

@googlefactss · Post #40899 · 04.04.2026 г., 22:01

In parts of Togo, wedding ceremonies include the groom’s family performing dances and music. These performances show respect to the bride’s family and celebrate the upcoming marriage. The events often involve drumming, singing, and group dancing as part of the traditional festivities. 💃🥁💍🌍 [Read more] @googlefactss #marriage#culture#tradition#worldfacts#anthropology#africa#weddingrituals#travel If you have ideas or feedback contact us: @Googlefactss_Feedback_bot

Google Facts™ [ ️@googlefactss🌎]

@googlefactss · Post #40839 · 21.03.2026 г., 23:01

In certain Thai weddings, couples participate in the Sai Sin ritual, a sacred tradition rooted in Buddhist beliefs. A cotton thread, called Sai Sin, is blessed by monks before the ceremony. The thread is tied around the bride and groom’s wrists or connected around their heads. This ritual symbolizes protection, good luck, and spiritual blessings for the couple. Guests and family may also touch or tie pieces of the thread to pass on their blessings. The Sai Sin connects the newlyweds to their family, community, and the monks who bless them, emphasizing unity and shared support. It is often performed alongside other traditional Thai wedding customs like pouring holy water over the hands of the bride and groom. 🧵👰🤵🇹🇭 [Read more] @googlefactss #marriage#culture#tradition#worldfacts#anthropology#thailand#weddingrituals#travel

Google Facts™ [ ️@googlefactss🌎]

@googlefactss · Post #40872 · 28.03.2026 г., 23:01

In some Mexican weddings, couples participate in the Lazo ritual. A large cord or rosary is placed around the bride and groom in a figure-eight shape to symbolize unity and lifelong commitment. 🤍👰🤵🇲🇽 [Read more1] [Read more2] @googlefactss #marriage#culture#tradition#worldfacts#anthropology#mexico#weddingrituals#travel