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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #60 · 31 мар.

Вторая по частоте future-функция, которую я использовал, это абсолютный импорт from __future__ import absolute_import Что она делает? Изменения, которые вносит эта инъекция описаны в PEP328 Покажу простой пример. Допустим, есть такой пакет: /my_package /__init__.py /main.py /string.py Смотрим код в my_package/main.py # main.py import string Простой пример готов) Вопрос в том, какой модуль импортируется в данном случае? Есть два варианта: 1. модуль в моём пакете my_package.string 2. стандартный модуль string И вот тут вступает в дело приоритет импортов. В Python2 порядок следующий: помимо иных источников, раньше ищется модуль внутри текущего пакета, а потом в стандартных библиотеках. Таким образом мы импортнём my_package.string. Но в Python3 это поведение изменилось. Если мы указываем просто имя пакета, то ищется именно такой модуль, игнорируя имена в текущем пакете. Если мы хотим импортнуть именно подмодуль из нашего пакета то, мы должны теперь явно это указывать. from my_package import string или относительный импорт, но с указанием пути относительно текущего модуля main from . import string Еще одной неоднозначностью меньше 😎 Подробней про импорты здесь: https://docs.python.org/3/tutorial/modules.html #2to3#pep#basic

Резултати

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

Пребарај: #usfinance

当前筛选 #usfinance清除筛选
Venture Village Wall 🦄

@venturevillagewall · Post #3964 · 23.01.2025 г., 22:00

Trump Launches National Crypto Strategy 🚨 President Trump has signed an executive order to establish a Presidential Working Group on Digital Asset Markets. This group will push for a robust regulatory framework for cryptocurrencies and stablecoins, and explore the creation of a National Digital Asset Stockpile using seized digital assets. Chaired by crypto advocate David Sacks, the group aims to strengthen U.S. leadership in digital finance and replace previous regulations seen as obstacles to innovation. Full details: Leviathan News #Trump#Crypto#DigitalAssets#Bitcoin#Stablecoins#NationalReserve#USFinance#Blockchain#Innovation#CryptoWorkingGroup

Crypto M - Crypto News

@CryptoM · Post #64737 · 09.04.2026 г., 16:54

🚀 U.S. March Budget Deficit Estimated at $163 Billion The U.S. Congressional Budget Office (CBO) has announced that the budget deficit for March is projected to reach $163 billion. According to BlockBeats, this estimate reflects ongoing fiscal challenges faced by the United States. The CBO's report highlights the financial pressures impacting the federal budget, as expenditures continue to outpace revenues. This development underscores the importance of addressing the nation's fiscal policies to manage the growing deficit effectively. #USBudget#BudgetDeficit#FiscalPolicy#CBO#USFinance#FederalBudget#Economy#MarchDeficit#FinancialReport#USGovernment

Crypto M - Crypto News

@CryptoM · Post #65191 · 11.04.2026 г., 18:19

🚀 U.S. Public Debt Increases by $571.28 Billion, Reaching $38.969 Trillion The United States public debt has increased by approximately $571.28 billion this year, reaching a total of $38.969 trillion as of April 7, 2026. According to NS3.AI, this figure encompasses both debt held by the public and intragovernmental holdings. In an interview with NPR, JPMorgan Chase CEO Jamie Dimon expressed concerns that the growing debt burden could pose challenges, potentially leading to higher market rates and reduced demand for U.S. Treasurys. #USDebt#PublicDebt#USFinance#GovernmentDebt#EconomicNews#USMarkets#Treasury#DebtCrisis#JPMorgan#Macroeconomics

Venture Village Wall 🦄

@venturevillagewall · Post #4357 · 10.03.2025 г., 22:00

Crypto News: Market Decline and Developments 🇺🇸 Sunnyvale Public Safety Officers Association becomes the first U.S. dual-agency to hold Bitcoin on its balance sheet. Joseph Lubin praises U.S. government's reforms, anticipating crypto growth by 2025. President Trump's upcoming executive order may adjust Fed policies for crypto banks and clarify that stablecoins are not securities. FIFA considering a new cryptocurrency, FIFA Coin, to engage 5 billion fans. Coinbase to hire 1,000 workers, citing Trump's positive impact on the crypto industry. Ethereum sees significant outflows totaling $1.8 billion, while total value locked in DeFi drops to $88 million. Bitcoin's price fluctuates between extreme greed and fear, with a current value of $79,000. Ethereum declines below $2000, triggering market fears as total market cap falls by 33%. Current index shows extreme fear since 2022, affecting trader sentiments. #Bitcoin#Crypto#DeFi#TrumpsExecutiveOrder#FIFA#Ethereum#Coinbase#Stablecoins#MarketSentiment#Bullish#Blockchain#Investors#CryptoRegulation#ETH#USFinance#DigitalAssets#CryptoOutflows#FinanceNews