mammoth-cli 2.2.8__tar.gz → 2.2.9__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/PKG-INFO +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/__init__.py +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/app.py +6 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/dashboard.md +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/dataset.md +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/project.md +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/workflow.md +4 -4
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/workspace.md +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/activity.py +8 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/calc.py +37 -10
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/client_app.py +3 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/dataset.py +33 -11
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/doctor.py +2 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/folder.py +1 -6
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/project.py +6 -7
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/schema.py +3 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/view.py +92 -13
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/view_ops.py +16 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/view_profile.py +7 -6
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/workflow.py +16 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/workspace.py +7 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/embed.py +56 -25
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/errors/envelope.py +1 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/normalize.py +51 -31
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/dryrun.py +33 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/embedded.py +15 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/executor.py +26 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/input_loader.py +16 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/intent_only.py +2 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/parents.py +24 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/runlog.py +5 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/dashboard_review.py +4 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/data_profile.py +2 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/data_quality.py +12 -6
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/input_fields.py +8 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/listing.py +4 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/mapping.py +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/sdk_service.py +56 -19
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/text_dates.py +4 -4
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/pyproject.toml +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/dashboard.yaml +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/dataset.yaml +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/project.yaml +1 -1
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/workflow.yaml +3 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/workspace.yaml +3 -3
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/sdk-catalog.source.yaml +4 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/sdk-methods.yaml +2 -2
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/.gitignore +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/LICENSE +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/README.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/__main__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/SKILL.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/about-mammoth.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/auth.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/capabilities-misc.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/capabilities.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/command-index.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/activity.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/addon.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/agent.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/ai.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/annotation.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/auth.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/automation.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/batch.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/billing.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/browse.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/calc.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/capability.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/client-app.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/completion.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/config.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/connector.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/context.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/dashboard-qa.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/dashboard-template.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/data-app.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/doctor.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/external-key.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/file.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/folder.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/job.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/link.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/log.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/notification.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/parameter.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/report.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/schedule.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/schema.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/skill.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/snippet.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/support.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/template.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/trash.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/upgrade.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/user.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/version.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/view-transform.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/view.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/commands/webhook.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/handoff.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/input.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/jobs-drafts.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/machine-output.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/operations.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/auth-scope.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/cleanup.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/dashboards.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/database-import.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/end-to-end.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/exports.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/index.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/need-action.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/resources.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/scheduling.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/transforms.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recipes/typed-etl-discovery.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/recovery.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/report-checklist.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/retention.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/safety.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/bundled_skill/mammoth-cli/references/task-start.md +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/addon.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/agent.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/ai.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/annotation.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/auth.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/automation.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/batch.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/billing.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/browse.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/capability.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/completion.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/config.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/connector.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/context.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/dashboard.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/data_app.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/external_key.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/file.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/job.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/link.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/notification.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/parameter.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/registry.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/report.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/schedule.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/skill.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/snippet.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/support.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/template.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/trash.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/upgrade.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/user.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/commands/webhook.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/context/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/context/credentials.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/context/endpoint.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/context/profiles.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/context/resolver.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/contracts/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/contracts/auth.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/errors/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/manifest/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/manifest/loader.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/messages/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/envelope.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/policy.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/progress.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/output/render.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/py.typed +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/confirm.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/dataset_health.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/dryrun_targets.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/invocation.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/new_data.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/options.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/session.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/state.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/strict.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/updates.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/validate.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/runtime/verify.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/argspec.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/board_values.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/coerce.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/command_contract.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/conditions.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/dashboard_filters.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/dashboard_pages.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/dispatch.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/factory.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/openapi_types.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/positionals.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/protocol.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/read_queries.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/stored_stats.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/testing.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/type_system.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/services/write_impact.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/skills/__init__.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/skills/installer.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/skills/steering.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/mammoth_cli/testing.py +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/activity.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/addon.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/agent.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/ai.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/annotation.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/auth.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/automation.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/batch.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/billing.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/browse.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/calc.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/capability.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/client-app.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/completion.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/config.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/connector.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/context.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/data-app.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/doctor.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/external-key.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/file.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/folder.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/job.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/link.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/log.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/notification.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/parameter.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/report.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/schedule.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/schema.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/skill.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/snippet.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/support.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/template.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/trash.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/upgrade.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/user.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/version.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/view.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/commands/webhook.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/edits-target.source.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/openapi-operations.yaml +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/manifests/schema-v1.json +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/openapi/metadata.json +0 -0
- {mammoth_cli-2.2.8 → mammoth_cli-2.2.9}/spec/openapi/openapi.json +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mammoth-cli
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.9
|
|
4
4
|
Summary: Command-line interface for the Mammoth Analytics platform
|
|
5
5
|
Project-URL: homepage, https://mammoth.io
|
|
6
6
|
Project-URL: repository, https://github.com/EdgeMetric/mammothsdk
|
|
@@ -17,7 +17,7 @@ Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
|
17
17
|
Requires-Python: <3.15,>=3.12
|
|
18
18
|
Requires-Dist: jsonschema>=4.20
|
|
19
19
|
Requires-Dist: keyring<26,>=25.7
|
|
20
|
-
Requires-Dist: mammoth-io<0.9,>=0.8.
|
|
20
|
+
Requires-Dist: mammoth-io<0.9,>=0.8.10
|
|
21
21
|
Requires-Dist: platformdirs<5,>=4.10
|
|
22
22
|
Requires-Dist: pydantic<3,>=2.12.5
|
|
23
23
|
Requires-Dist: pyyaml<7,>=6
|
|
@@ -457,6 +457,12 @@ class _EnvelopeGroup(TyperGroup):
|
|
|
457
457
|
# classify an argv flag that is not a known global option;
|
|
458
458
|
# a known option's malformed value remains usage_error.
|
|
459
459
|
known, _valued = _global_option_flags()
|
|
460
|
+
command = getattr(getattr(error, "ctx", None), "command", None)
|
|
461
|
+
known = known | {
|
|
462
|
+
flag
|
|
463
|
+
for param in getattr(command, "params", [])
|
|
464
|
+
for flag in (*param.opts, *param.secondary_opts)
|
|
465
|
+
}
|
|
460
466
|
option = next(
|
|
461
467
|
(
|
|
462
468
|
token.split("=", 1)[0]
|
|
@@ -386,7 +386,7 @@ Status on release: untried; no live run recorded.
|
|
|
386
386
|
|
|
387
387
|
Run: `mammoth dashboard format-preview`. Exact input fields: `mammoth schema get dashboard.format-preview`.
|
|
388
388
|
|
|
389
|
-
Example: `mammoth dashboard format-preview 123 --input '{"style": "
|
|
389
|
+
Example: `mammoth dashboard format-preview 123 --input '{"style": "presentation"}'`. Placeholders are illustrative; resolve IDs and input from observed reads.
|
|
390
390
|
|
|
391
391
|
Result: `DashboardFormatPreviewResult`; mutation `read`, confirmation `none`, wait policy `not_async`.
|
|
392
392
|
|
|
@@ -26,7 +26,7 @@ Status on release: untried; no live run recorded.
|
|
|
26
26
|
|
|
27
27
|
Run: `mammoth dataset broken-rows resolve`. Exact input fields: `mammoth schema get dataset.broken-rows.resolve`.
|
|
28
28
|
|
|
29
|
-
Example: `mammoth dataset broken-rows resolve 123 --input '{"op": "add", "batch_id": 1, "rows": [{"
|
|
29
|
+
Example: `mammoth dataset broken-rows resolve 123 --input '{"op": "add", "batch_id": 1, "rows": [{"line_num": 2, "line": "corrected,line,here"}]}'`. Illustrative only: append `--yes` after observing an owned target.
|
|
30
30
|
|
|
31
31
|
Result: `DatasetBrokenRowsResolveResult`; mutation `destructive`, confirmation `prompt_or_yes`, wait policy `not_async`.
|
|
32
32
|
|
|
@@ -6,9 +6,9 @@ Every command returns the standard JSON envelope. On nonzero exit, read the erro
|
|
|
6
6
|
|
|
7
7
|
Run: `mammoth project bulk-delete`. Exact input fields: `mammoth schema get project.bulk-delete`.
|
|
8
8
|
|
|
9
|
-
Example: `mammoth project bulk-delete --input '{"project_ids": [1]}'`. Illustrative only: append `--yes
|
|
9
|
+
Example: `mammoth project bulk-delete --input '{"project_ids": [1]}'`. Illustrative only: append `--yes --confirm <EXACT_TARGET>` after observing the target.
|
|
10
10
|
|
|
11
|
-
Result: `ProjectBulkDeleteResult`; mutation `destructive`, confirmation `
|
|
11
|
+
Result: `ProjectBulkDeleteResult`; mutation `destructive`, confirmation `confirm_target`, wait policy `not_async`.
|
|
12
12
|
|
|
13
13
|
Status on release: ran once on CLI 2.0.14 — write sweep 2026-09-18: exit 0 on release with CLI 2.0.14. Created throwaway project 22 (cli-write-sweep-throwaway-20260918), then bulk-deleted it. Without --yes: confirmation_required. With --yes: data:{}. Verified via project list: only project 3 (protected…
|
|
14
14
|
|
|
@@ -16,9 +16,9 @@ Status on release: untried; no live run recorded.
|
|
|
16
16
|
|
|
17
17
|
Run: `mammoth workflow block auth`. Exact input fields: `mammoth schema get workflow.block.auth`.
|
|
18
18
|
|
|
19
|
-
Example: `mammoth workflow block auth 123 123 --input '{"auth_data": {"sample_key": "Status"}}'`.
|
|
19
|
+
Example: `mammoth workflow block auth 123 123 --input '{"auth_data": {"sample_key": "Status"}}'`. Illustrative only: append `--yes --confirm <EXACT_TARGET>` after observing the target.
|
|
20
20
|
|
|
21
|
-
Result: `WorkflowBlockAuthResult`; mutation `benign_mutation`, confirmation `
|
|
21
|
+
Result: `WorkflowBlockAuthResult`; mutation `benign_mutation`, confirmation `confirm_target`, wait policy `not_async`.
|
|
22
22
|
|
|
23
23
|
Status on release: untried; no live run recorded.
|
|
24
24
|
|
|
@@ -56,9 +56,9 @@ Status on release: untried; no live run recorded.
|
|
|
56
56
|
|
|
57
57
|
Run: `mammoth workflow cleanup`. Exact input fields: `mammoth schema get workflow.cleanup`.
|
|
58
58
|
|
|
59
|
-
Example: `mammoth workflow cleanup`.
|
|
59
|
+
Example: `mammoth workflow cleanup`. Illustrative only: append `--yes` after observing an owned target.
|
|
60
60
|
|
|
61
|
-
Result: `WorkflowCleanupResult`; mutation `
|
|
61
|
+
Result: `WorkflowCleanupResult`; mutation `destructive`, confirmation `prompt_or_yes`, wait policy `not_async`.
|
|
62
62
|
|
|
63
63
|
Status on release: untried; no live run recorded.
|
|
64
64
|
|
|
@@ -258,8 +258,8 @@ Status on release: untried; no live run recorded.
|
|
|
258
258
|
|
|
259
259
|
Run: `mammoth workspace user update-batch`. Exact input fields: `mammoth schema get workspace.user.update-batch`.
|
|
260
260
|
|
|
261
|
-
Example: `mammoth workspace user update-batch --input '{"patches": [{"sample_key": "Status"}]}'`.
|
|
261
|
+
Example: `mammoth workspace user update-batch --input '{"patches": [{"sample_key": "Status"}]}'`. Illustrative only: append `--yes --confirm <EXACT_TARGET>` after observing the target.
|
|
262
262
|
|
|
263
|
-
Result: `WorkspaceUserUpdateBatchResult`; mutation `
|
|
263
|
+
Result: `WorkspaceUserUpdateBatchResult`; mutation `high_impact`, confirmation `confirm_target`, wait policy `not_async`.
|
|
264
264
|
|
|
265
265
|
Status on release: untried; no live run recorded.
|
|
@@ -12,6 +12,7 @@ public SDK method named by the command's reviewed manifest ``sdk_symbol``.
|
|
|
12
12
|
from __future__ import annotations
|
|
13
13
|
|
|
14
14
|
import json
|
|
15
|
+
import shlex
|
|
15
16
|
from datetime import UTC, datetime
|
|
16
17
|
from typing import Any
|
|
17
18
|
|
|
@@ -136,7 +137,9 @@ def _refuse_bare_resource_id(document: dict[str, Any]) -> None:
|
|
|
136
137
|
f" keys each resource by its type — {forms}."
|
|
137
138
|
),
|
|
138
139
|
exit_status=EXIT_USAGE,
|
|
139
|
-
recovery_commands=[
|
|
140
|
+
recovery_commands=[
|
|
141
|
+
f"mammoth activity list --input {shlex.quote(retry)}" for retry in retries
|
|
142
|
+
],
|
|
140
143
|
)
|
|
141
144
|
|
|
142
145
|
|
|
@@ -205,8 +208,10 @@ def _user_emails(service: Any) -> dict[Any, str]:
|
|
|
205
208
|
|
|
206
209
|
def _change(entry: dict[str, Any], emails: dict[Any, str]) -> dict[str, Any]:
|
|
207
210
|
"""One log entry as a line of a change list: when, who, what, on which object."""
|
|
208
|
-
|
|
209
|
-
|
|
211
|
+
raw_details = entry.get("details")
|
|
212
|
+
details: dict[str, Any] = raw_details if isinstance(raw_details, dict) else {}
|
|
213
|
+
raw_primary = entry.get("primary_object")
|
|
214
|
+
primary: dict[str, Any] = raw_primary if isinstance(raw_primary, dict) else {}
|
|
210
215
|
user_id = entry.get("user_id")
|
|
211
216
|
change = {
|
|
212
217
|
"when": _local_time(entry.get("created_at")),
|
|
@@ -18,7 +18,13 @@ from __future__ import annotations
|
|
|
18
18
|
import ast
|
|
19
19
|
import re
|
|
20
20
|
from collections.abc import Callable
|
|
21
|
-
from decimal import
|
|
21
|
+
from decimal import (
|
|
22
|
+
ROUND_HALF_UP,
|
|
23
|
+
Decimal,
|
|
24
|
+
DivisionByZero,
|
|
25
|
+
InvalidOperation,
|
|
26
|
+
localcontext,
|
|
27
|
+
)
|
|
22
28
|
from typing import Any
|
|
23
29
|
|
|
24
30
|
from mammoth_cli.errors.envelope import CODE_INVALID_ARGUMENT, EXIT_USAGE, CliError
|
|
@@ -30,6 +36,9 @@ HandlerResult = tuple[Any, dict[str, Any]]
|
|
|
30
36
|
#: valid Python expression syntax on its own.
|
|
31
37
|
_PERCENT_RE = re.compile(r"(\d+(?:\.\d+)?)\s*%")
|
|
32
38
|
|
|
39
|
+
#: Significant digits kept in a result (Python's default is 28).
|
|
40
|
+
_PRECISION = 60
|
|
41
|
+
|
|
33
42
|
_BINOPS: dict[type, Callable[[Decimal, Decimal], Decimal]] = {
|
|
34
43
|
ast.Add: lambda a, b: a + b,
|
|
35
44
|
ast.Sub: lambda a, b: a - b,
|
|
@@ -48,18 +57,26 @@ def _unsupported(expression: str) -> CliError:
|
|
|
48
57
|
)
|
|
49
58
|
|
|
50
59
|
|
|
51
|
-
def
|
|
60
|
+
def _literal(node: ast.Constant, source: str) -> Decimal:
|
|
61
|
+
"""The number as written: going through a float would round away digits past 17."""
|
|
62
|
+
try:
|
|
63
|
+
return Decimal(ast.get_source_segment(source, node) or "")
|
|
64
|
+
except InvalidOperation:
|
|
65
|
+
return Decimal(str(node.value))
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
def _evaluate(node: ast.AST, expression: str, source: str) -> Decimal:
|
|
52
69
|
if isinstance(node, ast.Expression):
|
|
53
|
-
return _evaluate(node.body, expression)
|
|
70
|
+
return _evaluate(node.body, expression, source)
|
|
54
71
|
if (
|
|
55
72
|
isinstance(node, ast.Constant)
|
|
56
73
|
and isinstance(node.value, (int, float))
|
|
57
74
|
and not isinstance(node.value, bool)
|
|
58
75
|
):
|
|
59
|
-
return
|
|
76
|
+
return _literal(node, source)
|
|
60
77
|
if isinstance(node, ast.BinOp) and type(node.op) in _BINOPS:
|
|
61
|
-
left = _evaluate(node.left, expression)
|
|
62
|
-
right = _evaluate(node.right, expression)
|
|
78
|
+
left = _evaluate(node.left, expression, source)
|
|
79
|
+
right = _evaluate(node.right, expression, source)
|
|
63
80
|
try:
|
|
64
81
|
return _BINOPS[type(node.op)](left, right)
|
|
65
82
|
except (InvalidOperation, DivisionByZero, ZeroDivisionError) as exc:
|
|
@@ -69,7 +86,7 @@ def _evaluate(node: ast.AST, expression: str) -> Decimal:
|
|
|
69
86
|
exit_status=EXIT_USAGE,
|
|
70
87
|
) from exc
|
|
71
88
|
if isinstance(node, ast.UnaryOp) and isinstance(node.op, (ast.UAdd, ast.USub)):
|
|
72
|
-
value = _evaluate(node.operand, expression)
|
|
89
|
+
value = _evaluate(node.operand, expression, source)
|
|
73
90
|
return value if isinstance(node.op, ast.UAdd) else -value
|
|
74
91
|
if (
|
|
75
92
|
isinstance(node, ast.Call)
|
|
@@ -78,7 +95,7 @@ def _evaluate(node: ast.AST, expression: str) -> Decimal:
|
|
|
78
95
|
and not node.keywords
|
|
79
96
|
and 1 <= len(node.args) <= 2
|
|
80
97
|
):
|
|
81
|
-
value = _evaluate(node.args[0], expression)
|
|
98
|
+
value = _evaluate(node.args[0], expression, source)
|
|
82
99
|
ndigits = 0
|
|
83
100
|
if len(node.args) == 2:
|
|
84
101
|
digits_node = node.args[1]
|
|
@@ -90,7 +107,14 @@ def _evaluate(node: ast.AST, expression: str) -> Decimal:
|
|
|
90
107
|
raise _unsupported(expression)
|
|
91
108
|
ndigits = digits_node.value
|
|
92
109
|
quantum = Decimal(1).scaleb(-ndigits)
|
|
93
|
-
|
|
110
|
+
try:
|
|
111
|
+
return value.quantize(quantum, rounding=ROUND_HALF_UP)
|
|
112
|
+
except InvalidOperation as exc:
|
|
113
|
+
raise CliError(
|
|
114
|
+
code=CODE_INVALID_ARGUMENT,
|
|
115
|
+
message=f"round() digits out of range in {expression!r}.",
|
|
116
|
+
exit_status=EXIT_USAGE,
|
|
117
|
+
) from exc
|
|
94
118
|
raise _unsupported(expression)
|
|
95
119
|
|
|
96
120
|
|
|
@@ -120,5 +144,8 @@ def calc(invocation: Invocation) -> HandlerResult:
|
|
|
120
144
|
hint="calc supports + - * / and parentheses, unary +/-, a trailing "
|
|
121
145
|
"'%' (divides by 100), and round(x[, ndigits]).",
|
|
122
146
|
) from exc
|
|
123
|
-
|
|
147
|
+
source = normalized
|
|
148
|
+
with localcontext() as context:
|
|
149
|
+
context.prec = _PRECISION
|
|
150
|
+
result = _evaluate(tree, expression, source)
|
|
124
151
|
return {"expression": expression, "result": str(result)}, {}
|
|
@@ -27,6 +27,7 @@ from mammoth_cli.errors.envelope import (
|
|
|
27
27
|
CliError,
|
|
28
28
|
)
|
|
29
29
|
from mammoth_cli.manifest.loader import command_by_id
|
|
30
|
+
from mammoth_cli.output.normalize import Revealed, normalize
|
|
30
31
|
from mammoth_cli.runtime.confirm import (
|
|
31
32
|
POLICY_CONFIRM_TARGET,
|
|
32
33
|
POLICY_PROMPT_OR_YES,
|
|
@@ -210,6 +211,8 @@ def client_app_create(invocation: Invocation) -> HandlerResult:
|
|
|
210
211
|
_forward_optional(document, kwargs, ("description",))
|
|
211
212
|
with open_service(invocation) as (service, auth):
|
|
212
213
|
data = service.call(_symbol(invocation), **kwargs)
|
|
214
|
+
# The API shows the new app's token once; masking it would lose it for good.
|
|
215
|
+
data = Revealed(normalize(data, redact_secrets=False))
|
|
213
216
|
return data, _meta(invocation, auth.workspace_id, resolved_project(invocation))
|
|
214
217
|
|
|
215
218
|
|
|
@@ -149,19 +149,38 @@ def _visible_projects(service: Any) -> list[dict[str, Any]]:
|
|
|
149
149
|
|
|
150
150
|
|
|
151
151
|
def _find_in_projects(
|
|
152
|
-
service: Any,
|
|
152
|
+
service: Any,
|
|
153
|
+
needle: str,
|
|
154
|
+
projects: list[dict[str, Any]],
|
|
155
|
+
skipped: list[dict[str, Any]] | None = None,
|
|
153
156
|
) -> list[dict[str, Any]]:
|
|
154
|
-
"""Datasets whose name contains ``needle`` (case-insensitive), in each of ``projects``.
|
|
157
|
+
"""Datasets whose name contains ``needle`` (case-insensitive), in each of ``projects``.
|
|
158
|
+
|
|
159
|
+
A project that cannot be read does not end the search: with ``skipped`` it is
|
|
160
|
+
recorded there (id, name, why) and the rest are still searched.
|
|
161
|
+
"""
|
|
155
162
|
matches: list[dict[str, Any]] = []
|
|
156
163
|
for project in projects:
|
|
157
164
|
project_id = project.get("id")
|
|
158
165
|
if project_id is None:
|
|
159
166
|
continue
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
167
|
+
try:
|
|
168
|
+
response = service.call(
|
|
169
|
+
"mammoth.api.datasets.DatasetsAPI.list_all",
|
|
170
|
+
project_id=project_id,
|
|
171
|
+
fields=DATASET_ROW_FIELDS,
|
|
172
|
+
)
|
|
173
|
+
except CliError as error:
|
|
174
|
+
if skipped is None:
|
|
175
|
+
raise
|
|
176
|
+
skipped.append(
|
|
177
|
+
{
|
|
178
|
+
"project_id": project_id,
|
|
179
|
+
"project_name": project.get("name"),
|
|
180
|
+
"error": error.message,
|
|
181
|
+
}
|
|
182
|
+
)
|
|
183
|
+
continue
|
|
165
184
|
datasets = response.get("datasets", []) if isinstance(response, dict) else []
|
|
166
185
|
for dataset in datasets:
|
|
167
186
|
name = dataset.get("name") if isinstance(dataset, dict) else None
|
|
@@ -210,18 +229,19 @@ def dataset_find(invocation: Invocation) -> HandlerResult:
|
|
|
210
229
|
"""
|
|
211
230
|
name_substring = _require_string_positional(invocation, "name substring")
|
|
212
231
|
needle = name_substring.lower()
|
|
232
|
+
skipped: list[dict[str, Any]] = []
|
|
213
233
|
with open_service(invocation) as (service, auth):
|
|
214
234
|
visible = _visible_projects(service)
|
|
215
235
|
if invocation.project is not None:
|
|
216
236
|
projects: list[dict[str, Any]] = [named_project(service, invocation.project, visible)]
|
|
217
|
-
matches = _find_in_projects(service, needle, projects)
|
|
237
|
+
matches = _find_in_projects(service, needle, projects, skipped)
|
|
218
238
|
if not matches:
|
|
219
239
|
others = _other_projects(visible, invocation.project)
|
|
220
|
-
matches = _find_in_projects(service, needle, others)
|
|
240
|
+
matches = _find_in_projects(service, needle, others, skipped)
|
|
221
241
|
projects += others
|
|
222
242
|
else:
|
|
223
243
|
projects = visible
|
|
224
|
-
matches = _find_in_projects(service, needle, projects)
|
|
244
|
+
matches = _find_in_projects(service, needle, projects, skipped)
|
|
225
245
|
meta = {
|
|
226
246
|
"profile": invocation.profile,
|
|
227
247
|
"workspace_id": auth.workspace_id,
|
|
@@ -229,8 +249,10 @@ def dataset_find(invocation: Invocation) -> HandlerResult:
|
|
|
229
249
|
}
|
|
230
250
|
result: dict[str, Any] = {
|
|
231
251
|
"matches": matches,
|
|
232
|
-
"projects_searched": len(projects),
|
|
252
|
+
"projects_searched": len(projects) - len(skipped),
|
|
233
253
|
}
|
|
254
|
+
if skipped:
|
|
255
|
+
result["projects_skipped"] = skipped
|
|
234
256
|
if note := ambiguity_note(len(matches), name_substring):
|
|
235
257
|
result["note"] = note
|
|
236
258
|
return result, meta
|
|
@@ -133,9 +133,8 @@ _PROJECT_LIMIT = 20
|
|
|
133
133
|
|
|
134
134
|
def _visible_projects(service: Any) -> list[dict[str, Any]]:
|
|
135
135
|
"""Return the projects this credential can list, or an empty list."""
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
return [p for p in projects if isinstance(p, dict)]
|
|
136
|
+
# Every page: "is the selected project visible" must not stop at the first few.
|
|
137
|
+
return [p for p in service.list_all_projects() if isinstance(p, dict)]
|
|
139
138
|
|
|
140
139
|
|
|
141
140
|
def _nearest_existing(path: Path) -> Path:
|
|
@@ -126,12 +126,7 @@ def folder_find(invocation: Invocation) -> HandlerResult:
|
|
|
126
126
|
if project_id is None:
|
|
127
127
|
continue
|
|
128
128
|
project_name = project.get("name")
|
|
129
|
-
|
|
130
|
-
# the maximum so a project's folders are not silently truncated.
|
|
131
|
-
response = service.call(
|
|
132
|
-
"mammoth.api.folders.FoldersAPI.list", project_id=project_id, limit=100
|
|
133
|
-
)
|
|
134
|
-
for folder in _folders_of(response):
|
|
129
|
+
for folder in _project_folders(service, project_id):
|
|
135
130
|
name = folder.get("name") if isinstance(folder, dict) else None
|
|
136
131
|
if isinstance(name, str) and needle in name.lower():
|
|
137
132
|
matches.append(
|
|
@@ -31,7 +31,6 @@ from mammoth_cli.manifest.loader import command_by_id
|
|
|
31
31
|
from mammoth_cli.runtime import embedded
|
|
32
32
|
from mammoth_cli.runtime.confirm import (
|
|
33
33
|
POLICY_CONFIRM_TARGET,
|
|
34
|
-
POLICY_PROMPT_OR_YES,
|
|
35
34
|
POLICY_YES_ALWAYS,
|
|
36
35
|
enforce_confirmation,
|
|
37
36
|
)
|
|
@@ -401,8 +400,9 @@ def project_bulk_delete(invocation: Invocation) -> HandlerResult:
|
|
|
401
400
|
project_ids = _require_input_field(document, "project_ids")
|
|
402
401
|
enforce_confirmation(
|
|
403
402
|
invocation,
|
|
404
|
-
policy=
|
|
403
|
+
policy=POLICY_CONFIRM_TARGET,
|
|
405
404
|
action=f"delete {len(project_ids)} projects",
|
|
405
|
+
target=",".join(str(project_id) for project_id in sorted(set(project_ids))),
|
|
406
406
|
)
|
|
407
407
|
with open_service(invocation) as (service, auth):
|
|
408
408
|
data = service.call(_symbol(invocation), project_ids=project_ids)
|
|
@@ -632,11 +632,10 @@ def _map_checks[T](
|
|
|
632
632
|
if len(items) <= 1:
|
|
633
633
|
return [work(service, auth, item) for item in items]
|
|
634
634
|
with ThreadPoolExecutor(max_workers=min(_CHECK_WORKERS, len(items))) as pool:
|
|
635
|
-
return
|
|
636
|
-
pool
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
)
|
|
635
|
+
return embedded.pool_map(
|
|
636
|
+
pool,
|
|
637
|
+
lambda item: _in_worker(invocation, lambda svc, ath: work(svc, ath, item)),
|
|
638
|
+
items,
|
|
640
639
|
)
|
|
641
640
|
|
|
642
641
|
|
|
@@ -1645,8 +1645,9 @@ def schema_index(family: str | None = None) -> dict[str, Any]:
|
|
|
1645
1645
|
``schema get`` for the command it picked.
|
|
1646
1646
|
"""
|
|
1647
1647
|
entries = schema_entries()
|
|
1648
|
-
|
|
1649
|
-
|
|
1648
|
+
words = (family or "").strip().split(".")[0].split()
|
|
1649
|
+
if words:
|
|
1650
|
+
wanted = words[0]
|
|
1650
1651
|
commands = [
|
|
1651
1652
|
{
|
|
1652
1653
|
"command_id": entry["command_id"],
|