Что-то вы гоните насчет "привычного вида формата 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
🚀🚀Raining Profits in the Premium Group
🎯🎯#FLOCK/USDT has covered all the targets to give an amazing profit of 142% for all Premium Members
👁🗨Contact @futurechief to enter the premium group & make daily gains on Futures as well as Spot Market
☑️☑️Below you will see the Futures Premium Signals Results for (24th February 2026)
🚀#FLOCK-USDT - 142% profit
🚀#ESP-USDT - 24% profit
❌
✅✅Net Profit = 166% Profit
👇🏻Signals Summary
➕Total Signals Sent out - 02
✔️Profitable Signals - 02
✖️Total Signals Lost - 00
◼️Trade cancelled without being executed - 00
✅✅Net Profit - 166% Profit
👁🗨Contact @futurechief to enter the most profitable Futures Premium Signal Group
Flock Secures $3M in Funding
Web3 AI training firm Flock has successfully raised $3M in a strategic funding round led by Digital Currency Group (DCG). Notable participants included Lightspeed Faction, Animoca Brands, Fenbushi Capital, Gnosis DAO, Bas1s Ventures, A41, and GSR Markets LTD.
#Web3#AI#Funding#Flock#DigitalCurrencyGroup#LightspeedFaction#AnimocaBrands#FenbushiCapital#GnosisDAO#Bas1sVentures#A41#GSRMarkets
Innovative Startups Raise Millions in Funding
A roundup of recent startup funding successes:
- Xiao Shangquan: $4.12M on Dec 16 for an ad investment platform for local merchants. Learn more
- Takumi Giken Kogyo: $3.26M on Dec 17, aims to innovate manufacturing while addressing social issues. Learn more
- FLock.io: $3M on Dec 19, building a decentralized privacy-preserving AI solution. Learn more
- Proxgy: $3M on Dec 26, creating a comprehensive ecosystem for global industries. Learn more
- RadioNano Therapeutics: $954.66K on Dec 25, advancing new cancer treatments from Kyoto University. Learn more
- Abastores: $788.78K on Dec 16, legal service for suppliers. Learn more
- EduCare: $778.73K on Dec 16, financing education and career support. Learn more
- Inyanga Marine Projects: $640.27K on Nov 29, specializing in tidal array technology. Learn more
- Kloutit: $559.69K on Dec 19, using AI to enhance chargeback defenses. Learn more
- EnviraBoard: $538.97K on Nov 30, focused on carbon-negative building materials. Learn more
#Funding#Investment#XiaoShangquan#TakumiGikenKogyo#FLock#Proxgy#RadioNano#EduCare#InyangaMarine#Kloutit#EnviraBoard#AI#Crypto#VC