Welcome to the Cumulus Support forum.

Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080

docker cutils recent release not updating

Discussion of the Cumulusutils tool and website generator.

Moderator: HansR

Nossie
Posts: 424
Joined: Tue 16 Aug 2022 8:01 pm
Weather Station: Ecowitt 2551
Operating System: Raspberry Pi5 Debian Bookworm
Location: Stewarton, East Ayrshire UK
Contact:

Re: docker cutils recent release not updating

Post by Nossie »

Hi Hans,

I've done a little digging and asking around a few docker people and ...
Running the app in a container vs a vm/server isn't much difference. If you have the issue I'd bet it's happening if you used a vm as well.
It's something code wise that's causing an issue, it sounds more like a weird race condition that's happening
Main.cs line 343 may be line above it that's the issue
To be honest, race conditions are above me Hans but do you mind telling me what's above line 343?
Ian.

http://www.StewartonWeather.com
Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
User avatar
HansR
Posts: 6926
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: GW1100 (WS80/WH40)
Operating System: Raspberry OS/Bookworm
Location: Wagenborgen (NL)
Contact:

Re: docker cutils recent release not updating

Post by HansR »

Nossie wrote: Mon 14 Oct 2024 11:12 pm Hi Hans,

I've done a little digging and asking around a few docker people and ...
Running the app in a container vs a vm/server isn't much difference. If you have the issue I'd bet it's happening if you used a vm as well.
Remember that there is nobody else who has this issue (others are running Windows or Linux). Not sure of anybody running this in vm.
Nossie wrote: Mon 14 Oct 2024 11:12 pm
It's something code wise that's causing an issue, it sounds more like a weird race condition that's happening
A race condition... see the wiki.
If true, could be related to the next point.
Nossie wrote: Mon 14 Oct 2024 11:12 pm
Main.cs line 343 may be line above it that's the issue
See screenshot:
    Schermafbeelding 2024-10-15 082259.png
    Nossie wrote: Mon 14 Oct 2024 11:12 pm To be honest, race conditions are above me Hans but do you mind telling me what's above line 343?
    What is happening in line 343 is that it creates the main thread to run the different modules as asynchronous tasks. A relatively simple explanation of asynchronous programming is given here.

    It could be some timing issue related to the usage of async but because it used to work on your system and the only thing which has been added is the SQLite libraries (which reside in the runtimes) the problem must be related to those. And that leads me to the remark that the diary module is NOT (currently) run async. It may in future.

    Afaiac, these remarks are guesses and I do not see a reason why any of the remarks should be valid without additional proof.
    I'll think about proving a timing point.

    Anybody with a suggestion is invited to propose something!
    You do not have the required permissions to view the files attached to this post.
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    And btw I checked your original logfile in the firsst post of this thread. It says:

    Code: Select all

    2024-09-12 03:12:23.912 Information Diary constructor: starting
    2024-09-12 03:12:23.937 Error Exception Unknown : The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception.
    2024-09-12 03:12:23.939 Error Data (cont): Microsoft.Data.Sqlite
    2024-09-12 03:12:23.975 Error Data:    at Microsoft.Data.Sqlite.SqliteConnection..ctor(String connectionString)
       at CumulusUtils.Diary.GetDiaryDatabase() in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Diary.cs:line 99
       at CumulusUtils.Diary..ctor(CuSupport s) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Diary.cs:line 61
       at CumulusUtils.CUtils.RealMainAsync(String[] args) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Main.cs:line 609
       at CumulusUtils.CUtils.Main(String[] args) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Main.cs:line 343
    2024-09-12 03:12:23.977 Error Exiting - check log file
    
    So this is likely the reason your friend comes up with the question about line 343. But you need to remember this is just the stackdump of the exception occurring. It is not the line of the error. I read the error still that the library has a problem with the connectionString. The SQLite libraries apparently do load but they fail to initialise.
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    Thanks Hans,

    I've temporarily reverted back to the older version while I have a think, although I did upgrade cmx to 4.2.1 (build: 4040) and that works so that's something

    I'm thinking of putting it on real hardware or atleast a VM - but I haven't tried to export it yet.

    Some remarks of my own, it was very kind of you to add the option of specifying the DB location, however in my tests I think only once did it ever add [Diary] to the cumulusutils.ini, accordingg to notepad++ the file gets updated but that new section is not added and if I do add it directly it looks like it gets ignored. If you are saying that the error may be occurring before diary is executed and not part of the issue pointed out before - is it possible it's something to do with that config generation/append? I have checked write permissions etc and everything does appear to save.

    - thanks.
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    Nossie wrote: Tue 15 Oct 2024 10:05 pm Thanks Hans,
    You're welcome, we'll have to find the solution together!
    Nossie wrote: Tue 15 Oct 2024 10:05 pm I've temporarily reverted back to the older version while I have a think, although I did upgrade cmx to 4.2.1 (build: 4040) and that works so that's something
    I think it will work fine with 4.2.1 but please check the CUtils log on errors
    Nossie wrote: Tue 15 Oct 2024 10:05 pm I'm thinking of putting it on real hardware or atleast a VM - but I haven't tried to export it yet.
    That would be a good test.
    Nossie wrote: Tue 15 Oct 2024 10:05 pm Some remarks of my own, it was very kind of you to add the option of specifying the DB location, however in my tests I think only once did it ever add [Diary] to the cumulusutils.ini, accordingg to notepad++ the file gets updated but that new section is not added and if I do add it directly it looks like it gets ignored. If you are saying that the error may be occurring before diary is executed and not part of the issue pointed out before - is it possible it's something to do with that config generation/append? I have checked write permissions etc and everything does appear to save.
    No, I don't think your issue has something to do with that config generation/append because you also had the problem before I made that modification for you.

    BTW: it is a modification which did not make it to a final version so if you would like to progress to a next beta and would like to continue with that experiment I will have to add it again!
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    Hi Ian,

    Thinking this all over again I just realise the runtimes have a library for all supported possible environments. Is it likely docker does not select - or does not pass a parameter - to select the proper system? How does it handle that?

    On the other hand, CMX is running under the same docker I presume. Please note that the runtimes of CUtils is missing the win and the unix directories but the contents of those is for libraries CUtils does not use.
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    HansR wrote: Sat 19 Oct 2024 8:06 pm Hi Ian,

    Thinking this all over again I just realise the runtimes have a library for all supported possible environments. Is it likely docker does not select - or does not pass a parameter - to select the proper system? How does it handle that?
    That's originally why I asked what modules were needed - lsb-release appears to work with sysinfo and was required in the build previously - from what I understand the fact it's docker should make no difference, it's just a linux distro running within the environment - so whatever a metal install uses to identify the runtime should be used in the same way.
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    OK, fwiw... I can reproduce exactly your error:

    Code: Select all

    2024-10-21 16:18:26.421 Information Diary constructor: starting
    2024-10-21 16:18:26.434 Error Exception Unknown : The type initializer for 'Microsoft.Data.Sqlite.SqliteConnection' threw an exception.
    2024-10-21 16:18:26.435 Error Data (cont): Microsoft.Data.Sqlite
    2024-10-21 16:18:26.476 Error Data:    at Microsoft.Data.Sqlite.SqliteConnection..ctor(String connectionString)
       at CumulusUtils.Diary.GetDiaryDatabase() in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Diary.cs:line 104
       at CumulusUtils.Diary..ctor(CuSupport s) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Diary.cs:line 60
       at CumulusUtils.CUtils.RealMainAsync(String[] args) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Main.cs:line 609
       at CumulusUtils.CUtils.Main(String[] args) in C:\Users\hansr\Documents\GitHub\CutilsFramework\CUtilsNET8\Main.cs:line 343
    2024-10-21 16:18:26.476 Error Exiting - check log file
    
    This happens after I delete the files:

    Code: Select all

    SQLitePCLRaw.batteries_v2.dll
    SQLitePCLRaw.core.dll
    SQLitePCLRaw.provider.e_sqlite3.dll
    
    Are you sure those files are there, valid rights, can be found, have no typo's or whatever...?
    I assume you already re-copied the runtimes from the distro after complete removal?
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    I'm currently rebuilding the container with some modifications and see what happens with that but yes those files exist and have the correct permissions etc.
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    hmmm it's still not updating

    what program or part of cutils calls those files? are there any packages that should be installed for this to be done?
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    Nossie wrote: Mon 21 Oct 2024 3:44 pm hmmm it's still not updating

    what program or part of cutils calls those files? are there any packages that should be installed for this to be done?
    It's only the diary which calls SQLite. If there is data in the database the module is generated and displayed. Without data the process of the diary stops. But SQLite is always required to read the database.
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    @Anybody: do you have any idea what could be a cause of Ian's problem? Cutils is working everywhere but not in Ian's docker environment where CMX (which also has SQLite) is running fine.
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    Hans,

    when you do
    dotnet --list-runtimes
    what is your output? thanks.
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    User avatar
    HansR
    Posts: 6926
    Joined: Sat 20 Oct 2012 6:53 am
    Weather Station: GW1100 (WS80/WH40)
    Operating System: Raspberry OS/Bookworm
    Location: Wagenborgen (NL)
    Contact:

    Re: docker cutils recent release not updating

    Post by HansR »

    Hi Ian,

    Currently away walking in the Ardennes so this has to wait until next monday (earliest).
    Hans

    https://meteo-wagenborgen.nl
    CMX build 4070+ ● RPi 4B ● Linux 6.6.62+rpt-rpi-v8 aarch64 (bookworm) ● dotnet 8.0.1
    BlueSky: https://bsky.app/profile/wagenborgenwx.bsky.social
    Nossie
    Posts: 424
    Joined: Tue 16 Aug 2022 8:01 pm
    Weather Station: Ecowitt 2551
    Operating System: Raspberry Pi5 Debian Bookworm
    Location: Stewarton, East Ayrshire UK
    Contact:

    Re: docker cutils recent release not updating

    Post by Nossie »

    thanks for getting back to me :)

    do enjoy, I'm jealous!
    Ian.

    http://www.StewartonWeather.com
    Containerised Cumulus[MX] 4.2.1 (build: 4040) ● CumulusUtils Version 7.1.1● Ecowitt 2551/WH65/T&HP/WH57/WH45/3x WH51 ● Pi 5 8GB ● Debian Bookworm ● Ubuntu Server Host
    Post Reply