tom-anders / Easy_xkcd

An easy and simple open source xkcd reader
Apache License 2.0
164 stars 41 forks source link

Random comics are not really random #329

Closed matusbzk closed 1 year ago

matusbzk commented 1 year ago

Everytime I open the app and click on random, same comics are generated as random.

Steps to reproduce:

  1. Open the app.
  2. Click on random - some comic is loaded (let's call it C1).
  3. Click on random - some comic is loaded (let's call it C2).
  4. Click on random - some comic is loaded (let's call it C3). etc.
  5. Close the app.
  6. Open the app again, and click on random.

Actual result: I see comic C1, then C2, C3, etc.

Expected result: A see random images, not the same ones all over again.

Workaround: I have not found a workaround, but the set of shown comics gets randomly regenerated every time new comic is posted.

matusbzk commented 1 year ago

Looks a lot similar to this issue https://stackoverflow.com/questions/73475522/kotlin-random-always-generates-the-same-random-numbers