Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Incorrect hostname in `/api/0/info` breaks "this device" badge in Web UI

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

Maintainer thường phản hồi trong vòng 2 ngày

Một pull request liên quan đã được merge.

  • #369 của @TimeToBuildBob — đã merge

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
kotlin, rust
Lĩnh vực
backend

Hướng nghiên cứu

Start by reading the /api/0/info handler and the device hostname lookup used elsewhere in the Android application; then trace how the Web UI decides which device gets the “this device” badge. Done means the endpoint reports the real device hostname and the badge identifies that device in a multi-device setup. Pull request #369 is already open, so check its changes and status first.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Description

There are a couple of related issues regarding how the Android device hostname is handled, which affects device identification in multi-device setups.

Current Behavior
  1. When querying the /api/0/info endpoint, the hostname is returned as localhost instead of the actual device name. The rest of the application already uses the device hostname correctly.
  2. On the /#/buckets (Raw Data) page in the Web UI, the "this device" badge only appears for a device named localhost. It fails to highlight the actual device currently being used.
Screenshot Image
Expected Behavior
  1. The /api/0/info endpoint should return the device hostname (the same one used elsewhere in the application).
  2. The Web UI should correctly identify the current device and display the "this device" badge based on the real device name.
Ngôn ngữ chính
Kotlin
Star
279
Fork
63
Merge trung bình
4 ngày 22 giờ
Pull request đã merge (30 ngày)
57

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

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.

Issue khác của ActivityWatch/aw-android

Tất cả issue của ActivityWatch/aw-android

Issue tương tự

Thêm issue về Kotlin

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.