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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #303 · 27 дек.

Наверняка вы замечали, что в Python есть удобная функция для получения переменной окружения os.getenv(NAME) И её "сестра" для создания или изменения переменных окружения os.putenv(NAME, VALUE) Но почему-то putenv() не работает как должно. Энвайромент не обновляется! os.putenv('MYVAR', '1') print(os.getenv('MYVAR')) ... и ничего 😴 Почему так? На самом деле энвайромент обновляется, но это значение не добавляется в словарь os.environ. Откройте исходник функции os.getenv(). Это просто шорткат для os.environ.get() В то время как putenv() это built-in С-функция. Словарь os.environ (или точней класс из MutableMapping) создаётся из энвайромента в момент инициализации. Функция putenv() самостоятельно его не изменяет. В тоже время, когда вы создаёте или изменяете ключ в os.environ, автоматически вызывается putenv() в методе __setitem__(). То есть, технически putenv() всё делает верно, но в os.environ это не отражается. Можно проверить так: >>> os.putenv('MYVAR', '123') >>> os.system('python -c "import os;print(os.getenv(\'MYVAR\'))"') 123 Я объявил переменную в текущем процессе и вызвал дочерний процесс, который её унаследовал и получил в составе os.environ. Аналогично при удалении переменной вызывается еще одна built-in функция unsetenv(), удаляющая переменную из системы. Итого ▫️ Удобней всего явно обновлять переменные через os.environ ▫️ Есть способ неявно создать/удалить переменную через putenv/unsetenv, что не повлияет на os.environ но изменит энвайромент и передаст изменения сабпроцессам. Но так лучше не делать! ▫️os.environ это просто обертка для built-in функций putenv() и unsetenv(). #basic

Hashtags

Резултати

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

Пребарај: #cryptocurrency

当前筛选 #cryptocurrency清除筛选
The Hacker News

@thehackernews · Post #8826 · 18.04.2026 г., 08:00

Sanctioned #cryptocurrency exchange Grinex is shutting down after a $13.74M hack. Stolen funds were quickly moved and swapped to avoid freezing. The platform is linked to Garantex, flagged for laundering over $100M. 🔗 Read → https://thehackernews.com/2026/04/1374m-hack-shuts-down-sanctioned-grinex.html

🦅 [ perspective ix ]

@perspectiveix · Post #1281 · 20.05.2018 г., 19:30

​​💰With at least $1.3 billion invested globally in 2018, VC funding for blockchain blows past 2017 totals 🚀@PerspectiveIX Read more at t.me/iXNews/25659 Do you own any #CryptoCurrency? 👍🏻 Yes 😅 No, but I'm thinking of buying 👎🏻 No, not interested at all

DWF Labs Broadcast

@Dwflabs · Post #183 · 27.01.2023 г., 03:05

Fans of the TON #cryptocurrency now have a new way to trade their favorite altcoin following its addition to the options trading markets on the popular exchange platforms BIT and Paradigm. The options are live on the platform today and will be available on the institution-focused liquidity network Paradigm later, the exchange said in a statement shared with CoinDesk. The options are launched in collaboration with liquidity provider Darley Technologies and blockchain industry market maker and TON-backer DWF Labs. "Joining the options market is a logical and important step for TON because, until now, the only coins available there were BTC and ETH. It means TON will take its place alongside crypto's most prestigious coins," said Andrei Grachev, Managing Partner at DWF Labs. Full read here: https://lnkd.in/g6zACNN7

🗺 Travel the World | Private Expeditions

@expeditionsworldwide · Post #52 · 12.08.2020 г., 04:30

📊Intermediate statistics for the experimental portfolio: Days elapsed since launch: 20; Purchased 18 coins: #BTC #XRP #REP #EOS #NEO #STRAT #BSTX #OGN #ETC #ICX #LTC #CELR #QTUM #DASH #BEAM #LTO; Already Invested (since launch): $200 Total profit (since launch): 7.02% 📊Detailed portfolio statistics - https://bit.ly/30GlvN2 ➕FIBONACCI $10 Experiment (#cryptocurrency)

Trump's Ear

@trumpsear_tg · Post #1448 · 02.09.2025 г., 13:59

Trump earned more in cryptocurrency in a day than in real estate in his entire life - The Wall Street Journal On September 1, the WLFI token, another cryptocurrency issued by the Trump family, began trading on exchanges. The price of the token on the first day of trading fell by more than a third from its peak value, but despite this, the Trump fortune increased by more than $5 billion per day. This is much more than the value of all the real estate owned by Trump. #Trump#cryptocurrency 👂More on Trump's Ear ⚠️

TONlines – News

@tonlines · Post #7324 · 22.05.2025 г., 11:25

⚡️TON Community: Join the Ultimate TON NFT Gathering in Lisbon #TON#cryptocurrency TON Community announces an exclusive one-day event, TON of People, in Lisbon on June 5, 2025. The event will feature key figures from the TON blockchain and cryptocurrency communities, providing insights into NFTs and blockchain marketing. Attendees will also have access to additional events during the NFC Summit. Source: link @tonlines

TONlines – News

@tonlines · Post #6753 · 14.04.2025 г., 12:08

⚡️xRocket News: Real-Time Crypto Rates and Referral System #Telegram#cryptocurrency xRocket News introduces a new @xrocket dash command in Telegram that provides instant cryptocurrency rates and changes within chats. Users can also benefit from a built-in referral system by typing @xrocket dash followed by desired tokens. The rates automatically update every 30 minutes in larger groups or channels. Source: link @tonlines

DWF Labs Broadcast

@Dwflabs · Post #167 · 20.01.2023 г., 07:40

BIT x DWF Labs Crypto Snapshot [13 Jan] 📰 Highlights: 🔸Shanghai Upgrade Well On Track With Latest Testnet Developments 🔸#Bitcoin Rebounds From Its Lows Back To $21,000 🔸Innovation And Sound Practices Are Key For #Cryptocurrency Integration Full read here.

TONlines – News

@tonlines · Post #7055 · 05.05.2025 г., 16:22

Trending Apps: Discover TonTradingBot for Seamless Crypto Management #Cryptocurrency#Web3 Trending Apps highlights TonTradingBot, a comprehensive solution for crypto enthusiasts to manage trading operations directly within the chat. It offers features such as sniper mode, limit orders, and copy-trading, along with tools like Fast Swap and Honeypot Detection, promising secure and fast performance. Source: link @tonlines

123•••10•••20•••30•••40•••4344
ПретходнаСтраница 1 од 44Следна