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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #214 · 12 фев.

Как правильно проверить атрибуты доступа файла? То есть доступна ли запись в файл или является ли он исполняемым? Для этого в Python есть функция os.access() Проверять так: os.access(path, flag) Функция вернёт bool в зависимости от наличия указанного флага. Всего есть 4 флага проверки: os.F_OK - наличие файла на диске os.R_OK - доступ на чтение os.W_OK - доступ на запись os.X_OK - доступ на исполнение Например, вместо try-except лучше делать так (пример из документации): if os.access("myfile", os.R_OK): with open("myfile") as fp: return fp.read() #basic#libs

Hashtags

Резултати

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

Пребарај: #cnft

当前筛选 #cnft清除筛选

🤔What is cNFT cNFT is a young technology in TON that allows you to create NFT collections with thousands or even millions of items for the price of a single NFT mint. Using this technology, GetGems team has already conducted several NFT giveaways via the Pearls bot. For example, the Gemmy collection is a cNFT collection. 🎲 You can see the received cNFTs in your profile on #GetGems, but in order to sell or transfer such NFTs, they need to be claimed by paying a blockchain commission. 🙏 If you filled out forms from the #TONSociety, you may have already received a Soulbound #cNFT. Such cNFTs when claimed become Soulbound NFTs (#SBT) — a type of NFT that cannot be sold or transferred. These NFTs can act as an achievement or unique award that cannot be sold. ⚡️Boost | 🌐Twitter