MyCustomerSecretKey is missing secret_key (secretKey)
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 42/100
Hướng nghiên cứu
Bắt đầu bằng cách xác định định nghĩa model Python cho MyCustomerSecretKey và so sánh với CustomerSecretKey, sau đó tái hiện ví dụ create_my_customer_secret_key từ issue. Hoàn thành khi phản hồi của SDK cung cấp secret_key nhất quán với giá trị secretKey của API và hành vi hoặc tài liệu của model liên quan được cập nhật.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Model MyCustomerSecretKey does not include secret_key attribute though it is absolutely returned from the API. I see secret_key is included in CustomerSecretKey model. In both cases the API documentation does not show secret_key is a return value though it absolutely is. Frankly, if it were not in the return the API would be pointless as creating a new key without being able to retrieve the new value is of no use.
Consider this example:
identity_domain_client = oci.identity_domains.IdentityDomainsClient(
config, signer=signer, service_endpoint=domain.url
)
new_key = oci.identity_domains.models.MyCustomerSecretKey(
display_name="SDK",
schemas=["urn:ietf:params:scim:schemas:oracle:idcs:customerSecretKey"],
)
resp = identity_domain_client.create_my_customer_secret_key(
my_customer_secret_key=new_key,
)
resp.data.display_name
'SDK'
resp.data.access_key
'bc8309f45128a4658b18d38fff3997d605d7c380'
resp.data.secret_key
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'MyCustomerSecretKey' object has no attribute 'secret_key'
…however, this works:
endpoint = "/admin/v1/MyCustomerSecretKeys"
body = {
"displayName": "REST",
"schemas": ["urn:ietf:params:scim:schemas:oracle:idcs:customerSecretKey"],
}
resp = requests.post(domain.url + endpoint, auth=signer, json=body)
jsonresp = json.loads(resp.content)
jsonresp["displayName"]
'REST'
jsonresp["accessKey"]
'e74aec6e2317b972691986696403f0b175f60880'
jsonresp["secretKey"]
'tXaYYB0gFUF2/4UthIyYZqCh4Y5tQ3Sp2lxVJKvF+RI='
…so obviously the value for secretKey (or secret_key) should be in the response (as I say, otherwise, what's the point of creating the key?).
- Ngôn ngữ chính
- Python
- Star
- 474
- Fork
- 321
- Merge trung bình
- 23 phút
- Pull request đã merge (30 ngày)
- 4
Chuẩn bị môi trường
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của oracle/oci-python-sdk
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
oracle/oci-python-sdk#890 · 3 bình luận ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
oracle/oci-python-sdk#879 · 3 bình luận ·
-
Example uses non-existent APIĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 66/100
oracle/oci-python-sdk#878 ·
-
SDK
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
oracle/oci-python-sdk#861 · 5 bình luận ·
-
SDK
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 48/100
oracle/oci-python-sdk#852 ·
Tất cả issue của oracle/oci-python-sdk
Issue tương tự
-
good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
vllm-project/vllm-metal#822 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
vector-store
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 90/100
mem0ai/mem0#7461 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug]: chunk_span_bounds and _validated_chunk_spans reject Pydantic models ChunkSpan and AudioFileĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
BasedHardware/omi#19047 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày