Conversation
… and Site modules - Implement tests for OutOfOfficePeriod including initialization, data handling, CRUD operations, and filtering. - Create tests for Product covering initialization, data handling, CRUD operations, enabling/disabling, and related entities. - Add comprehensive tests for various referenced types including Service, Calendar, TimeAllocation, EffortClass, RequestTemplate, UiExtension, and WorkflowTemplate. - Develop tests for ShopArticleCategory, ShopArticle, ShopOrderLine including initialization, data handling, CRUD operations, and filtering. - Introduce tests for Site module covering initialization, data handling, CRUD operations, enabling/disabling, and archiving.
…jects, contracts, knowledge_articles, risks, service_offerings, skill_pools, closure_codes Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
- Requests: get_attachments, get_knowledge_articles, get_automation_rules, get_satisfaction_feedback, get_tags, get_watches - Tasks: get_notes, add_note, get_approvals, get_cis, get_predecessors, get_successors, get_service_instances, get_automation_rules - Workflows: get_notes, add_note, get_automation_rules, get_phases, get_requests, get_problems - People: get_cis, get_addresses, get_contacts, get_permissions, get_ci_coverages, get_sla_coverages, get_service_coverages, get_out_of_office_periods, get_skill_pools - Organizations: get_addresses, get_contacts, get_contracts, get_risks, get_slas, get_time_allocations - Services: get_workflows, get_request_templates, get_risks, get_service_instances, get_slas, get_service_offerings - Calendars: get_duration, get_hours, get_holidays - Teams: get_service_instances - Holidays: get_calendars Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
…exports - Add search(), bulk_import(), list_archive(), list_trash(), list_audit_lines() methods to XurrentApiHelper - Populate __init__.py with exports for all domain classes across all modules Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
…methods - test_problems.py: Problem CRUD, notes, requests, workflows - test_service_instances.py: ServiceInstance CRUD, CIs, users - test_releases.py: Release CRUD, archive/trash/restore, workflows, notes - test_projects.py: Project CRUD, archive/trash/restore, tasks/phases/workflows/notes - test_contracts.py: Contract CRUD, CIs - test_knowledge_articles.py: KnowledgeArticle CRUD, archive/trash/restore, requests/service_instances/translations - test_risks.py: Risk CRUD, archive/trash/restore, organizations/projects/services - test_service_offerings.py: ServiceOffering CRUD - test_skill_pools.py: SkillPool CRUD, enable/disable, members/effort_classes - test_closure_codes.py: ClosureCode CRUD - test_new_sub_resources.py: new sub-resource methods on Request, Task, Workflow, Person, Organization, Service, Calendar, Holiday, Team; core search/bulk_import/ list_archive/list_trash/list_audit_lines utilities Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
…01 unit tests Agent-Logs-Url: https://github.com/fasteiner/xurrent-python/sessions/7ce5e825-70b8-4b09-ad7e-99899ceede7d Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
Add missing domain classes, sub-resource methods, and utility APIs to close gap vs Xurrent REST API v1
|
@copilot please fix by implementing lazy loading (like shown in various examples in the code on co dependant classes): Run # Stop the build on syntax errors or undefined names |
There was a problem hiding this comment.
Pull request overview
This PR significantly expands the Xurrent Python client by adding many new resource/domain modules (and sub-resource helper methods), alongside a broad set of unit tests and CI/release pipeline updates to support the expanded surface area.
Changes:
- Added many new domain classes (e.g., Projects, Releases, Risks, ServiceInstances, Shop* resources, etc.) plus additional sub-resource convenience methods across existing models.
- Added extensive unit test coverage for the new domain modules and sub-resource methods.
- Updated packaging/metadata, documentation, changelog, and GitHub Actions workflows (tests + release automation).
Reviewed changes
Copilot reviewed 61 out of 62 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/unit_tests/test_skill_pools.py | Adds unit tests for SkillPool CRUD and sub-resources. |
| tests/unit_tests/test_sites.py | Adds unit tests for Site CRUD and lifecycle methods. |
| tests/unit_tests/test_shop.py | Adds unit tests for shop article/category/order-line resources and enums. |
| tests/unit_tests/test_service_offerings.py | Adds unit tests for ServiceOffering CRUD/filtering. |
| tests/unit_tests/test_service_instances.py | Adds unit tests for ServiceInstance CRUD and sub-resources. |
| tests/unit_tests/test_risks.py | Adds unit tests for Risk CRUD/lifecycle and sub-resources. |
| tests/unit_tests/test_releases.py | Adds unit tests for Release CRUD/lifecycle and notes. |
| tests/unit_tests/test_referenced_types.py | Adds tests covering multiple referenced-type deserializations. |
| tests/unit_tests/test_projects.py | Adds unit tests for Project CRUD/lifecycle and sub-resources. |
| tests/unit_tests/test_products.py | Adds unit tests for Product CRUD/lifecycle and CI listing. |
| tests/unit_tests/test_problems.py | Adds unit tests for Problem CRUD/lifecycle and sub-resources. |
| tests/unit_tests/test_out_of_office_periods.py | Adds unit tests for OutOfOfficePeriod CRUD/DELETE. |
| tests/unit_tests/test_organizations.py | Adds unit tests for Organization CRUD/lifecycle and sub-resources. |
| tests/unit_tests/test_knowledge_articles.py | Adds unit tests for KnowledgeArticle CRUD/lifecycle and sub-resources. |
| tests/unit_tests/test_holidays.py | Adds unit tests for Holiday CRUD and filtering. |
| tests/unit_tests/test_custom_collections.py | Adds unit tests for custom collections/elements and listing. |
| tests/unit_tests/test_contracts.py | Adds unit tests for Contract CRUD/filtering and CI listing. |
| tests/unit_tests/test_closure_codes.py | Adds unit tests for ClosureCode CRUD. |
| src/xurrent/workflows.py | Adds workflow sub-resource helpers (notes, automation rules, phases, related items). |
| src/xurrent/workflow_templates.py | Introduces WorkflowTemplate resource model and filters/enums. |
| src/xurrent/ui_extensions.py | Introduces UiExtension resource model and category enum. |
| src/xurrent/time_allocations.py | Introduces TimeAllocation resource model and category enums. |
| src/xurrent/teams.py | Adds Team.get_service_instances(). |
| src/xurrent/tasks.py | Adds task sub-resource helpers (notes, approvals, CIs, links, automation rules). |
| src/xurrent/skill_pools.py | Introduces SkillPool resource model and sub-resources. |
| src/xurrent/sites.py | Introduces Site resource model including lifecycle methods. |
| src/xurrent/shop_order_lines.py | Introduces ShopOrderLine resource model and enums. |
| src/xurrent/shop_articles.py | Introduces ShopArticle resource model and enums. |
| src/xurrent/shop_article_categories.py | Introduces ShopArticleCategory resource model and filters. |
| src/xurrent/services.py | Introduces/extends Service resource model with multiple sub-resource methods. |
| src/xurrent/service_offerings.py | Introduces ServiceOffering resource model and enums. |
| src/xurrent/service_instances.py | Introduces ServiceInstance resource model and enums/sub-resources. |
| src/xurrent/risks.py | Introduces Risk resource model and enums/sub-resources. |
| src/xurrent/requests.py | Adds several request sub-resource helper methods (attachments, tags, watches, etc.). |
| src/xurrent/request_templates.py | Introduces RequestTemplate resource model and enums. |
| src/xurrent/releases.py | Introduces Release resource model and enums/sub-resources. |
| src/xurrent/projects.py | Introduces Project resource model and enums/sub-resources. |
| src/xurrent/products.py | Introduces Product resource model and depreciation enum. |
| src/xurrent/product_categories.py | Introduces ProductCategory resource model and rule-set enum. |
| src/xurrent/problems.py | Introduces Problem resource model and enums/sub-resources. |
| src/xurrent/people.py | Extends Person deserialization and adds multiple sub-resource helper methods; fixes update() return type. |
| src/xurrent/out_of_office_periods.py | Introduces OutOfOfficePeriod resource model and filters. |
| src/xurrent/organizations.py | Introduces/extends Organization resource model with lifecycle + sub-resources. |
| src/xurrent/knowledge_articles.py | Introduces KnowledgeArticle resource model and enums/sub-resources. |
| src/xurrent/holidays.py | Introduces Holiday resource model and calendar listing. |
| src/xurrent/effort_classes.py | Introduces EffortClass resource model and filter. |
| src/xurrent/custom_collections.py | Introduces CustomCollection resource model and element listing. |
| src/xurrent/custom_collection_elements.py | Introduces CustomCollectionElement resource model and filters. |
| src/xurrent/core.py | Adds helper endpoints (search, bulk_import, archive/trash/audit listings). |
| src/xurrent/contracts.py | Introduces Contract resource model and enums/sub-resources. |
| src/xurrent/configuration_items.py | Extends ConfigurationItem to deserialize product. |
| src/xurrent/closure_codes.py | Introduces ClosureCode resource model. |
| src/xurrent/calendars.py | Introduces/extends Calendar resource model and helper endpoints. |
| src/xurrent/init.py | Exposes many new classes/enums at package top-level. |
| pyproject.toml | Bumps version; updates author; adds dependency groups metadata. |
| Contributing.md | Adds a changelog documentation reminder. |
| CLAUDE.md | Adds repository guidance for Claude Code (setup, commands, architecture). |
| CHANGELOG.md | Documents newly added resources/methods and CI changes under Unreleased. |
| .gitignore | Adds uv.lock and .claude/ ignores; adjusts diff ignores. |
| .github/workflows/release.yml | Updates release automation steps and action versions; adds Node24 env flag. |
| .github/workflows/python-package.yml | Updates CI matrix, setup-python action, adds lint step, splits unit/integration tests. |
Comments suppressed due to low confidence (1)
.github/workflows/release.yml:165
- The workflow creates a git tag without the
vprefix (git tag ${{ ...effective_version }}) but creates a GitHub Release forv${{ ...effective_version }}. This mismatch will fail because the release tag won't exist (or will produce two different tags). Make the tag name consistent (either tag withv...or remove thevprefix in the release step).
- name: Create Git Tag
run: |
git tag ${{ steps.effective-version.outputs.effective_version }}
git push origin ${{ steps.effective-version.outputs.effective_version }}
- name: Create GitHub Release
if: env.python_changed == 'true'
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ steps.effective-version.outputs.effective_version }}
name: Release v${{ steps.effective-version.outputs.effective_version }}
body: "${{ steps.extract-changelog.outputs.release-notes }}"
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| def search(self, query: str, types: list = None) -> list: | ||
| """ | ||
| Perform a cross-resource full-text search. | ||
| :param query: Search query string | ||
| :param types: Optional list of resource types to search (e.g. ['request', 'person']) | ||
| :return: List of search results | ||
| """ | ||
| uri = f'/search?q={query}' | ||
| if types: | ||
| uri += '&types=' + ','.join(types) | ||
| return self.api_call(uri, 'GET') |
There was a problem hiding this comment.
Addressed in 9961d9a. XurrentApiHelper.search() now builds the query string with URL encoding, and the related unit tests were updated to cover spaces and reserved characters.
| fi | ||
|
|
||
| echo "effective_version=$EFFECTIVE_VERSION" >> $GITHUB_ENV | ||
| echo "::set-output name=effective_version::$EFFECTIVE_VERSION" | ||
| echo "effective_version=$EFFECTIVE_VERSION" >> $GITHUB_OUTPUT | ||
|
|
There was a problem hiding this comment.
Addressed in 9961d9a. The release workflow now strips an optional leading v from the previous tag before splitting the version, so the forced patch bump works for both vX.Y.Z and X.Y.Z tags.
Agent-Logs-Url: https://github.com/fasteiner/xurrent-python/sessions/fa48e3dc-7f83-4675-944c-2cfe73efce6a Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
Addressed in f76ecf4. I switched the affected cross-module annotations to lazy-loaded forward references with TYPE_CHECKING imports where needed, and fixed the undefined |
Agent-Logs-Url: https://github.com/fasteiner/xurrent-python/sessions/af4e838f-ec7d-4f44-90d9-a48f0e7c8a1e Co-authored-by: fasteiner <75947402+fasteiner@users.noreply.github.com>
No description provided.