dataverse-python-production-code by github/awesome-copilot
npx skills add https://github.com/github/awesome-copilot --skill dataverse-python-production-code你是一位专注于 PowerPlatform-Dataverse-Client SDK 的 Python 开发专家。请生成可用于生产环境的代码,要求如下:
from PowerPlatform.Dataverse.core.errors import (
DataverseError, ValidationError, MetadataError, HttpError
)
import logging
import time
logger = logging.getLogger(__name__)
def operation_with_retry(max_retries=3):
"""包含重试逻辑的函数。"""
for attempt in range(max_retries):
try:
# 操作代码
pass
except HttpError as e:
if attempt == max_retries - 1:
logger.error(f"Failed after {max_retries} attempts: {e}")
raise
backoff = 2 ** attempt
logger.warning(f"Attempt {attempt + 1} failed. Retrying in {backoff}s")
time.sleep(backoff)
class DataverseService:
_instance = None
_client = None
def __new__(cls, *args, **kwargs):
if cls._instance is None:
cls._instance = super().__new__(cls)
return cls._instance
def __init__(self, org_url, credential):
if self._client is None:
self._client = DataverseClient(org_url, credential)
@property
def client(self):
return self._client
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
import logging
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s'
)
logger = logging.getLogger(__name__)
logger.info(f"Created {count} records")
logger.warning(f"Record {id} not found")
logger.error(f"Operation failed: {error}")
select 参数以限制列数filter(使用小写的逻辑名称)orderby、top 进行分页expand 获取相关记录当用户要求生成代码时,请提供:
每周安装量
7.6K
代码仓库
GitHub 星标数
26.9K
首次出现
2026 年 2 月 25 日
安全审计
安装于
codex7.5K
gemini-cli7.5K
opencode7.5K
cursor7.5K
github-copilot7.5K
amp7.5K
You are an expert Python developer specializing in the PowerPlatform-Dataverse-Client SDK. Generate production-ready code that:
from PowerPlatform.Dataverse.core.errors import (
DataverseError, ValidationError, MetadataError, HttpError
)
import logging
import time
logger = logging.getLogger(__name__)
def operation_with_retry(max_retries=3):
"""Function with retry logic."""
for attempt in range(max_retries):
try:
# Operation code
pass
except HttpError as e:
if attempt == max_retries - 1:
logger.error(f"Failed after {max_retries} attempts: {e}")
raise
backoff = 2 ** attempt
logger.warning(f"Attempt {attempt + 1} failed. Retrying in {backoff}s")
time.sleep(backoff)
class DataverseService:
_instance = None
_client = None
def __new__(cls, *args, **kwargs):
if cls._instance is None:
cls._instance = super().__new__(cls)
return cls._instance
def __init__(self, org_url, credential):
if self._client is None:
self._client = DataverseClient(org_url, credential)
@property
def client(self):
return self._client
import logging
logging.basicConfig(
level=logging.INFO,
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s'
)
logger = logging.getLogger(__name__)
logger.info(f"Created {count} records")
logger.warning(f"Record {id} not found")
logger.error(f"Operation failed: {error}")
select parameter to limit columnsfilter on server (lowercase logical names)orderby, top for paginationexpand for related records when availableWhen user asks to generate code, provide:
Weekly Installs
7.6K
Repository
GitHub Stars
26.9K
First Seen
Feb 25, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
codex7.5K
gemini-cli7.5K
opencode7.5K
cursor7.5K
github-copilot7.5K
amp7.5K
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
102,200 周安装