Opened 6 years ago

Closed 6 years ago

Last modified 5 years ago

#14632 closed bug (fixed)

Fail to edit comment/rating

Reported by: humdinger Owned by: apl-haiku
Priority: normal Milestone: R1/beta2
Component: Applications/HaikuDepot Version: R1/beta1
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

This is hrev52295+100, 32bit

I'm only able to edit the comment/rating of a package if I log out and in again. Otherwise I get an alert "Authorization or security issue".

(BTW, what's the checkbox in front of the rating stars for in the rate/comment dialog? I expected deactivating the checkbox would remove the rating, but it doesn't...)

Attachments (3)

1-edit-rating.txt (7.1 KB ) - added by humdinger 6 years ago.
failed editing
2-logout-in_rating.txt (7.3 KB ) - added by humdinger 6 years ago.
success after logout/in
b399d23f9ac36e66f0704371c6923fd7403d7bcf.png (45.3 KB ) - added by mazbrili 6 years ago.

Download all attachments as: .zip

Change History (21)

comment:1 by humdinger, 6 years ago

Owner: changed from stippi to apl-haiku
Status: newassigned

comment:2 by vidrep, 6 years ago

I was able to log in, change the star rating, and edit my comments without any issue on installed apps. Currently running hrev52394 x86_64.

comment:3 by apl-haiku, 6 years ago

I'm only able to edit the comment/rating of a package if I log out and in again.

That seems strange. Do I understand this correctly;

  1. Login
  2. Make a comment
  3. Attempt to edit comment - fails
  4. Logout
  5. Login
  6. Attempt to edit comment - succeeds

Are you able to get the trace log and see if the HTTP request to save the comment has your authentication on it?

BTW, what's the checkbox in front of the rating stars for in the rate/comment dialog?

A rating consists of;

  • Stability
  • Numerical rating 0..5
  • Comments

You are able to make a rating that just has a comment or a rating that just has just a numerical value (stars) and no comment. In the case that you do not want to supply a numerical rating then you should set the checkbox to 'off' state and this will mean that for that rating, the numerical value stored is NULL and there will not influence on the average rating for that package from that rating.

in reply to:  3 comment:4 by humdinger, 6 years ago

Replying to apl-haiku:

That seems strange. Do I understand this correctly; [items 1-6]

Yes. Exactly right.
I attach 2 logs:

  1. when I try to edit the rating and I get the authorization error
  2. right after doing 1. I log out and in and edit a rating successfully

(I redacted my password and token)

BTW, what's the checkbox in front of the rating stars for in the rate/comment dialog?

[...]In the case that you do not want to supply a numerical rating then you should set the checkbox to 'off' state and this will mean that for that rating, the numerical value stored is NULL and there will not influence on the average rating for that package from that rating.

Looks like that's not working. I un-tisk the checkbox, but I see the rating still in the "Rating" tab of HaikuDepot and the number of votes and their average is still the same. Editing the rating again shows the checkbox is ticked.

by humdinger, 6 years ago

Attachment: 1-edit-rating.txt added

failed editing

by humdinger, 6 years ago

Attachment: 2-logout-in_rating.txt added

success after logout/in

comment:5 by humdinger, 6 years ago

Works now. Can we close this, Andrew?

comment:6 by apl-haiku, 6 years ago

Resolution: fixed
Status: assignedclosed

Sounds good!

comment:7 by mazbrili, 6 years ago

Resolution: fixed
Status: closedreopened

cannot rate from haikudepot.. on x86_64 hrev52701

comment:8 by humdinger, 6 years ago

Does it work when doing what's described in the ticket?
Are your logs identical to the ones already attached to this ticket?

comment:9 by apl-haiku, 6 years ago

Hello mazbrili; Can you please identify the package that you are trying to rate.

comment:10 by mazbrili, 6 years ago

all package i try is throw same error message... as picture i attached.

comment:11 by mazbrili, 6 years ago

@humdinger.. i login from haikudepot-> success and then try to rate -> not success, try to logout and re-login is not make different. the error message popup when try to click rate button.

Last edited 6 years ago by mazbrili (previous) (diff)

comment:12 by apl-haiku, 6 years ago

Thank you for the clarification @mazbrili;

Could I please ask you to now use pkgman list-repos command from the Terminal application in order to list the repositories that you are using. This way I might be able to see if there is anything unusual going on with the "url" (identifier) if your repo's mirror.

Could you please ask you to run HaikuDepot with debugging logging which will help to show a bit more detail about what is happening. You can do this by opening HaikuDepot from the Terminal by issuing the command HaikuDepot -v debug. If necessary, pipe this to a file (reply to let me know if you need guidance) and then cut out that part of the log where you are attempting to create the rating. Hopefully there is some helpful hints there.

Version 0, edited 6 years ago by apl-haiku (next)

comment:14 by mazbrili, 6 years ago

haikudepot log:

[ServerIconExportUpdateProcess] did populate 288 packages' icons ( 0.105 secs) received http status 304 --> will not store download to file [ServerRepositoryDataUpdateProcess] remote data has not changed since [Wed, 26 Dec 2018 22:45:21 GMT]
[ServerRepositoryDataUpdateProcess] did fetch data
[ServerRepositoryDataUpdateProcess] will process data
[ServerRepositoryDataUpdateProcess] did process data
[Node<ServerPkgDataUpdateProcess<Haiku>>] initiating
[Node<ServerPkgDataUpdateProcess<Haiku>>] starting process
[ServerPkgDataUpdateProcess<Haiku>] am not updating data for depot [Haiku] as there is no web app repository source code available
[Node<ServerPkgDataUpdateProcess<HaikuPorts>>] initiating
[Node<ServerPkgDataUpdateProcess<HaikuPorts>>] starting process
[ServerPkgDataUpdateProcess<HaikuPorts>] am not updating data for depot [HaikuPorts] as there is no web app repository source code available
unknown process coordinator changed
unknown process coordinator changed
pkg [sqlite] will be updated from the server.
jrpc; will make request to https://depot.haiku-os.org/__api/v1/pkg
jrpc; did receive http-status [200] from https://depot.haiku-os.org/__api/v1/pkg no changelog present for [sqlite] jrpc; will make request to https://depot.haiku-os.org/__api/v1/userrating
jrpc; did receive http-status [200] from https://depot.haiku-os.org/__api/v1/userrating
did retrieve 0 user ratings for [sqlite]
populating package [sqlite]
the depot [HaikuPorts] has no web app repository code

Last edited 6 years ago by mazbrili (previous) (diff)

comment:15 by apl-haiku, 6 years ago

Hello again mazbrilli - thank you for supplying that extra diagnostic information. It appears that the "identification url" is not correct on your setup. Can you please remove the repositories and then add them again. For example, the identification URL for HaikuPorts in your host is;

https://eu.hpkg.haiku-os.org/haikuports/master/repository/x86_64/current

...but the identification URL stored in the repository and HDS is...

https://hpkg.haiku-os.org/haikuports/master/x86_64/current

Once you have re-added the repositories in your system, the two should match and then commenting should work again.

comment:16 by mazbrili, 6 years ago

thanks @apl-haiku..remove repo and add fixed problem.. maybe it can be write somewhere on faq so haiku user can solve if they get problem like me

comment:17 by humdinger, 6 years ago

Resolution: fixed
Status: reopenedclosed

Commenting/rating seems to work if the repo URLs are correct. Closing again.

comment:18 by nielx, 5 years ago

Milestone: UnscheduledR1/beta2

Assign tickets with status=closed and resolution=fixed within the R1/beta2 development window to the R1/beta2 Milestone

Note: See TracTickets for help on using tickets.