airbytehq / airbytehq/airbyte-api-python-sdk
AIrbyte Get Connection Request incorrectly sending the source configuration object.
- Ngôn ngữ chính
- Python
- Star
- 61
- Fork
- 27
- Merge trung bình
- 4 phút
- Pull request đã merge (30 ngày)
- 2
Mô tả
# Issue: Loss of Important Fields During Source Configuration Retrieval
## **Problem Statement**
While retrieving source information, we have encountered an issue where the expected source configuration dataclass (e.g., `SourceSalesforce`) is not being correctly returned. Instead, the configuration is returned as `SourceAirbyte`, which causes unintended field removal.
## **Breakdown of the Issue**
### **1. Expected Behavior**
- When we create a source configuration using a specific dataclass (e.g., `SourceSalesforce`), we expect to retrieve it in the same structured format.
- This ensures that all necessary fields (such as authentication details, API settings, etc.) are retained, allowing us to update or modify the source configuration seamlessly.
### **2. Observed Behavior**
- Instead of returning the original dataclass (`SourceSalesforce`), the system is returning a more generic `SourceAirbyte` class.
- The `SourceAirbyte` class does not retain all the fields of `SourceSalesforce`.
- As a result, fields specific to `SourceSalesforce` are missing upon retrieval.
### **3. Impact of the Issue**
- **Field Removal:** Since `SourceAirbyte` does not have the additional fields defined in `SourceSalesforce`, these fields are getting removed when retrieving and updating the configuration.
- **Data Loss:** Important configuration settings required for proper functionality are lost.
- **Update Failures:** When trying to modify the source configuration, required fields are missing, leading to issues when saving or syncing data.
- **Unexpected Behavior:** The system may function incorrectly due to missing parameters that were initially set.
## **Potential Causes**
- **Incorrect Serialization/Deserialization:** If the system is serializing the source configuration without considering its original dataclass, it might be defaulting to `SourceAirbyte`, stripping out subclass-specific fields.
- **Improper Type Handling:** The retrieved data might be cast into a generic base class (`SourceAirbyte`) instead of preserving the specific subclass (`SourceSalesforce`).
- **Schema Enforcement Issue:** If the system has predefined schemas for different sources but defaults to `SourceAirbyte` during retrieval, this could lead to loss of information.
- **Incorrect Database/Storage Retrieval:** The stored configuration might not be properly mapped to its specific dataclass when fetching from storage.
Hướng dẫn đóng góp
Hướng nghiên cứu
Theo dõi việc truy xuất, tuần tự hóa và giải tuần tự hóa source xung quanh các dataclass SourceAirbyte và SourceSalesforce, sau đó tái hiện luồng tạo và truy xuất được mô tả trong issue. Công việc được hoàn thành khi việc truy xuất một source giữ nguyên dataclass và các trường riêng của nó, để việc cập nhật source không xóa dữ liệu cấu hình.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- python
- Lĩnh vực
- api
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 38/100