matrix-org / matrix-org/matrix-python-sdk

Support using "User-Interactive Authentication API" for login/register

Đang mở
#82 14 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Api layer architecture breaking Client layer enhancement
Ngôn ngữ chính
Python
Star
266
Fork
118
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Hi,

First of all, thanks for the SDK, that helps a lot!

Now onto my issue: I followed MatrixClient's example on registering an user and got back an error about captcha. Could this be a change in Matrix' protocol that wasn't propagated down here?

>>> from matrix_client.client import MatrixClient
>>> client = MatrixClient("https://matrix.org")
>>> token = client.register_with_password(username="foobar1234", password="password")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/dryvenn/Downloads/matrix-python-sdk/matrix_client/client.py", line 126, in register_with_password
    "m.login.password", user=username, password=password
  File "/Users/dryvenn/Downloads/matrix-python-sdk/matrix_client/api.py", line 110, in register
    return self._send("POST", "/register", content)
  File "/Users/dryvenn/Downloads/matrix-python-sdk/matrix_client/api.py", line 459, in _send
    code=response.status_code, content=response.text
matrix_client.errors.MatrixRequestError: 400: {"errcode":"M_UNKNOWN","error":"Captcha is required."}

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu với matrix_client/client.py tại MatrixClient.register_with_password và theo dõi lời gọi đến các phương thức register và _send trong matrix_client/api.py. Tái hiện yêu cầu đăng ký đã cho đối với matrix.org và kiểm tra các yêu cầu của User-Interactive Authentication API. Được xem là hoàn tất khi đăng nhập và đăng ký hỗ trợ API đó thay vì thất bại với phản hồi captcha-required.

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, authentication
Loại issue
Tính năng
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.