Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM claims no updates available, file system says otherwise #48

Open
snomos opened this issue May 3, 2024 · 16 comments
Open

DM claims no updates available, file system says otherwise #48

snomos opened this issue May 3, 2024 · 16 comments
Labels
bug Something isn't working

Comments

@snomos
Copy link
Member

snomos commented May 3, 2024

According to DM, Inari Sámi is at latest nightly build:

image

But according to zsh, that is not the case (cf second last line):

-rw-r--r--  1 root  wheel   5276913 Oct  8  2021 /Library/Services/fo.bundle/Contents/Resources/fo.zhfst
-rw-r--r--  1 root  wheel   3165554 Nov  8 16:13 /Library/Services/kl.bundle/Contents/Resources/kl.zhfst
-rw-r--r--  1 root  wheel    104212 Jan 29 15:51 /Library/Services/lut.bundle/Contents/Resources/lut.zhfst
-rw-r--r--  1 root  wheel   3757014 Feb 21  2023 /Library/Services/mhr.bundle/Contents/Resources/mhr.zhfst
-rw-r--r--  1 root  wheel    695254 May  3  2023 /Library/Services/mns.bundle/Contents/Resources/mns.zhfst
-rw-r--r--  1 root  wheel    928493 Aug 31  2023 /Library/Services/mrj.bundle/Contents/Resources/mrj.zhfst
-rw-r--r--  1 root  wheel   1499132 Sep 21  2022 /Library/Services/nno.bundle/Contents/Resources/nn-Runr.zhfst
-rw-r--r--  1 root  wheel   1515258 Sep 21  2022 /Library/Services/nno.bundle/Contents/Resources/nn.zhfst
-rw-r--r--  1 root  wheel   1390961 Jun  1  2023 /Library/Services/olo.bundle/Contents/Resources/olo.zhfst
-rw-r--r--  1 root  wheel  18941111 Jun  6  2023 /Library/Services/se.bundle/Contents/Resources/se.zhfst
-rw-r--r--  1 root  wheel   4737921 Sep 25  2023 /Library/Services/sma.bundle/Contents/Resources/sma.zhfst
-rw-r--r--  1 root  wheel  16927782 Jun  1  2023 /Library/Services/smj.bundle/Contents/Resources/smj.zhfst
-rw-r--r--  1 root  wheel  16336078 Jun  1  2023 /Library/Services/smj.bundle/Contents/Resources/smj_NO.zhfst
-rw-r--r--  1 root  wheel  16286721 Jun  1  2023 /Library/Services/smj.bundle/Contents/Resources/smj_SE.zhfst
-rw-r--r--  1 root  wheel   9990111 Jun  6  2023 /Library/Services/smn.bundle/Contents/Resources/smn.zhfst
-rw-r--r--  1 root  wheel  23269745 Sep 26  2023 /Library/Services/sms.bundle/Contents/Resources/sms.zhfst

In fact, all installed .zhfst files are from last year or older (except one from January this year), while DM claims they are all update to within the last couple of days for most of them.

So something seems seriously wrong with the automatic update system. I reinstalled DM to the latest version available in the stable branch (at divvun.no).

@snomos snomos added the bug Something isn't working label May 3, 2024
@snomos
Copy link
Member Author

snomos commented May 3, 2024

I also tried the newest nightly build of DM, with. the result that it could not contact the Páhkat repository, even after several restarts of DM.

@dylanhand
Copy link
Contributor

I also tried the newest nightly build of DM, with. the result that it could not contact the Páhkat repository, even after several restarts of DM.

I've seen this issue as well. It seems intermittent and often happens after initially working upon first launch.

In case it's helpful while I'm investigating, I've found that reinstalling Divvun Manager is a reliable way of getting it to load.

@snomos
Copy link
Member Author

snomos commented May 6, 2024

I tried reinstalling, and it didn't help. The issue is not that it doesn't get contact with the repo server (that happens as well, but that is, as you say, intermittent, and can be solved after restarts or reinstallation), but that it is lying: it claims the newest version is installed, but the file system and actual behaviour of e.g. spellers tells a different story (the true story).

Lying is one thing, but failing to actually update is the major issue here (and lying is just a symptom of the other problem).

@dylanhand
Copy link
Contributor

I tried reinstalling, and it didn't help. The issue is not that it doesn't get contact with the repo server (that happens as well, but that is, as you say, intermittent, and can be solved after restarts or reinstallation), but that it is lying: it claims the newest version is installed, but the file system and actual behaviour of e.g. spellers tells a different story (the true story).

Lying is one thing, but failing to actually update is the major issue here (and lying is just a symptom of the other problem).

Sorry I wasn't more clear. In my experience, reinstalling usually fixes the issue where DM hangs and does not load the list of packages.

It does not fix its lying that there are no updates when in fact there are.

@dylanhand
Copy link
Contributor

@snomos have you found a reliable way to reproduce the bug where it does not connect/the UI does not refresh?

I've been messing with the app for a while now and haven't been able to reproduce the issue.

@snomos
Copy link
Member Author

snomos commented May 6, 2024

Unfortunately no. I have had reports from others earlier, but with a working system myself, and the whole issue is very strange.

What I can offer now is a Mac (my Mac) that has this issue, and a person willing to spend time in debugging this (me). So chances are a bit better to find the issue, although it won't be easy.

@snomos
Copy link
Member Author

snomos commented May 6, 2024

Could it be related to stale caches or something? Where is the pahkat cache on macOS?

@dylanhand
Copy link
Contributor

Ok 😄

Any information you can provide will be helpful. I've seen this issue before but of course now that I'm trying to debug it, it refuses to present itself.

Not yet sure where the caches are kept. I've spent some time today going through the code to see how the pieces fit together but it's not crystal clear.

@dylanhand
Copy link
Contributor

@snomos is this not a duplicate of #32?

What it sounds like is happening, is that the latest stable version of the package is installed, so DM is not offering to overwrite it with the nightly version.

It sounds, based on #32, that the way this is expected to work is that if a package is installed via the stable channel, switching to the nightly channel will not indicate an update is available, but instead should show that the latest version on the stable channel is installed. Is that right? Can you confirm which way you initially installed the package (stable/beta/nightly)?

Put another way, if I'm interpreting #32 correctly, my understanding is that the result you're seeing is correct in that it does not offer to update to the nightly version (assuming package was not initially installed via nightly channel), but it is incorrect in that it doesn't indicate you're running the latest stable version.

@snomos
Copy link
Member Author

snomos commented May 7, 2024

A very good point, and indeed you are probably right.

At the same time, it illustrates the problem:

Can you confirm which way you initially installed the package (stable/beta/nightly)?

No, I can't reliably, because there is no way I can tell which channel was used to install a given speller. Also the easter egg with version info does not give any clue as to whether the speller was built using nightly, beta or stable.

BUT given the 1.1.1 git tag and its date, it looks likely that my Faroese speller (which I tested right now for the purpose of this bug) was installed using the stable branch. So it looks like you are correct.

And yes, DM should only update installed packages using the same channel as when it was first installed: nightly installs are updated through the nighty channel, beta installs using the beta channel, and stable ditto.

That is, we need to fix #32 ASAP, to end this confusion. For both Windows and Mac.

@dylanhand
Copy link
Contributor

Ok thanks for clarifying. I'll begin looking into #32.

@dylanhand
Copy link
Contributor

Upon further inspection, there actually was a bug with this issue's description that affected nightly packages.

The bug prevented a nightly with the same version, but a more recent timestamp, to be installed.

This is fixed in the latest nightly version.

@dylanhand
Copy link
Contributor

And for the sake of documentation, as discussed offline, Divvun Manager is working as intended. It only supports one channel at a time and does not keep track of channels on a per-package basis.

@dylanhand
Copy link
Contributor

Upon further inspection, there actually was a bug with this issue's description that affected nightly packages.

The bug prevented a nightly with the same version, but a more recent timestamp, to be installed.

This is fixed in the latest nightly version.

This is fixed in version 2.2.1 of Divvun Manager, which is now available from https://divvun.org.

Permalink to Divvun Manager 2.2.1 installer.

@snomos would you like to test and close this issue if resolved?

@snomos
Copy link
Member Author

snomos commented Aug 9, 2024

It is mostly working. ls gives this output:

ls -l /Library/Services/*.bundle/Contents/Resources/*.zhfst 
-rw-r--r--  1 root  wheel     95445 Aug  9 03:55 /Library/Services/ciw.bundle/Contents/Resources/ciw.zhfst
-rw-r--r--  1 root  wheel   5339302 Aug  8 22:53 /Library/Services/fo.bundle/Contents/Resources/fo.zhfst
-rw-r--r--  1 root  wheel   3165554 Nov  8  2023 /Library/Services/kl.bundle/Contents/Resources/kl.zhfst
-rw-r--r--  1 root  wheel    126585 Aug  9 04:53 /Library/Services/lut.bundle/Contents/Resources/lut.zhfst
-rw-r--r--  1 root  wheel   3989680 Aug  9 05:54 /Library/Services/mhr.bundle/Contents/Resources/mhr.zhfst
-rw-r--r--  1 root  wheel   3729486 Aug  9 06:05 /Library/Services/mns.bundle/Contents/Resources/mns.zhfst
-rw-r--r--  1 root  wheel   1550367 Aug  9 06:53 /Library/Services/mrj.bundle/Contents/Resources/mrj.zhfst
-rw-r--r--  1 root  wheel   1499132 Sep 21  2022 /Library/Services/nno.bundle/Contents/Resources/nn-Runr.zhfst
-rw-r--r--  1 root  wheel   1515258 Sep 21  2022 /Library/Services/nno.bundle/Contents/Resources/nn.zhfst
-rw-r--r--  1 root  wheel   1372133 Aug  9 04:31 /Library/Services/olo.bundle/Contents/Resources/olo.zhfst
-rw-r--r--  1 root  wheel  18748838 Aug  9 01:01 /Library/Services/se.bundle/Contents/Resources/se.zhfst
-rw-r--r--  1 root  wheel   3024421 Jul  6 06:51 /Library/Services/sma.bundle/Contents/Resources/sma.zhfst
-rw-r--r--  1 root  wheel  15456360 Jul  7 21:33 /Library/Services/smj.bundle/Contents/Resources/smj.zhfst
-rw-r--r--  1 root  wheel  15463810 Jul  7 21:34 /Library/Services/smj.bundle/Contents/Resources/smj_NO.zhfst
-rw-r--r--  1 root  wheel  15457797 Jul  7 21:34 /Library/Services/smj.bundle/Contents/Resources/smj_SE.zhfst
-rw-r--r--  1 root  wheel  10405214 Aug  9 03:21 /Library/Services/smn.bundle/Contents/Resources/smn.zhfst
-rw-r--r--  1 root  wheel  23545864 Aug  9 03:43 /Library/Services/sms.bundle/Contents/Resources/sms.zhfst

Most languages have been updated to the latest nightly (August 8 or 9). The languages not updated are:

  • kl
  • nn
  • sma
  • smj

The DM status of these languages are:

  • kl — no update available, reports installed Aug 7 2024 (much newer than actually installed)
  • nn — no update available, reports installed September 21 2022 (same as installed, and no newer builds are available due to bugs in the source code)
  • sma — update available, reports installed July 5 2024 (older than actually installed)
  • smj — update available, reports installed July 7 2024 (same as installed)

That is:

  • kl: DM lies, and does not autoupdate - bug is not fixed
  • nn: DM tells the truth, and works as it should
  • sma: DM tells the truth, but autoupdate does not work
  • smj: DM lies (in a strange way), and autoupdate does not work

All in all: DM is much better than earlier, but still not fully working as intended. I'll keep this open for the time being.

@snomos
Copy link
Member Author

snomos commented Aug 9, 2024

Update: after fixing the nno build bug, and refreshing the DM view, the status is now as follows:

  • kl: same as before
  • nn: DM lists the newly built package, and claims nno is not installed
  • sma: local install and build log is consistent (last successful build July 6), DM claims the newest version is from July 5
  • smj: local install, build log and DM are consistent: last available speller is from July 7

I may have mixed sma and smj in the previous comment.

All in all: SMJ seems fine, for the three others there is something fishy. See also this comment in #32.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants