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

Резултати

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

Пребарај: #khotkovo

当前筛选 #khotkovo清除筛选
NIDO Russia (НИДО)

@nido_russia · Post #1692 · 04.07.2024 г., 15:51

NIDO Russia is organising an adventure trip for members to the festival Made in Khotkovo on the 6th of July 2024 & 7th of July 2024. See new places🪧, experience new local culture, cuisine 🍲 and music 🎼. Yurt camp 🏕, swimming 🏊‍♀️, deers 🦌 and local animals, folk concert/festival 🎼, food🥞, animation, bonfire🔥. Possibility to bring tent and stay overnight. 🤠There is a dedicated tour guide 🎼Musicians areprovided a platform to perform. Spread your talent and music all around Russia. Display African culture. It promises to be lots of fun! If interested, please contact us +79262385618 Estimated budget: 2000 rubles. Students enjoy discounts. You will be added to a special group chat after registration. Deadline for registration extended to 05.07.2024 12:00🙏 https://t.me/nido_russia/1692 #adventure#Khotkovo#concert#swimming#nidorussia

NIDO Russia (НИДО)

@nido_russia · Post #1687 · 02.07.2024 г., 08:37

NIDO Russia is organising an adventure trip for members to the festival Made in Khotkovo on the 6th of July 2024 & 7th of July 2024. See new places🪧, experience new local culture, cuisine 🍲 and music 🎼. Yurt camp 🏕, swimming 🏊‍♀️, deers 🦌 and local animals, folk concert/festival 🎼, food🥞, animation, bonfire🔥. Possibility to bring tent and stay overnight. 🤠There is a dedicated tour guide 🎼Musicians areprovided a platform to perform. Spread your talent and music all around Russia. Display African culture. It promises to be lots of fun! If interested, please contact us +79262385618 Estimated budget: 2000 rubles. Students enjoy discounts. You will be added to a special group chat after registration. Deadline for registration 03.07.2024🙏 https://t.me/nido_russia/1669 #adventure#Khotkovo#concert#swimming#nidorussia

NIDO Russia (НИДО)

@nido_russia · Post #1683 · 01.07.2024 г., 05:54

NIDO Russia is organising an adventure trip for members to the festival Made in Khotkovo on the 6th of July 2024 & 7th of July 2024. See new places🪧, experience new local culture, cuisine 🍲 and music 🎼. Yurt camp 🏕, swimming 🏊‍♀️, deers 🦌 and local animals, folk concert/festival 🎼, food🥞, animation, bonfire🔥. Possibility to bring tent and stay overnight. 🤠There is a dedicated tour guide 🎼Musicians areprovided a platform to perform. Spread your talent and music all around Russia. Display African culture. It promises to be lots of fun! If interested, please contact us +79262385618 Estimated budget: 2000 rubles. Students enjoy discounts. You will be added to a special group chat after registration. Deadline for registration 03.07.2024🙏 https://t.me/nido_russia/1669 #adventure#Khotkovo#concert#swimming#nidorussia

NIDO Russia (НИДО)

@nido_russia · Post #1669 · 27.06.2024 г., 12:54

NIDO Russia is organising an adventure trip for members to the festival Made in Khotkovo on the 6th of July 2024 & 7th of July 2024. See new places🪧, experience new local culture, cuisine 🍲 and music 🎼. Yurt camp 🏕, swimming 🏊‍♀️, deers 🦌 and local animals, folk concert/festival 🎼, food🥞, animation, bonfire🔥. Possibility to bring tent and stay overnight. 🤠There is a dedicated tour guide 🎼Musicians areprovided a platform to perform. Spread your talent and music all around Russia. Display African culture. It promises to be lots of fun! If interested, please contact us +79262385618 Estimated budget: 2000 rubles. Students enjoy discounts. You will be added to a special group chat after registration. Deadline for registration 03.07.2024🙏 https://t.me/nido_russia/1669 #adventure#Khotkovo#concert#swimming#nidorussia

NIDO Russia (НИДО)

@nido_russia · Post #1704 · 07.07.2024 г., 18:52

❤️😅 Memorable moments from adventure/excursion trip to Khotkovo! We all had fun and good company. The Major was in attendance and NIDO Russia was recognised for contribution to community. Subscribe:@nido_russia https://t.me/nido_russia/1710?single #news#Nigeria#Russia#Khotkovo#excursion#adventure#festival#madeinkhotkovo

NIDO Russia (НИДО)

@nido_russia · Post #1702 · 07.07.2024 г., 18:52

🍾🎉 The Mayor of Khotkovo and Sergiyev Posad Region (Dmitry Aleksandrovoch Akulov) meets NIDO Russia Chairman (Dr. Godwin Ibe) who receives an award for distinguished contribution to the community from the Director of Made in Khotkovo (Ms. Larisa Dmitrieva Rapaport) and Owner of Moscow Navigator (Ms. Irina Chulkova) Up Nigeria Russia relations! 🇳🇬🇷🇺 Subscribe:@nido_russia https://t.me/nido_russia/1702 #news#Nigeria#Russia#Khotkovo#excursion#adventure#festival#madeinkhotkovo