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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #197 · 4 јан.

Подразумеваемые неймспейсы или неявные пакеты. Этот функционал добавлен в Python 3.3 Что он означает? Ранее, до 3.3 пакетами считались лишь директории, в которых есть файл __init__.py. Этот файл одновременно являлся свидетельством того, что директория это Python-пакет, и служил "телом" этого пакета. То есть местом, где можно написать код, как это делается внутри модуля. Этот код исполняется в момент импорта пакета, так что его принято называть "код инициализации пакета". Начиная с версии 3.3 Любая директория считается пакетом и Python будет пытаться использовать любую директорию для импорта. Конечно, не любую в файловой системе, а только те что находятся в sys.path. Это значит, что теперь __init__.py нужно делать только если: 🔸 вам требуется создать код инициализации пакета 🔸 нужна совместимость со старыми версиями Python На мой взгляд это немного упрощает разработку, делает её чище, но с другой стороны убивает некоторую однозначность происходящего. Например, я создал репозиторий со своей библиотекой и рядом положил код примеров или тестов. repo_name/ my_library/ __init__.py main.py examples/ exam1.py exam2.py В этом репозитории пакетом является только my_library, остальные директории это не пакеты, это просто дополнительный код в файлах. Директория examples не добавлена в sys.path, в ней нет рабочих модулей. Но если она лежит рядом с my_library, то Python вполне сможет импортнуть из неё модули, так как посчитает что examples это валидный пакет. Конечно, пример несколько надуманный. Никто не будет добавлять корень репозитория в sys.path. Но, я думаю, суть ясна. Иногда директория это просто директория а не пакет! #basic#pep

Hashtags

Резултати

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

Пребарај: #ether

当前筛选 #ether清除筛选
SIGNAL

@finsignal · Post #3127 · 23.05.2024 г., 06:55

Good morning, everyone! 🌄 🤔 The cue ball froze around 69.500, but the #Ether, despite the sideways bitcoin, is trying to grow and is trading around 3800. I think that they will try to get through the Air today or tomorrow to the 3.850-3.870 area. But then everything will depend on #Bitcoin: if the cue ball supports the market with growth, then the #Ether will be able to go above $ 4,000. 😎In general, nothing has been dented on the market since yesterday and the alignment is still the same.

Venture Village Wall 🦄

@venturevillagewall · Post #4158 · 15.02.2025 г., 10:00

OM Whale Transfers Millions to Binance A significant OM whale (0x17...fe76) transferred 10.711 million OM to Binance today, valued at approximately 80.88 million USD. Previously, this whale had withdrawn OM worth around 4.82 million USD from Binance between March 1-6, 2024. This indicates a potential profit nearing 84 million USD for the whale. More Details #OM#Binance#Crypto#Whale#Investment#Market#Profit#Trading#Blockchain#Ether

Crypto M - Crypto News

@CryptoM · Post #64763 · 09.04.2026 г., 20:15

🚀 Ether Rises Over 6% as Undervaluation Signals Potential Retest of Higher Levels Ether experienced a 6.33% increase, surpassing $2,150, with indicators suggesting a potential retest of the $2,400–$2,500 range. According to NS3.AI, the Capriole Macro Index Oscillator registered a reading of -2.42, indicating that Ether is in a rare undervaluation zone. This development has sparked interest among investors, who are closely monitoring the cryptocurrency for further movements. #Ether#Crypto#Ethereum#Undervaluation#PriceIncrease#Investment#CryptoTrading#NS3AI#ETH

Crypto M - Crypto News

@CryptoM · Post #65226 · 12.04.2026 г., 05:55

🚀 Bitcoin and Ether Prices Could Signal Sustainable Growth, Says Analyst Macro analyst Jordi Visser has suggested that Bitcoin surpassing $76,000 and Ether exceeding $2,400 might indicate the beginning of a sustainable upward trend this year. According to NS3.AI, Visser expressed confidence in the market's resilience, noting that he does not foresee a recession. Additionally, data from the United States Bureau of Labor Statistics revealed that the Consumer Price Index (CPI) for April increased by 3.3% compared to the previous year. #Bitcoin#Ether#Cryptocurrency#MarketAnalysis#SustainableGrowth#MacroEconomics#CPI#Inflation#BTC#ETH