🐛 [SignalK] Connecting to ttyUSB*

Description
Not sure if it is a bug or not but I'm not able to get a connection via ttyUSB0 or ttyUSB0 under Connections in SignalK

Reproduction steps
1. Go to 'SignalK'
2. Click on 'Data Connections'

Addon Logs
Registering new address record for ::1 on lo.*.
Registering new address record for <IP_ADDRESS> on lo.IPv4.
Server startup complete. Host name is db21ed7f-signalk.local. Local service cookie is<PHONE_NUMBER>.
*** WARNING *** The program 'node' uses the Apple Bonjour compatibility layer of Avahi.
*** WARNING *** Please fix your application to use the native API of Avahi!
*** WARNING *** For more information see <http://0pointer.de/blog/projects/avahi-compat.html>
*** WARNING *** The program 'node' called 'DNSServiceRegister()' which is not supported (or only supported partially) in the Apple Bonjour compatibility layer of Avahi.
*** WARNING *** Please fix your application to use the native API of Avahi!
 Any other devices I should add at the same time?

OK done

Hi Alexandre,
Ok, I have tried again but no luck, error  still the same:
Jun 29 23:42:29 Error: Permission denied, cannot open /dev/ttyUSB1
Any ideas?
reagrds /anders

From: Alexandre @.>
Sent: Saturday, June 29, 2024 17:36
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
OK done
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2198238773, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LZJQFUW3RPL3QUUOQTZJ3IANAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOJYGIZTQNZXGM.
You are receiving this because you authored the thread.Message ID: @.***>

Hi, perhaps I need to adapt apparmor permissions in addition to the config options, I'll try that later today

Hi,
Tried the latest version but no success, still same error message
Mvh /anders

From: Alexandre @.>
Sent: Sunday, June 30, 2024 09:04
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Reopened #1450https://github.com/alexbelgium/hassio-addons/issues/1450.
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#event-13341470148, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L2SHLNOPR5KMU6FNFDZJ6UYHAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJTGM2DCNBXGAYTIOA.
You are receiving this because you authored the thread.Message ID: @.***>

I'm sorry it's the only configurable options linked to ttyusb that HA proposes I am not sure how to help...

Hi,
ok,  I'm also using the node-red addon and from that I can access ttyUSB0 and ttyUSB1
but I really need it to work with the signal k addon
Could you look at the node-red addon and see if you can get some info regarding this issue?
https://github.com/hassio-addons/addon-node-red
[https://opengraph.githubassets.com/af5ec5bb7f72a58de7f5dc4b3d61354d8a80d1c7606c3afa12703874f4cd020d/hassio-addons/addon-node-red]https://github.com/hassio-addons/addon-node-red
GitHub - hassio-addons/addon-node-red: Node-RED - Home Assistant Community Add-onshttps://github.com/hassio-addons/addon-node-red
Node-RED - Home Assistant Community Add-ons. Contribute to hassio-addons/addon-node-red development by creating an account on GitHub.
github.com
regards /anders

From: Alexandre @.>
Sent: Monday, July 1, 2024 12:07
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
I'm sorry it's the only configurable options linked to ttyusb that HA proposes I am not sure how to help...
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2199745351, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L645XCQDWI3FQKPUWDZKES4VAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOJZG42DKMZVGE.
You are receiving this because you authored the thread.Message ID: @.***>

This addon has TONS of permissions added... I can try to add all of those but it will be preferable to remove it after to avoid creating security risks.
If you are ok I could duplicate the addon on my test repo and add the permissions there

Hi,
ok I understand.
It would be great if you could do that, but I’m
not sure how I can update to that version.
regards /anders
Skickat från Outlook för iOShttps://aka.ms/o0ukef

Från: Alexandre @.>
Skickat: Monday, July 1, 2024 4:30:10 PM
Till: alexbelgium/hassio-addons @.>
Kopia: MrHobsons @.>; Author @.>
Ämne: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
This addon has TONS of permissions added... I can try to add all of those but it will be preferable to remove it after to avoid creating security risks.
If you are ok I could duplicate the addon on my test repo and add the permissions there
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2200322049, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L435J6TBU64ZZAY743ZKFRXFAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBQGMZDEMBUHE.
You are receiving this because you authored the thread.Message ID: @.***>

Hi,
Can you please install the repository https://github.com/alexbelgium/hassio-addons-test ? It will contain an addon named "Signalk Server Test" that has all possible permissions found in the nodered addon. We'll adapt depending on that ;-)
Thanks for your help!

I'll also push an update to the main repo version with a potential fix from https://github.com/esp8266/source-code-examples/issues/26

Hi,
Thanks, I will try this tomorrow and get back to you.
regards /anders
Skickat från Outlook för iOShttps://aka.ms/o0ukef

Från: Alexandre @.>
Skickat: Tuesday, July 2, 2024 7:10:45 PM
Till: alexbelgium/hassio-addons @.>
Kopia: MrHobsons @.>; Author @.>
Ämne: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Hi,
Can you please install the repository https://github.com/alexbelgium/hassio-addons-test ? It will contain an addon named "Signalk Server Test" that has all possible permissions found in the nodered addon. We'll adapt depending on that ;-)
Thanks for your help!
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2203870246, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LYSWAGT27JM254NHB3ZKLNJJAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBTHA3TAMRUGY.
You are receiving this because you authored the thread.Message ID: @.***>

Hi,
Tried the "Signalk Server Test" but unfortunately same error.
Regards /anders

From: Alexandre @.>
Sent: Tuesday, July 2, 2024 19:10
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Hi,
Can you please install the repository https://github.com/alexbelgium/hassio-addons-test ? It will contain an addon named "Signalk Server Test" that has all possible permissions found in the nodered addon. We'll adapt depending on that ;-)
Thanks for your help!
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2203870246, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LYSWAGT27JM254NHB3ZKLNJJAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBTHA3TAMRUGY.
You are receiving this because you authored the thread.

Hi,
Di you also put this in Test?
Regards /anders

From: Alexandre @.>
Sent: Tuesday, July 2, 2024 19:16
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
I'll also push an update to the main repo version with a potential fix from esp8266/source-code-examples#26https://github.com/esp8266/source-code-examples/issues/26
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2203881951, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L4E4GR4ZFJZ2JPTNETZKLOAHAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMBTHA4DCOJVGE.
You are receiving this because you authored the thread.Message ID: @.***>

Hi, "Test" was only with the same config.yaml options than the node red addon (which therefore are confirmed not to be the solution), however the version on the main repo has a specific permission added that should solve the issue according to what I read on some other projects

Hi,
So version 2.8.3-4 has has a specific permission added that should solve the issue ?

That's indeed what I wrote, is it working?

Hi,
No, unfortunately it’s not working.
Same error permission denied.
Regards  /anders
Skickat från Outlook för iOShttps://aka.ms/o0ukef

Från: Alexandre @.>
Skickat: Wednesday, July 10, 2024 11:37:23 AM
Till: alexbelgium/hassio-addons @.>
Kopia: MrHobsons @.>; Author @.>
Ämne: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
That's indeed what I wrote, is it working?
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2220025812, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L35VEDWCZWDDNORJFDZLT6FHAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRQGAZDKOBRGI.
You are receiving this because you authored the thread.Message ID: @.***>

Hi, mmh that is unfortunate as this was the only solution I found on github for other projects corresponding to this issue... I would have to see if I have a mean to replicate this type of device on my system to be able to really find a solution as curently I can only rely on blind tries based on other's solutions

I couldn't replicate but I have an idea. If you have the addons File Editor or Filebrowser, you can find the file /addon_configs/db21ed7f_signalk/signalk.sh . Everything you place in this file will be executed at addon start.
So if you add in this file the code below, it should print you which are the permissions required to access the device. In particular in terms of usergroup.
#!/usr/bin/with-contenv bashio
# shellcheck shell=bash

#################
# CODE INJECTOR #
#################

# Any commands written in this bash script will be executed at addon start
# See guide here : https://github.com/alexbelgium/hassio-addons/wiki/Add%E2%80%90ons-feature-:-customisation
log="$(ls -l /dev/ttyUSB0)"
bashio::log.warning "This is the required permissions : $log"

Hi,
This is the result:
/etc/cont-init.d/01-custom_script.sh: executing
Execute /addon_configs/db21ed7f-signalk/signalk.sh if existing
Wiki here : github.com/alexbelgium/hassio-addons/wiki/Add-ons-feature-:-customisation
... script found, executing
[05:32:01] WARNING: This is the required permissions : crw-rw---- 1 root 18 188, 0 Jul 11 05:22 /dev/ttyUSB0
[05:32:01] WARNING: This is the required permissions : crw-rw---- 1 root 18 188, 1 Jul 11 05:22 /dev/ttyUSB1
/etc/cont-init.d/99-run.sh: executing
[05:32:01] INFO: Starting application
Regards /anders

From: Alexandre @.>
Sent: Thursday, July 11, 2024 07:21
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
I couldn't replicate but I have an idea. If you have the addons File Editor or Filebrowser, you can find the file /addon_configs/db21ed7f_signalk/signalk.sh . Everything you place in this file will be executed at addon start.
So if you add in this file the code below, it should print you which are the permissions required to access the device. In particular in terms of usergroup.
#!/usr/bin/with-contenv bashio
shellcheck shell=bash
#################
CODE INJECTOR
#################
Any commands written in this bash script will be executed at addon start
See guide here : https://github.com/alexbelgium/hassio-addons/wiki/Add‐ons-feature-:-customisation
log="$(ls -l /dev/ttyUSB0)"
bashio::log.warning "This is the required permissions : $log"
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222057869, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LZT5YS6EDMJ2IYA7KTZLYI53AVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGA2TOOBWHE.
You are receiving this because you authored the thread.Message ID: @.***>

That's great thanks! So write read/access is granted to root and usergroup, with usergroup being "18". I detected an error in the code that I should have set the permissions. I'll push a new version now, it should take around 15 minutes to build (until that time you would get a manifest unknown error in homeassistant if you try to install it). Thanks for your patience hope this is will be good this time !

Hi,
Perfect, thanks.
I will try this and let you know
Regards/anders

From: Alexandre @.>
Sent: Thursday, July 11, 2024 07:48
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
That's great thanks! So write read/access is granted to root and usergroup, with usergroup being "18". I detected an error in the code that I should have set the permissions. I'll push a new version now, it should take around 15 minutes to build (until that time you would get a manifest unknown error in homeassistant if you try to install it). Thanks for your patience hope this is will be good this time !
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222085598, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L3ACTVYH3WTH7NHC5DZLYMBXAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGA4DKNJZHA.
You are receiving this because you authored the thread.Message ID: @.***>

Hi,
Did the update and now I have another error and it never starts
/etc/cont-init.d/01-custom_script.sh: executing
Execute /addon_configs/db21ed7f-signalk/signalk.sh if existing
Wiki here : github.com/alexbelgium/hassio-addons/wiki/Add-ons-feature-:-customisation
/etc/cont-init.d/99-run.sh: executing
usermod: group 'UNKNOWN' does not exist
Regards /anders

From: Alexandre @.>
Sent: Thursday, July 11, 2024 07:48
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
That's great thanks! So write read/access is granted to root and usergroup, with usergroup being "18". I detected an error in the code that I should have set the permissions. I'll push a new version now, it should take around 15 minutes to build (until that time you would get a manifest unknown error in homeassistant if you try to install it). Thanks for your patience hope this is will be good this time !
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222085598, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L3ACTVYH3WTH7NHC5DZLYMBXAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGA4DKNJZHA.
You are receiving this because you authored the thread.Message ID: @.***>

Ah - that's a good sign! I'll update the script and push a new version thanks

Hi,
Unfortunately I'm getting Permission error again
Network interface enumeration completed.
Registering new address record for <IP_ADDRESS> on eth0.IPv4.
Registering new address record for ::1 on lo.*.
Registering new address record for <IP_ADDRESS> on lo.IPv4.
Server startup complete. Host name is db21ed7f-signalk.local. Local service cookie is 409187000.
signalk-server running at <IP_ADDRESS>:3000
Error: Permission denied, cannot open /dev/ttyUSB1
Mvh /anders

From: Alexandre @.>
Sent: Thursday, July 11, 2024 10:09
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Ah - that's a good sign! I'll update the script and push a new version thanks
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222302268, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L6SDMDPYT2BCJBJAHTZLY4UTAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGMYDEMRWHA.
You are receiving this because you authored the thread.Message ID: @.***>

Sorry for that. Then most likely I'll have to replicate your system on mine to troubleshoot, alas I will be on holidays for 2 weeks so I won't have time to check again probably soon. Except if you also use the .sh method to inject other code to solve the issue...

Hi, the key thing is that signalk is ran under the user node which
doesn't seem to have access to the device as only root and it's subgroup
have access to it.
We can't increase /dev/ttyUSB permissions as HA mounts it read only so the
only way I was thinking (the last version) was therefore to add node to the
root group but it didn't work. I'll have to think what more we can try...
On Thu, Jul 11, 2024 at 11:31 MrHobsons @.***> wrote:

Hi,
ok, do you have some suggestions what code to add in .sf ?
regards /anders

From: Alexandre @.>
Sent: Thursday, July 11, 2024 11:20
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to
ttyUSB* (Issue #1450)
Sorry for that. Then most likely I'll have to replicate your system on
mine to troubleshoot, alas I will be on holidays for 2 weeks so I won't
have time to check again probably soon. Except if you also use the .sh
method to inject other code to solve the issue...
—
Reply to this email directly, view it on GitHub<
https://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222439627>,
or unsubscribe<
https://github.com/notifications/unsubscribe-auth/BE2F2L5ZYUSHVUZ7WH6D26DZLZE6FAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGQZTSNRSG4>.
You are receiving this because you authored the thread.Message ID:
@.***>
—
Reply to this email directly, view it on GitHub
https://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2222463890,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKRB2GNZKNH6HX2IBUPAELLZLZGFVAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRSGQ3DGOBZGA
.
You are receiving this because you modified the open/close state.Message
ID: @.***>

In addition to the USB devices many will need access to the socketcan device /dev/can0 and maybe /dev/can1 to be able to read NMEA2000 data.
These would also need to be initialised with these commands
ip link set can0 up type can bitrate 250000
ifconfig can0 txqueuelen 65536
neither ip nor ifconfig is accessable in the container, but these can be installed by adding the package iproute2. I do not think can-utils will be needed.

I have messed around, trying to get a decent dev env going. I am tunneling to my boat where I have a rpi cm4 running with an mp2515 connected to can0.  I suspect that the same kind of access issue that is in play with USB will be in play with can, hence why I'm hijacking this issue.
What would be the best way to setup a minimal env on the boat rpi to be able to make local changes to the addon?

Hi, to make local changes shrub the add-on the best is to use my infection script described above.  With it, you can even prevent the normal add-on launch and instead launch it with a custom command. However, it is not possible to modify the add-on configuration (such as permissions) with that, as HA reads the config.json embedded at build time.
I've just thought that to simplify things, I'll push a new build with the "full access" option. From the main option you can decide to give admin access to the add-on and it should have all permissions. If this work, then we can use the injection script to execute commands with admin access disabled. Or we just keep full access, but it is usually not preferable

Hi
I think the "full access" would be nice while we
figure out how to solve this issue.
Regards /anders
Skickat från Outlook för iOShttps://aka.ms/o0ukef

Från: Alexandre @.>
Skickat: Sunday, July 14, 2024 9:09:56 AM
Till: alexbelgium/hassio-addons @.>
Kopia: MrHobsons @.>; Author @.>
Ämne: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Hi, to make local changes shrub the add-on the best is to use my infection script described above. With it, you can even prevent the normal add-on launch and instead launch it with a custom command. However, it is not possible to modify the add-on configuration (such as permissions) with that, as HA reads the config.json embedded at build time.
I've just thought that to simplify things, I'll push a new build with the "full access" option. From the main option you can decide to give admin access to the add-on and it should have all permissions. If this work, then we can use the injection script to execute commands with admin access disabled. Or we just keep full access, but it is usually not preferable
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2227221069, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LZHPBYZZUG7HRQAIK3ZMIP4JAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRXGIZDCMBWHE.
You are receiving this because you authored the thread.Message ID: @.***>

It seems like can0 is not exposed to the signalk container. If i run "ip link" to see the network connections in the injection script there is only lo and eth0. If i do the same in the ssh terminal addon, i get a bunch of interfaces, including can0.

I don't use the addon (in fact it is not even installed), but you might want to know that
hassio_supervisor logs complain with
2024-07-15 19:21:34.805 WARNING (SyncWorker_7) [supervisor.addons.validate] Add-on have full device access, and selective device access in the configuration. Please report this to the maintainer of Signalk Server
(I've read above that this was activated on purpose, but you possibly haven't noticed that this warning pops up generally)
I personally do not care, but wanted to find out what a "Signalk Server" and therefore landed here :)

I don't use the addon (in fact it is not even installed), but you might want to know that
hassio_supervisor logs complain with
2024-07-15 19:21:34.805 WARNING (SyncWorker_7) [supervisor.addons.validate] Add-on have full device access, and selective device access in the configuration. Please report this to the maintainer of Signalk Server
(I've read above that this was activated on purpose, but you possibly haven't noticed that this warning pops up generally)
I personally do not care, but wanted to find out what a "Signalk Server" and therefore landed here :)

Thanks that's because I enabled full access in latest version but kept the partial access to revert once it is working ;)

Hi,
I have np tried the "full access" but it did not solve the problem with permission denied om /dev/ttyUSB1
regards /anders

From: Alexandre @.>
Sent: Sunday, July 14, 2024 09:09
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
Hi, to make local changes shrub the add-on the best is to use my infection script described above. With it, you can even prevent the normal add-on launch and instead launch it with a custom command. However, it is not possible to modify the add-on configuration (such as permissions) with that, as HA reads the config.json embedded at build time.
I've just thought that to simplify things, I'll push a new build with the "full access" option. From the main option you can decide to give admin access to the add-on and it should have all permissions. If this work, then we can use the injection script to execute commands with admin access disabled. Or we just keep full access, but it is usually not preferable
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2227221069, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2LZHPBYZZUG7HRQAIK3ZMIP4JAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRXGIZDCMBWHE.
You are receiving this because you authored the thread.Message ID: @.***>

Been following along this curious to see where it ended up as I will also be needing usb access to signalk in the near future.

Also wanted to add I am willing/able to test anything required.

I'm also interested in can0 access. I plan to power my HA RPi using the Pican-M hat connected to the onboard NMEA2000 bus. The Pican-M board exposed the n2k interface on can0.

Was doing some research on this I wonder if this is a similar issue, which came up with VenusOS (Victron Controller) which also has the ability to run Signalk in a container.. That being said it may not be relevant.
https://communityarchive.victronenergy.com/questions/138314/ngt-1-pi-and-venus.html

This commit https://github.com/alexbelgium/hassio-addons/commit/b07bdce9d8bb1dcded710c0b182d6dcaf95703f4 apparently adds support for /dev/can0

Interesting.
In the past hour I setup a fresh Hass installation on a RP5 with a USB Device (NGX-1-USB) to map to Signalk.
Still receiving the error presented before. "[Error: Error: Permission denied, cannot open /dev/ttyUSB0]"
Core: 2024.9.2
Supervisor: 2024.09.1
Operating System: 13.1
Frontend: 20240909.1
Signal K Addon Version: 2.11.0
Trying to see if there are any other work arounds I can perform to make it work in this environment and will update if anything interesting is found.

This is from a rather old issue, not sure it's even relevant
https://github.com/home-assistant/supervisor/issues/2690#issuecomment-809321072

This is not my area of expertise, but maybe the /dev/can0 will work in the current state because it's a serial interface and not a tty interface? Seems like HA somehow limits access to tty in the container addons. However, there are plenty of addons, like zigbee2mqtt and zwave2mqtt that allows access to tty devices inside the containers.
BTW, the zigbee2mqtt addon does not have an apparmor.txt file. The signalk addon does have that, but /dev/can0 is not mentioned. https://github.com/alexbelgium/hassio-addons/blob/master/signalk/apparmor.txt
PS, I dont have access to my pican-m board at home right now, as it's currently in use on another RPi in my powerboat.

Bump to keep this issue current. Any updates?

Following up on this as I recently had to move my signalk instance off of HASS because of the lack of TTYUSB support and running a separate rpi just for signalk. Would love to move it back as it is the only part that was not working.
Unfortunately I am not exactly sure what is not mapped correctly within the addon, but there are other addons that use the local usb port and devices attached.
Willing to test anything required.

@tingles2233 , I ended up doing the exact same thing, running SignalK on a separate Pi4 in my boat. Data from SignalK is exported to HA through mqtt, and it's actually working great. Running everything on the same Pi would have been nice to reduce the number of devices to integrate, but I think it will be hard to get the Pican-M HAT to function properly on Hass OS. Even if I managed to get the Pican-M HAT including the binary dependencies to function in Hass OS, it's still the issue of exposing the can0 device to the SignalK addon that I believe will be hard. So, I'm quite happy with running two separate devices. The SignalK Pi services AIS data to N2K network onboard to use in my Orca and Garmin nav stations. I think running SingalK on a separate device is a good decision for redundancy.

Hi, I've tried pushing a new version with uart and removal of apparmor just to try, I don't see what other difference zigbee2mqtt has...

This is from a rather old issue, not sure it's even relevant home-assistant/supervisor#2690 (comment)

Thanks very much! It confirmed that uart: true is needed for tty so I implemented it in my last build that should hopefully work!

Awesome thanks Alex I do appreciate your help with this!
I`ll test it out over the next 48-72 hours and update this issue.

I'm having this same issue with the latest release. My device is ultimaterly /dev/ttyACM0, and I get permission denied for it.
Any ideas?

Thanks! Added in a new version

Thanks! Added in a new version

Thankyou! Sadly same error:
Error: Permission denied, cannot open /dev/ttyACM0

Argh thanks. I'll see a bit later to add back the full access toggle in case it helps

I've disabled app armor does it work?

I've disabled app armor does it work?

Sadly not :(

I've disabled app armor does it work?

Sadly not :(

And now? I've removed all possible protections :) please try with the full access flag enabled or disabled

Hi,
I have tried but no success.
Regards /anders

From: Alexandre @.>
Sent: Tuesday, December 24, 2024 16:42
To: alexbelgium/hassio-addons @.>
Cc: MrHobsons @.>; Author @.>
Subject: Re: [alexbelgium/hassio-addons] 🐛 [SignalK] Connecting to ttyUSB* (Issue #1450)
And now? I've removed all possible protections :) please try with the full access flag enabled or disabled
—
Reply to this email directly, view it on GitHubhttps://github.com/alexbelgium/hassio-addons/issues/1450#issuecomment-2561242665, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BE2F2L4ZGAWIQ7C7XHNTAXL2HF6FHAVCNFSM6AAAAABJ2IKZSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNRRGI2DENRWGU.
You are receiving this because you authored the thread.Message ID: @.***>

Well then I guess then it's an issue with HA itself, there is nothing I can do more from my side...
Merry Christmas anyway!


Failed to update on the latest insiders build

GitLens Version: 8.2.3
VSCode Version: latest insiders build
OS Version: Windows 10

See Microsoft/vscode/issues/48373
Basically, any time I am trying to udpate gitlens (since last week or so), I am presented with an error dialog: Failed to update.

As GitLens installation is completely controlled by vscode itself, and the vscode issue has been resolved, I'm going to close this.


[VT-32] Scroll through history

Scott Kostyshak on 2013-05-03T20:35:30Z says:
Currently, if I do ":" and then , the prompt changes to "Annotate:". Same with "c" and then .
It would be nice if these scrolled through the previous commands.
If that's too difficult, I would suggest having  be an escape in this context because "Annotate" does not seem intuitive here.

Migrated metadata:
Created: 2013-05-03T20:35:30Z
Modified: 2014-06-27T14:07:18Z

David Patrick on 2014-06-08T20:09:03Z says:
duplicate?

Scott Kostyshak on 2014-06-09T00:54:46Z says:
Yes, thanks for catching this David. I've fixed the "Annotate:" appearing. Now  and  have no effect. But the main feature, command history, is still not implemented.

Scott Kostyshak on 2014-06-27T14:07:18Z says:
Implemented at 716d51d8.


How to use custom metrics?

Hi, i read sourse code and could not understand how to use custom metrics? Does exist way do it, or i should rewrite this library?

Any update on this issue? It seems you can add custom metrics but the question is how to trigger them?
Thanks in advance!

@nizarayari Yes, you should use gin metrics with you custom mectrics build with standart prometheus library methods.  Gin prometheus library collect base metrics and bind it into common metrics report

ok.. so im a bit stumped here.
i have the custom metrics implemented (so i can see them show up when i have my server running):

However, even with looking with the answer provided to nizarayari, i dont see how to apply the .Inc() method to the custom metric.
Here is my code snippet:
func main() {       r1 := gin.Default() // Main Server       r2 := gin.Default() // A server where Prometheus itself runs on        // Optional Custom Metrics List         customMetrics := []*ginprometheus.Metric{                 &ginprometheus.Metric{                         ID:          "9001",          // required iD                         Name:        "test_metric",   // required string                         Description: "A test metric", // required string                         Type:        "counter",                 },                 &ginprometheus.Metric{                         ID:          "9002",          // required ID                         Name:        "test_metric_2", //required string                         Description: "test 2 metric",                         Type:        "summary",                 },                 // TYPES: counter, counter_vec, gauge, gauge_vec, histogram, histogram_vec,summary, sum_vec         }         p := ginprometheus.NetPrometheus("gin", customMetrics)         r1.Use(p.HandlerFunc())         p.SetMetricsPath(r2)         r1.GET("/alive", func (c *gin.Context) {                       // I want to increase the counter on this hit                       // This is 'wrong" , but iterating i know its the first it the sllice                       test_cnt := p.MetricsList[0]                       test_cnt.Inc()
c.JSON(http.StatusOK, gin.H{
"code": http.StatusOK,
"status": "alive",
})
     go func () { r2.Run(":8443") } ()
     err := r1.Run(":5000")
     if err != nil { panic (err) }

}
I have tried as well looking at the other example, however the prometheus.Register(numErrors) example never ends up showing up in the gin metrics list (as the test ones outlined above are).
any pointers would be wonderful!
D

I change MetricsList []*Metric to MetricsList map[string]*Metric, when i use the custom metrics. Make a easy way to get  custom metric.
customMetrics := []*ginprometheus.Metric{
	&ginprometheus.Metric{
		ID:	"1234",				// optional string
		Name:	"test_metric",			// required string
		Description:	"Counter test metric",	// required string
		Type:	"counter",			// required string
	},
	&ginprometheus.Metric{
		ID:	"1235",				// Identifier
		Name:	"test_metric_2",		// Metric Name
		Description:	"Summary test metric",	// Help Description
		Type:	"summary", // type associated with prometheus collector
	},
	// Type Options:
	//	counter, counter_vec, gauge, gauge_vec,
	//	histogram, histogram_vec, summary, summary_vec
}
p := ginprometheus.NewPrometheus("gin", customMetrics)
// add data to custom metrics
m := p.MetricsList["1234"].MetricCollector.(prometheus.Counter)
m.Inc()

Thanks @snowlyg


APEXCORE-303 #resolve evaluate the launch properties at application l…

…aunch

@davidyan74 : Can you please add test case as well so that users know how to use this enhancement?

@gauravgopi123 added unit test


Final changes from my side

[x] fix figure caption formatting
[x] add Listing 6 as example
[x] archive to Zenodo, to preserve the examples
[x] make Listing 1 a working Dockerfile, although still not "sensible"
[x] use other listing formatting so the listings don't break across pages

@sje30 What do you think about this "working" Dockerfile as the full example.
@vsoch Stephen suggested to make the "full Dockerfile" one that actually works, and here is my attempt at doing that.

What do you think about this "working" Dockerfile as the full example.

I think it looks good.  But shouldn't it also be available in the examples folder so that someone can run it.  (Listings legend should then say how it should be run.)

or even if it just on dockerhub, so that someone can run it with a command that we give them.

It is in the examples directory, see https://github.com/nuest/ten-simple-rules-dockerfiles/blob/ab5d300ea986ac924f8b985d2ed27905189381a7/examples/full-demo/Dockerfile
It is included into the manuscript form that file, see https://github.com/nuest/ten-simple-rules-dockerfiles/pull/81/files#diff-a5e29fb9dc2e9e18941d1125cabcbaefR158
Re. build on Docker Hub: IMO we want people to look at the Dockerfile to better understand the application of the rules. Having a pre-built image does not add a value to that. But I can of course create an automated build on Docker Hub and Circle CI :-)

I merge this now and then create an automated build on Docker Hub and Quay.io.


fix: fix long press on search dropdown items

The type of this PR is: Fix
Description
When I press (long click) on search results in the dropdown - redirect doesn't happen. This PR fixes the issue.

Before
After

@dzucconi I know you've recommended relying on Link's native redirect behaviour, but for some reason it doesn't work in this case. My theory (might be complete nonsense though), is that when a user presses on a search result item and then releases the mouse button (or trackpad) - Link is no longer in the DOM (because dropdown is closed / destroyed), thus redirect doesn't happen.

 However, I cannot open the search result in a new tab any more. I believe this is confronting with this resent PR.
Do you think we could address both issues or should we compromise?

@dariakoko I'm not sure that I will be able to fix both quickly, but the issue with long press (which in reality is not even a long press, just a slightly longer click) definitely has higher priority. I would deploy this PR and then try to find a solution that satisfies both requirements, wdyt?

@nickskalkin Sounds good, thank you 🙏
Let me know if I can be helpful here

Would it not make sense to fix the root cause?

:ceiling-cat: what's that root cause?

@joeyAghion Presumably something to do with the mousedown handler in the AutocompleteInput? It'd be worth investigating though!

FYI: @dariakoko and I have pair programming session scheduled for tomorrow to try to find the root cause and fix it

@dzucconi question. Do you know why we have onMouseDown here? @dariakoko and I are wondering if this should be onClick. Seems like using onClick fixes the issue.
The problem is that when user presses on an option, in handleMouseDown function UI gets cleared (dropdown destroyed) after 100ms delay. If user keeps mouse pressed - dropdown UI is cleared before user releases the mouse button. But seems like router links (that are inside options) start handling redirect only after user releases mouse. But at this point of time there are no links in DOM, so redirects are not handled.
onClick will wait until user releases the mouse button, and only after that will clear UI.
Sorry it explanation is convoluted. Let's have a call if something is not clear

@nickskalkin I think you're right. I don't recall the specific motivation, but it does look/feel like a mistake. Let's change that to click and go from there.

@dzucconi, oki, I'll open PR, thanks


The repo is dead

Thefuck is one of my favourite tools, and recently I've been looking to contribute, but the project seems pretty much dead at the moment. There are a few people commenting on issues and PRs that it seems like people would be willing to help out, but nothing has really been done.
As of writing, @nvbn has disappeared (see https://github.com/nvbn/thefuck/pull/1415#issuecomment-2091471140), there are 260 open issues out of 730 total issues (with 470 closed issues) and 86 open pull requests out of 695 total.
The most recent commit was c7e7e1d, which constituted fixing readme typos and 62e0767, the commit before that, is well over a year old now. It seems like @scorphus is the most recent active maintainer, however given the time since the last merged PR and hasn't commented on any issues or PRs since. His github activity shows he was still around doing something pretty consistently up until a bit over a week ago, but hasn't done anything related to this project since the PR in January.
In #1415, there is some discussion about a maintainer (presumably @scorphus) fixing the issue and not merging the PR, however that was well after the second last commit to main, so I'm unsure what exactly is going on there. It's possibly a misunderstanding, as the latest release is from January 2022, which means somewhere around two and a half years of commits until 62e0767, none of which have been released.
If anyone knows of a maintained fork, please mention it here. If not, I might consider putting myself up for the task of maintaining the project, but ideally it would be a part of the original repo here instead of a fork. If anyone else would like to maintain the project, please volunteer yourself as I'm not entirely sold on the idea of maintaining this myself but I would like to see this project get some of the love, bugfixes and updates it deserves.

Hi @cyuria,
I stumbled on this project, the idea of this project is great, but with all the LLMs out there it makes more sense to send the errors to an llm and get it to suggest a correction instead of trying to manually create the list of corrections.
I am trying to create a LLM assisted terminal, pretty much doing a similar concept, creating a middle man for the shell in a similar way, but:

automatically send errors to some ai agent, responses would be printed on sdtout
create an "askai" command that just sends the question over to the ai
Runs the LLM locally for privacy, but allows api setup

Something on the lines of https://www.warp.dev/ - but much less fancy.
I dont think I can commit to own a proper repo.

@jdtogni78 That sounds like a great idea. I myself personally prefer hard and fast rules, as it's more predictable. If I write a rule for, say, running a command with sudo, I know exactly when it's going to trigger and exactly what the output is.
This isn't to say there isn't a place for LLMs, I just prefer something more predictable. I think there have been a couple issues here with requests for AI integration and maybe even a PR, although I don't have them on hand.
While you say you don't want to own the repo, I do think it's a good idea and if you want to do it, you should just start writing the code now. My advice is to not feel pressured to maintain a repo and instead just do what you feel like. If your repo gains enough traction, there will be people willing to take on maintenance.
I myself don't have any experience working with AI integration code, so I don't think I can commit to something like what you're describing either, but maybe sometime in the future? Either way, I'd encourage you to just start writing code now and worry about other people later. OSS is inherently unselfish, and you as a developer have absolutely no obligation (be it moral or otherwise) to do what anyone else says or expects.
To use thefuck as an example, @nvbn hasn't been seen in a long time. I find it a shame that such an excellent repo has pretty much died out, but there's nothing I can really do about it. I don't blame nvbn either, I'm thankful that he made the project in the first place. If you want to write your own tool, go ahead. By writing OSS code, you aren't promising anything other than the legal rights to use and modify the stuff you wrote, meaning you can just up and leave like nvbn and people will (or should anyway) be thankful for the work you've already put in.
This is really all just to say "start writing the code now and everything else can come later".

Indeed a shame. My repo is a POC, I just uploaded a mov to showcase the idea - https://github.com/jdtogni78/ai_term/blob/main/README.md

How does one adopt an orphaned project in this state? Is it possible? 🤔

I've started working on my own take on https://github.com/nvbn/thefuck.
I'm planning to call it oopsie. There's nothing public yet, but I'll post here once I have something I'm ready to share.
I'm thinking it'll use a plugin system (likely pluggy, although I need to spend some more time familiarizing myself with it) so that it's easy to write and share 3rd-party "Rules" (thefuck's term. For now, oopsie calls them SuggestionProviders.).
It'll likely support just zsh (and maybe bash?) on macOS and Linux at release (since that's all I use regularly), but I'd be open to contributions that add support for other shells/OSes.

@cj81499 I think you used the wrong link?

I did not, although I can see how my comment wasn't perfectly clear. To clarify, I have started working on my own take of this project (thefuck).
However, my project (which is called oopsie) is not shared publicly yet. I will share the repo publicly here once I've made a bit more progress.

I feel like it should be resurrected if at all possible.

I hear that. Unfortunately, I'm not aware of a way to "adopt an orphaned project" unless the author/maintainer transfers it to someone else.
Afaik, the best you can do is fork or rewrite. Personally, I decided I'd prefer to rewrite.

If oopsie grows to become popular and have contributors other than me, I'd happily move it to an org (either its own or perhaps https://github.com/jazzband) so that I'm not a single point of failure (like nvbn is/was 😢).

@mbridon Responding to your comment here, you wrote:

Well, I guess the original author @nvbn seems to have disappeared, so all it would take is for someone to fork the repo and merge this PR and then assume maintenance of the project.
I won't do it for health reasons, so if someone who commented on this PR wants to have a go at it then go ahead. 🤷
And when @nvbn comes back eventually, assume joint maintenance all together.
Free Software sometimes loses maintainers and find new ones, that's how it sometimes evolves and continues.

This repo already has some ~3400 forks on Github alone. Can you offer any insight into how one fork might distinguish itself as the continuation? (To be clear, this is not a rhetorical question; I know this must not be the first time it was accomplished, but I don't know how.)

@rpdelaney Off the top of my head, https://github.com/pygame-community/pygame-ce is a fork at a similar scale. IIRC the repo owner had some philosophical issues with a lot of the devs so most of them split off. Regardless, it's pretty distinguished in its own right due to having more features and better performance in general.
I think the main distinction for a continuation would be having most or many of the original devs working on the same fork.

There also seems to be pay-respects.

There also seems to be pay-respects.

At first glance this is pretty cool. I personally consider rust to be the wrong language for something like this (an interpreted language would be better IMO) and it shows in needing to recompile for adding/changing any new rules, which will seriously mess with packaging. Even with those caveats, it seems cool though and it is a maintained alternative to thefuck.

@cyuria I think you might have had the wrong URL in your clipboard: you gave a link to pygame-ce, which has no obvious connection to thefuck.

@cyuria I think you might have had the wrong URL in your clipboard: you gave a link to pygame-ce, which has no obvious connection to thefuck.

Pygame-ce is a fork similar to what I think would be good to achieve with thefuck. Sorry if I wasn't too clear about that.

I would love for this to be maintained as well

The tool is not working properly for me, I wrote gt commit -m "Correct foo bar" and it's suggesting gtr or gtf instead of clearly git:

Note, it's on the latest version.

The tool is not working properly for me, I wrote gt commit -m "Correct foo bar" and it's suggesting gtr or gtf instead of clearly git:

Note, it's on the latest version.

@ppamorim this isn't necessarily the best place to post problems like this. It would probably be better to create a separate github issue for this one, or even a pull request if you're familiar with python and/or willing to put some time into figuring the issue out.

What's the point to do anything if the repo is dead? Comments and PRs are ignored, it's a waste of time.

If the repo is ever revived, the issues will be useful. If someone chooses to fork the project, they might look through existing issues and pull requests and port them to the fork.
Furthermore, issues, PRs, etc aren't ignored. Other people like myself still look at them from time to time, it's only the maintainers who've stopped looking.
Lastly, it's really just good etiquette to not spam random issues with unrelated problems. Doing so makes you come across as not really caring and a bit of an asshole, which isn't usually conducive to getting your problem resolved.

@ppamorim this isn't necessarily the best place to post problems like this. It would be better to create a separate github issue, or even a pull request if you're familiar with python and/or willing to put some time into figuring the issue out.

Not only that, https://github.com/iffse/pay-respects appears to be a much better solution over this implementation, sadly this project in python is dead and I don't see any possibility it will get any improvement in the long run.

What's the point to do anything if the repo is dead? Comments and PRs are ignored, it's a waste of time.

If the repo is ever revived, the issues will be useful. If someone chooses to fork the project, they might look through existing issues and pull requests and port them to the fork.
Furthermore, issues, PRs, etc aren't ignored. Other people like myself still look at them from time to time, it's only the maintainers who've stopped looking.
Lastly, it's really just good etiquette to not spam random issues with unrelated problems.

I really didn't want to post that as an spam but as an warning of the library state, for me that situation appears so ridiculous it makes the library not useful at all. If I had a very specific case where the tool would generate a bad response I would open a card specific for that issue.

There also seems to be pay-respects.

At first glance this is pretty cool. I personally consider rust to be the wrong language for something like this (an interpreted language would be better IMO) and it shows in needing to recompile for adding/changing any new rules, which will seriously mess with packaging. Even with those caveats, it seems cool though and it is a maintained alternative to thefuck.

I really don't get why a interpreted language would be any better or different at all since all the rules defined there are toml files, it's a totally modular solution allowing you to add any rule without any recompilation and it's only evaluated on the parser part.

I really don't get why a interpreted language would be any better or different at all since all the rules defined there are toml files, it's a totally modular solution allowing you to add any rule without any recompilation and it's only evaluated on the parser part.

On second glance it looks like I misread the documentation. There are actually two types of rules and only one of them needs recompilation. I still believe an interpreted language offers more flexibility with rules, as toml isn't exactly turing complete, but I imagine for 99% of use cases that's not an issue and for the 1% you can recompile. Thanks for pointing this out to me, I'll update the original issue to add pay-respects as an alternative to thefuck.


Try making closed issues have grey bg and all grey text

Can't get grey background to work, possibly because way too much work is being done on the main thread, so this might take some refactoring. For now I've done grey labels, closed issue icon, and text.


Python Test breaks EDR MONITOR

Describe the bug
Running edr monitor after a failed python test with following error:
elementary.exceptions.exceptions.DbtCommandError: Failed to run dbt command - {'returncode': 1, 'cmd': ['dbt', '--log-format', 'json', 'run-operation', 'get_pending_test_alerts', '--args', '{"days_back": 1, "disable_samples": false}', '--project-dir', '/Users/oskarelvkull/Library/Python/3.8/lib/python/site-packages/elementary/monitor/dbt_project', '--target', 'prod'], 'output': b'{"code": "A001", "data": {"v": "=1.3.1"}, "invocation_id": "29566b3c-1385-4b8b-b4b0-6359240ce881", "level": "info", "log_version": 2, "msg": "Running with dbt=1.3.1", "pid": 13745, "thread_name": "MainThread", "ts": "2023-03-01T07:11:12.890608Z", "type": "log_line"}\n{"code": "Q001", "data": {"exc": "Database Error\\n  002003 (42S02): SQL compilation error:\\n  Object \'<REDACTED>.ELEMENTARY.PYTEST_TMP__ELEMENTARY_SOURCE_JSON_SCHEMA__BF323C23D3F5E6B18C3A3F1A8E995C6E\' does not exist or not authorized."}, "invocation_id": "29566b3c-1385-4b8b-b4b0-6359240ce881", "level": "error", "log_version": 2, "msg": "Encountered an error while running operation: Database Error\\n  002003 (42S02): SQL compilation error:\\n  Object \'<REDACTED>.ELEMENTARY.PYTEST_TMP__ELEMENTARY_SOURCE_JSON_SCHEMA__BF323C23D3F5E6B18C3A3F1A8E995C6E\' does not exist or not authorized.", "pid": 13745, "thread_name": "MainThread", "ts": "2023-03-01T07:11:14.623132Z", "type": "log_line"}\n', 'stderr': b''}

Running on Snowflake.
The reason why it fails seems to be that it tries to query a table, that is non-existent. The reason why the table does not exist is this line in compile_py_code.sql
output_df.write.mode('overwrite').save_as_table(target_relation, table_type='temporary')
The table is written as a temporary table and only exists in that exact session. Since the name include tmp it could be that the table should be temporary and the fault is somewhere in the edr monitor.
A simple fix would be to remove the table_type='temporary' but the could be a reason why it is temporary, maybe the result of the test is fetching wrong "result query".
To Reproduce
Any failing python test in Snowflake should cause this error.
Expected behavior
The expected behaviour would be that edr monitor does not fail.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment (please complete the following information):

edr Version: 0.7.2
dbt package Version: 0.7.1

Additional context
Add any other context about the problem here.

Hi @Deathfireofdoom, does this issue still occur?
I believe we've made some changes in the latest versions of edr and the dbt package that should prevent this from happening.

Closing since there has been no response for a while, please open a new issue if relevant!


Gibberish undefined variable.

Are these type of errors handled by the LS? I'm not sure why but from time to time I get some weird message about undefined variables with code that's not present. Usually reloading fixes the issue and it doesn't happen again. I have no hard evidence of why it happens but seems to have more often when typing occurs when the background analysis is in process.

Probably same as #1009

https://github.com/microsoft/python-language-server/pull/1227 probably fixed this as it was possible to try and retrieve document content while document was being updates as a result of editing. Please reopen if you see this in 0.3.18+ builds


suggestion: add a default include_dir configuration

Hi,
I find it harder than it should be to customize postgresql.conf:

usually PGDATA is bind mounted so it’s not always easy to add a file in there at the right time (or replace a file)
there’s options with /docker-entrypoint-initdb.d scripts but those are executed only when the database does not exists

so I suggest to add an include_dir configuration in the default postgresql.conf
in the Dockerfile, where listen_addresses is added, something along mkdir /docker-postgres-conf.d/ && echo 'include_dir=/docker-postgres-conf.d/' >> /usr/share/postgresql/postgresql.conf.sample
I believe this would be really useful, comes with no BC break and low maintenance
what do you think ?
(might be related to #581)

Sometimes it can be necessary to be able to customize server config within the image instead of overriding via command line arguments to docker run, so +1 for this.
What do you think @wglambert ?

Actually, would also be great if it would be possible to interpolate container start-up time environment variable values in config files. This would be useful e.g. in configuring cron.database_name parameter value for the pg_cron extension.

Using your suggestion, it is not that hard to extend the image for your own needs. Unfortunately, I don't think this is something we want to add to the image right now.
FROM postgres:13
RUN set eux; \
	confdir='/docker-postgres-conf.d/'; \
	mkdir -p "$confdir"; \
	chown postgres:postgres "$confdir"; \
	echo "include_dir = '$confdir'" >> /usr/share/postgresql/postgresql.conf.sample

$ docker build -t pg .
Sending build context to Docker daemon  11.26kB
Step 1/2 : FROM postgres:13
 ---> 293e4ed402ba
Step 2/2 : RUN set eux; 	confdir='/docker-postgres-conf.d/'; 	mkdir "$confdir"; 	chown postgres:postgres "$confdir"; 	echo "include_dir = '$confdir'" >> /usr/share/postgresql/postgresql.conf.sample
 ---> Running in 01feb0757294
Removing intermediate container 01feb0757294
 ---> c9083ff81afd
Successfully built c9083ff81afd
Successfully tagged pg:latest
$ cat extra.conf
shared_buffers=256MB
$ docker run -it --rm -e POSTGRES_PASSWORD=12345 --name pg-test -v "$PWD/extra.conf":/docker-postgres-conf.d/extra.conf pg
$ # check via another terminal and shared_buffers is correctly changed from the default

Conf files mounted this way or otherwise placed in the configuration directory would need to have proper permissions for the postgres user to read it.

thx @yosifkit ! It’s indeed not too hard. Especially if we’re already build a custom image (eg: to install 3rd party extensions)
Still, I don’t understand why it should not be included in the base image, is it to keep as close as possible to the default Postgres configuration ? Or is it not useful enough ?
If you have a bit of time to spare, I would be interested in reading your point of view on the subject
I’m just asking out of curiosity, feel free to ignore this and close the issue if it’s not useful to keep this issue around. I won’t be offended !
And if you have time to waste, here is the thought process that led me to open this issue/suggestion :
For most project the default Postgres image is enough, and I can make it work by changing the configuration with command line arguments, but it’s not the nicest when you want to read / edit or look at configuration changes over time (because it’s - in my case - included in the docker-compose.yml file which should not, imho, be the place where I configure Postgres. The alternative is, as you mentioned, to build a custom image, either adding an include_dir in the default configuration file and mounting the configuration as a volume (or docker config) or adding the whole configuration into the image. Either way, it requires building and tagging a new image and probably pushing it to a registry. It’s not a huge task, but it’s tedious, and if you don’t already build custom images as part of your process it’s even more intimidating. I’m not a maintainer of widely use docker images, so I can definitely have missed something, but I thought this change comes with very little costs.

They don't want to add one line into configuration file to simplify image usage for hundreds of people, people won't use their image. I personally prefer to use mysql, and this case is one of the reasons why.

i would really like to have an option to specify an include_dirs,
to achieve it i:

created a custom entrypoint script
called the default one
wait a little time then stop the service
edit the .conf to add the include dir
restart the service

`
#!/bin/bash
set -e
Call the original entrypoint script to set up the environment
docker-entrypoint.sh postgres &
Wait for the PostgreSQL server to be initialized and the postgresql.conf file to be generated
sleep 10
Modify the postgresql.conf file
echo "include_dir = '/etc/gci/pgconf/'" >> /var/lib/postgresql/data/postgresql.conf
Stop the PostgreSQL server that was started by the original entrypoint script
pg_ctl -D "$PGDATA" -m fast -w stop
Now start the PostgreSQL server again with the modified configuration
exec postgres
`
it shouldn't be too hard to set in the entrypoint a verification if an include_dirs env var is set, and if path exist enable the include_dirs conf with this path in the original .conf before starting it, base use will still be able to use the current image as it, and advanced use will be able to use it as a base image and include custom .conf to be added


Add basic authentication support in Marathon

This PR adds basic authentication support in Marathon.
See #110

LGTM 🐻


Add Russian language translation

Coverage remained the same at 92.308% when pulling 037b819a75e686509ae45e5f803e2d66cc722631 on webartisans-org:master into 27c0cf89a616c9d7ad14f4d2ca84c5bb014f8149 on arteria:master.


Additional option to make the sign-in and -up forms become an overlay without rerouting

It would be nice to have an option that allows login forms to be shown in a dropdown or popup or a overlay without a reroute happening. However, with having a fixed route accessible for fallback reasons, e.g. if aforementioned option is not a choice like on few mobiles.

...for the dropdown stuff theres accounts-ui ;-)
something like a modal?
This might me something for v2.0

Yes, like a modal, but also other kind of overlays or dropdowns.
Thanks though ^^


Bring Keystore branch up to date with master

It looked like some important changes happened in master since the last time this branch was updated.

Never mind, it looks like the only thing this branch has that master doesn't is a couple of readme lines.
It would be nice to remove the keystore branch and the note that suggests we need it.

My mistake, I meant the note in redux-persist-sensitive-storage, the branch is the only confusing thing over here :)


It Seems Like It Choked: Uncaught (in promise) Syntax Errors

From Dataview Type Query
TABLE mathLink-blocks.AltNotation, mathLink-blocks.Dimensions, mathLink-blocks.LinkedDimensions, mathLink-blocks.StaticDimensions, mathLink-blocks.LinkedStaticDimensions, mathLink-blocks.MKS, mathLink-blocks.CGS,mathLink-blocks.FPS, mathLink-blocks.LinkedFormula
FROM "Glossary"
LIMIT 50

obsidian.md-1714877932099.log
From Dataviewjs Type Query
const {fieldModifier: f} = this.app.plugins.plugins["metadata-menu"].api;
dv.table (["File", "mathLink", "AltNotation", "Dimensions", "LinkedDimensions", "StaticDimensions", "LinkedStaticDimensions", "MKS", "CGS", "FPS", "LinkedFormula"],
	await Promise.all(dv.pages('"Glossary"').map(async p => [
		p.file.link,
		await f(dv, p, "mathLink"),
		await f(dv, p, "mathLink-blocks.AltNotation"),
		await f(dv, p, "mathLink-blocks.Dimensions"),
		await f(dv, p, "mathLink-blocks.LinkedDimensions"),
		await f(dv, p, "mathLink-blocks.StaticDimensions"),
		await f(dv, p, "mathLink-blocks.LinkedStaticDimensions"),
		await f(dv, p, "mathLink-blocks.MKS"),
		await f(dv, p, "mathLink-blocks.CGS"),
		await f(dv, p, "mathLink-blocks.FPS"),
		await f(dv, p, "mathLink-blocks.LinkedFormula"),
		])
))

obsidian.md-1714878245785.log

const pageNum = dv.current().page;
const start = 10 * (pageNum - 1);
const end = 10 * pageNum;
const results = dv.pages('"Glossary"');
const regex = />\s\[\!theorem\]\s(.+?)((\n>\s.*?)*)\n/;

const rows = []
for (const page of results) {
    const file = app.vault.getAbstractFileByPath(page.file.path)
    // Read the file contents
    const contents = app.vault.read(file)
    // Extract the summary via regex
    for (const callout of contents.match(new RegExp(regex, 'sg')) || []) {
        const match = callout.match(new RegExp(regex, 's'))
        rows.push([match[1], match[2], page.file.link])
    }
};
const rows2 = rows.slice(start, end)
const totalPages = Math.ceil(rows.length / 10);
const options = rows.slice(0, totalPages).map((_, i) => `option(${i + 1})`).join(',');
const selector = `\`INPUT[inlineSelect(${options}):page]\``;
dv.span(`Page ${selector} out of *${totalPages}*`);
const cols = ['Title', 'Content', 'Page Link'];
dv.table(cols, rows2)

obsidian.md-1715178564263.log
// You can update this to filter as you like - filtering for just your daily notes would be good
const pages = dv.pages('"Glossary"')

// This regex will find the contents of a specifically formatted callout
const regex = />\s\[\!theorem\]\s(.+?)((\n>\s.*?)*)\n/

const rows = []
for (const page of pages) {
    const file = app.vault.getAbstractFileByPath(page.file.path)
    // Read the file contents
    const contents = app.vault.read(file)
    // Extract the summary via regex
    for (const callout of contents.match(new RegExp(regex, 'sg')) || []) {
        const match = callout.match(new RegExp(regex, 's'))
        rows.push([match[1], match[2], page.file.link])
    }
}

dv.table(['Title', 'Content', 'Page Link'], rows)

obsidian.md-1715178722797.log

So neither the dataview query nor dataviewjs worked right? (the dataview query looks like it should work)
For the dataviewjs, you don't do dv.table(). You have to instead return an object with properties headers and values
const data = dv.pages().map(f => [f.file.link, f.foo]);
return {
  headers: ['file', 'foo'],
  values: data
}

Something interesting-- The same way you make a metabind plugin codeblock, you can create a dataedit codeblock from within a dataview block like this:
dv.span("```dataedit\n" +
"TABLE test, date, bool\n" +
"```"
)

Which would allow you to render other things (like metabind codeblocks or whatever you want) within the block while being able to utilize Dataedit's functionality.
The only meh thing about this approach is that after making an edit in the Dataedit table (within a dataview codeblock), editable table will still update quickly and without any flicker, but shortly after Dataview will flicker due to metadata changing (which is a known issue with Dataview and one of the reasons for Datacore being written with React).


MappingException when cypher query returns node with array field

I have a node entity that has an Integer[] for one of its fields. This works fine when using session.save() and session.load(). It breaks with a MappingException when using a cypher query. Found in 2.0.0-M02.
Here's a sample entity with an array field:
@NodeEntity
public class IntArrayHolder {

    @GraphId
    public Long id;

    public Integer[] myList;
}

This test will fail:
    @Test
    public void testPaths() {
        IntArrayHolder main = new IntArrayHolder();
        main.myList = new Integer[]{1};

        session.save(main);
        session.clear();

        Map<String, Object> params = new HashMap<>();
        session.query("match n return n", params); // Throws exception
    }

I get this stack trace:
org.neo4j.ogm.exception.MappingException: Error mapping GraphModel to instance of external.ogm.domain.IntArrayHolder
	at org.neo4j.ogm.context.GraphEntityMapper.mapEntities(GraphEntityMapper.java:145)
	at org.neo4j.ogm.context.GraphEntityMapper.map(GraphEntityMapper.java:117)
	at org.neo4j.ogm.context.RestModelMapper.mapEntity(RestModelMapper.java:153)
	at org.neo4j.ogm.context.RestModelMapper.map(RestModelMapper.java:76)
	at org.neo4j.ogm.session.delegates.ExecuteQueriesDelegate.query(ExecuteQueriesDelegate.java:98)
	at org.neo4j.ogm.session.delegates.ExecuteQueriesDelegate.query(ExecuteQueriesDelegate.java:77)
	at org.neo4j.ogm.session.Neo4jSession.query(Neo4jSession.java:313)
	at external.ogm.OgmSyntheticBugTests.testPaths(OgmSyntheticBugTests.java:108)
	...
org.neo4j.ogm.testutil.Neo4jIntegrationTestRule$1.evaluate(Neo4jIntegrationTestRule.java:78)
	at org.junit.rules.RunRules.evaluate(RunRules.java:20)
	...
Caused by: java.lang.ClassCastException: [I cannot be cast to java.lang.Iterable
	at org.neo4j.ogm.context.GraphEntityMapper.writeProperty(GraphEntityMapper.java:204)
	at org.neo4j.ogm.context.GraphEntityMapper.setProperties(GraphEntityMapper.java:177)
	at org.neo4j.ogm.context.GraphEntityMapper.mapNodes(GraphEntityMapper.java:158)
	at org.neo4j.ogm.context.GraphEntityMapper.mapEntities(GraphEntityMapper.java:142)
	... 39 more

This also happens with Long[], String[], and probably many others. If this turns out to be a bug and you're going to write a unit test, you could use https://github.com/neo4j/neo4j-ogm/blob/2.0/core/src/test/java/org/neo4j/ogm/domain/canonical/Mappable.java

@tarehart thanks for the pointer to Mappable.java :-)

@tarehart which version of the OGM are you using? I've tested all types in both 1.x and 2.x and the only problem is char/Character

@tarehart what am I missing? https://github.com/neo4j/neo4j-ogm/blob/91865a4ed966774f52d43623250fedac5994c81b/core/src/test/java/org/neo4j/ogm/persistence/examples/canonical/CanonicalTest.java

I'm not sure what the discrepancy is, maybe my dependencies are messed up somehow.
compile("org.springframework.data:spring-data-neo4j:4.1.0.M1")
testCompile(group: 'org.neo4j', name: 'neo4j-ogm', version: '1.1.5-SNAPSHOT', classifier: 'tests')
testCompile(group: 'org.neo4j.test', name: 'neo4j-harness', version: '2.3.1')

This gives me neo4j-ogm-core-2.0.0-M02.jar and neo4j-ogm-1.1.5-SNAPSHOT-tests.jar.

You shouldn't have the 1.1.5-SNAPSHOT in there. The test dependency is now called "neo4j-ogm-test", maybe that's the problem?

I'm happy to be on the right test dependency now, thanks! Unfortunately I'm still getting the same stack trace on my test (and on your test too).
The serialization is done by jackson, right? What version of that are you running?

I've realized that I'm only seeing this problem while executing tests, and my actual application works fine with arrays. There must still be something wrong with my setup. Sorry for the trouble, I hope the test you wrote isn't wasted effort.
I tried downgrading jackson to 2.5.1 and it didn't help. I also tried neo4j-harness on 2.3.1 and 2.3.2. My project dependencies are here: https://github.com/tarehart/node-stand/blob/master/build.gradle
Feel free to close this; I'll update if I figure it out.

No problem. Found an issue with character arrays, so the test was not wasted. We use jackson 2.7.1. I downgraded to your version, but that did not make a difference. The result from Neo4j would be an array, we map it to an Iterable. Keeping this issue open for a bit in case @vince-bickers knows what this could be.

@tarehart found it. It fails in tests because this is an issue with the embedded driver (which your tests are  probably using?). Will fix.

@luanne Yes, my tests use the embedded driver. Thanks Luanne!

Fixed in 2.0.0 (available in the current snapshot 2.0.0-SNAPSHOT)


docs: Explain SAML ACS url with SOCIAL_AUTH_SUBDOMAIN.

The docs weren't explaining well enough configuring the IdP for servers with multiple organizations and thus SOCIAL_AUTH_SUBDOMAIN.

Merged as the series of commits ending with 23e3ae121196b3fa3f3159af3a2feb27922939ef, thanks @mateuszmandera!


Add auth middleware

:tada: This PR is included in version 1.3.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Facebook Scraping issue

agent = Mechanize.new
agent.get 'http://mediaserver-cont-ch1-2-v4v6.pandora.com/images/public/rovi/albumart/3/2/7/3/075679453723_500W_500H.jpg - work in local and give Mechanize::Page object.
agent.get 'http://mediaserver-cont-ch1-2-v4v6.pandora.com/images/public/rovi/albumart/3/2/7/3/075679453723_500W_500H.jpg - not working in production.gives Mechanize::Image object.
Please Help me. i am stuck here.

Isn't it a JPEG image?  If so, I think it is your production environment where it is working correctly.  How does the Mechanize::Page object you obtain locally look like?  Is it a valid HTML document?  Chances are some edge servers of the CDN are responding with a broken copy of the content with the wrong content-type or something.

Going to close this until more feedback. Thanks


Add Interoperator

Pull Request Test Coverage Report for Build 2063

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 89.158%

Totals

Change from base Build 2059:
0.0%

Covered Lines:
8294

Relevant Lines:
9002

💛  - Coveralls


Replace old vscode icon to match new Visual Studio 2017

Something like

with the vscode blue color

Closing all icon issues against https://github.com/Microsoft/vscode/issues/6607


feat: generate an openapi client using the generated openapi spec.

fixed lots of the handler annotations so that a better openapi spec is generated.

@nerdalert I think it should be good now.

@chirino nice, LGTM


sexagesimal in the api

The precess package is strange because it uses sexa types in the api.  I think there might be another package or two that do this.  The motivation is commented in precess but it's outdated, referencing sexagesimal types from base when they have been moved to another package.  This is now bad to make people consult another package to understand the api.
A possible solution is to go back to float64s like most other places and just be sure documentation is clear on interpretation of the return values.
Another possible solution is to put types Angle, RA, HourAngle, and Time in base, but without all the sexagesimal support.  They would just share the same unit interpretation with the sexagesimal package.

new unit package.  sexa out of the api; it's only a test dependency now.


Security vulnerability: privilege escalation

It's possible to hijack the msctl scripts user privileges and run arbitrary commands as the user msctl is running as. E.g.
echo 'echo I can run whatever I want as `whoami`' >malicious.mscs.conf
mscs -c malicious.mscs.conf list

I don't think this is intentional and should probably be addressed.
But worse, with e.g. a weakly configured sudoers rule (e.g. allowing sudo msctl to any user), this can be even used to run arbitrary commands as an arbitrary user:
USER_NAME=root -c malicious.mscs.conf mscs list

I think the following two steps should fix this. That said, I'm by no means a shell security expert.

Do not allow injection of $USER_NAME from the environment. Always set a default value for the case $MSCS_DEFAULTS does not exist
Do not source the configuration file. Use IFS="=" read -r or another approach that does not execute the content of the config file.

Good catch. I don't think we have had anyone check for the security of this script.
We are already parsing values in ini format when we read in mscs.properties for each world. Maybe we could go that route instead of sourcing the configuration file.

This is the reason I was worried about sourcing an outside file to begin with.  I agree, the best solution going forward is probably to get rid of the defaults file and move to using the code that reads in the mscs.properties file.  Unfortunately I have neither the time nor the will to tackle such a change at this time.  For now I will recommend only using this script in controlled environments where users can be trusted to not do such hijinks.

Of course if someone were to make a pull request with the changes, I'm sure it would be accepted or worked on to make it acceptable.

I will take the time to review pull requests.  I just don't have the time to make the required change to the code and test it to verify that the changes work.
If someone submits what looks like a reasonable fix that utilizes the parsing functions already in place and tells me that it has been tested and functions, I'll probably just accept it outright.

Note that a reasonable fix must include updates to the README file, particularly the Adjusting global server settings (optional) and Configuring MSCS for multiple users (optional) sections.

I said I wouldn't work on this, but I did anyway.  Checkout the branch I just created for this patch: cd48b2de1f2a8792fec6520fbc0cf3106b4503b4.  The wiki page will still need to be updated for the new format if everything looks good.  I've done some basic tests of this code, but I would appreciate a second or third set of eyes on this.

The README file on that branch has now been updated.  I'm going to stop working on this for now.  If anyone has the opportunity to give this a test I'd be happy to hear how it goes.
I did not make any changes to stop the injection of USER_NAME to the mscs script.  That is a simple one line change if it still needs to be done.

I only took a quick look, but it seems good so far. Hopefully I can find some time to test it myself.

I'll squash this into a couple of patches, some of the changes can go directly to master.  That should make the change log easier to follow.

Good idea, will be easier to follow.
Do you think a settings converter will be needed?

I was going to take a closer look at the perl code.. it should be able to ignore lines containing comments and remove quotes around strings.  With those abilities, the format of the file will be almost the same, just missing mscs- in front of the variable names.  We could add a simple converter to the Makefile maybe.

I stripped out the old converter code when I began

I would leave it as a separate file.

Ok, I published a new branch with one commit per file.  Some of the minor changes that were in the old branch are now on master.

Nice, only 3 commits to look at. Makes it a bit easier to go over.

I made some comments directly in one of the commits.

I responded in that same commit.  I'll get a v3 out sometime later today to address the issues that have been brought up so far.
What do you think of the changes so far?  Are the variable and file name changes reasonable?  The perl code is probably case insensitive, or could be set to be.  Variables now use -  instead of _, and have mscs- tacked on the front, but we don't have to do that.  I made the change so that it would be more uniform with the other settings files.

I like that there is consistency in the settings/properties files, keeping them pre-fixed  with mscs- is good and makes it obvious to the user they are editing MSCS settings.
I also made another comment about importing the settings files on the commit.
https://github.com/MinecraftServerControl/mscs/commit/ed876b64d1b18dc9c27a769ed676e5183bfbeb99#commitcomment-17670758
I wonder if a PR would have been better since it's easier to track comments on them.

Ok, v3 is now available with a pull request.

What should we do about the user name override in the mscs script.  I'm fine with dropping it.  Is there a use case that requires it?

Since the executable defaults files are gone, I don't see how or where USER_NAME can be overridden.
Are you saying that USER_NAME=${USER_NAME:-minecraft} should be changed to USER_NAME=minecraft and similar for LOCATION?

yes, exactly

I don't see why not. LOCATION can still be overridden with mscs.defaults and the mscs file only exists for compatibility. The only thing I can think of is when a user wants to use the mscs script and change the username, but they should be able to copy or alter it.

I added commit ccf480bfc8c755a4f8fcb9f1961461a409845acd to the pull request to stop USER_NAME and LOCATION from being overridden.

I think things are looking pretty good.  As far as I can tell, the only thing to do is worry about whether or not we want to build in update function for this change into the Makefile, add an external script for the update function (perhaps in a subdirectory), or add some documentation so that people know about the change and can do the update themselves.

I would say both, but I'm not sure how hard it would be to convert the existing executable config files to the new format. Was there any other executable config file other than /etc/default/mscs?

I see that the mscs.conf got renamed to mscs.defaults for user's home directories, we probably want to add a mv for those.

Pull request #134 should finally cover this issue.  Let me know if you have the chance to give it a try.  If there are no objections, I'll merge #134 some time next week.

I went ahead and merged the v5 patch set with commit 0cefa4d601bc582e73d2a6319033d74890a7284a.  Closing this issue before it becomes 2 months old.

Thanks for updating the wiki pages @zanix

You are welcome


VS Codium

Would there be any chance to have this working on VS Codium, supposedly the same code base without the Microsoft branding and telemetry?

there is https://github.com/Pure-D/code-d, which works on VS Codium (obtain package from https://marketplace.visualstudio.com/items?itemName=webfreak.code-d)


VSCode as kubectl editor is not returning to terminal until I quit VSCode completely

On my mac Ventura in my ~/.bash_profile  I have :
export KUBE_EDITOR='open -a "Visual Studio Code" --wait'
and it is opening the new VSCode window with command on terminal:
kubectl edit pod fooapp
The problem is once I am done editing the yml and save it and close the associated VSCode window  the control is not returning to terminal.
For that I have to Quit VSCode completely.
This is very inconvenient as this is resulting in closing all my other open / work in progress files with VSCode .
Please suggest.

/kind support
/remove-kind bug

I suspect that Visual Studio Code is doing something that prevents kubectl from detecting if the window that was spawned is ever closed, and so it thinks that the edit is still in progress and you have to kill the entire VSCode process to get it to see that the window is closed. This feature was created quite a while ago and I think it expects there to be separate process or something that it can watch to stop and the way VSCode works doesn't allow for that. If these suggestions that Brian made don't work, I don't think we can accomadate how VSCode works unfortunately.
/close


Add single platform image flag

Description
Add command line flag to override platforms configuration to only build a single platform image build.

Related Issue

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):
Types of changes

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

[x] I have signed the Adobe Open Source CLA.
[ ] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[x] I have read the CONTRIBUTING document.
[ ] I have added tests to cover my changes.
[x] All new and existing tests passed.

New log message when building multi-platform builds looks like this:

Note: Building multi-platform images can take a long time, please be patient.
If you are running this locally, you can speed this up by using the '--single-platform' CLI flag or set the 'single-platform' flag in the global config file.

Message when overriding multi-platform config:
----------------------------------------------------------------- Note: Overriding multi-platform build configuration, this will only build a single-platform image. image: buildrunner-mp-build-container-multi-platform-main-11.i322946.m1697047940-1697061543 platform:linux/arm64/v8 -----------------------------------------------------------------

Updated messages:
-----------------------------------------------------------------
Note: Disabling multi-platform build, this will only build a single-platform image.
image: buildrunner-mp-build-container-multi-platform-main-11.i322946.m1697047940-1697064901 platform:linux/arm64/v8
-----------------------------------------------------------------

-----------------------------------------------------------------
Note: Building multi-platform images can take a long time, please be patient.
If you are running this locally, you can speed this up by using the '--disable-multi-platform' CLI flag or set the 'disable-multi-platform' flag in the global config file.
-----------------------------------------------------------------


[Azure.AI.Projects] Add support for Inference

Contributing to the Azure SDK
Please see our CONTRIBUTING.md if you are not familiar with contributing to this repository or have questions.
For specific information about pull request etiquette and best practices, see this section.

API change check
APIView has identified API level changes in this PR and created following API reviews.
Azure.AI.Projects


US158341 - Use new release token

The brightspace-bot and D2L_GITHUB_TOKEN are no longer needed for release workflows. Instead, we have a new D2L_RELEASE_TOKEN that has the ability to bypass the repo ruleset (configured in https://github.com/Brightspace/repo-settings/pull/1466) and org-level ruleset.
Note: This isn't available in the Brightspace org yet, but will be soon!
Before merging, I will:

Confirm the new ruleset matches the old branch protection rule before deleting it
Remove brightspace-bot as a repo contributor
Confirm the D2L_RELEASE_TOKEN is available and remove this repo's access to D2L_GITHUB_TOKEN

If you need to make a cert or hotfix, this will need to be backported to the 20.23.12 and 20.23.11 release branches.

Looking to get this in before I'm off. Reach out if you have questions/concerns!


Picker Component doesn't disable click functionality when disabled

Description
When using a screen reader the Picker component doesn't disable click functionality. Picker's own "enabled" property works correctly here.
This issue is covered in-depth by parent issue #30840, please check there for more details.
React Native version:
0.63

Picker is deprecated https://reactnative.dev/docs/picker


[Java] How do I read encrypted Parquet files using Arrow?

Describe the usage question you have. Please include as many useful details as  possible.
I want to read encrypted Parquet files using Arrow Java API to create an input stream for DuckDB.
It works for Parquet files as shown below.
import org.apache.arrow.c.ArrowArrayStream;
import org.apache.arrow.c.Data;
import org.apache.arrow.dataset.file.FileFormat;
import org.apache.arrow.dataset.file.FileSystemDatasetFactory;
import org.apache.arrow.dataset.jni.NativeMemoryPool;
import org.apache.arrow.dataset.scanner.ScanOptions;
import org.apache.arrow.dataset.scanner.Scanner;
import org.apache.arrow.dataset.source.Dataset;
import org.apache.arrow.dataset.source.DatasetFactory;
import org.apache.arrow.memory.BufferAllocator;
import org.apache.arrow.memory.RootAllocator;
import org.apache.arrow.vector.ipc.ArrowReader;
import org.duckdb.DuckDBConnection;
import java.net.URI;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.Statement;

URI uri = URI.create("file:/path/to/sample.parquet");

ScanOptions options = new ScanOptions(/*batchSize*/ 32768);
try (BufferAllocator allocator = new RootAllocator();
     ArrowArrayStream stream = ArrowArrayStream.allocateNew(allocator);
     DatasetFactory datasetFactory = new FileSystemDatasetFactory(allocator,
                     NativeMemoryPool.getDefault(), FileFormat.PARQUET, uri.toString());
     Dataset dataset = datasetFactory.finish();
     Scanner scanner = dataset.newScan(options);
     ArrowReader reader = scanner.scanBatches();) {

   Data.exportArrayStream(allocator, reader, stream);

   Class.forName("org.duckdb.DuckDBDriver");
   try (DuckDBConnection conn = (DuckDBConnection) DriverManager.getConnection("jdbc:duckdb:")) {
         conn.registerArrowStream("testStream", stream);

         try (Statement stmt = conn.createStatement();
                ResultSet rs = stmt.executeQuery("SELECT * FROM testStream")) {
                    // Do stuff with the resultset...
                }
         }
    }
}

However, I haven't found how to do it for files encrypted using Parquet modular encryption. Arrow Python documentation shows some examples, but they don't exist for Java.
Component(s)
Java

This is not yet implemented. Let me find a way to support this.

This is still a good idea, but fyi -- DuckDB has encrypted parquet support  now.


Update README.md

in the latest version,the css variable must have "bc-" prefix.
add two ways for webpack user to use less file.

thanks for this!


Update to work with current level version

Using with current levelup gives an error because db.hooks doesn't exist:
TypeError: Cannot read property 'post' of undefined
    at module.exports (/Users/nick/code/nodes/substack/level-track/index.js:8:13)

same problem here

@nichoth I installed your fork, but i get the same error.

level-sublevel doesn't seem to be necessary.
So basically, the following example code code solved it for me
changed example
var loggs = require("console-stream")
var level = require('level-browserify')
var track = require('level-track')
var hooks = require('level-hooks')

var cs = loggs()
var db = level('test.db')
hooks(db)
var tracker = track(db)
var t = tracker()

t.pipe(cs)
t.write('"c"\n')
t.write('["f","p"]\n')

setInterval(function () {
    var l = Math.floor(Math.random() * 2) + 1
    var key = ''
    for (var i = 0; i < l; i++) {
        key += String.fromCharCode(Math.random() * 26 + 97)
    }
    db.put(key, { n: Math.floor(Math.random() * 100) })
}, 250)

I wonder if level-hooks shouldn't be an "implementation detail" of level-track.
I can create a pull request to add level-hooks to level-track and update the readme with the example above if that makes sense.

Created a module level-tracker https://github.com/serapath/level-tracker
I'd appreciate feedback. It doesn't support the sincekey, but I couldn't quite wrap my head around what it's good for.


MacOS Support

It appears that only works on linux.
$ go get github.com/dobyrch/termboy-go
# github.com/dobyrch/termboy-go/inputoutput
In file included from ../../dobyrch/termboy-go/inputoutput/keyboard.go:4:
./keyboard.h:7:10: fatal error: 'linux/kd.h' file not found
#include <linux/kd.h>
         ^
1 error generated.

Yes, it uses some Linux-specific ioctl trickery to display graphics in text mode.  Unfortunately I don't have anything running OS X to tinker with.

You can use Termbox, it is cross platform.

+1 Having this issues too.

This is a shot in the dark, but it might be worth checkout out the freebsd branch.  If anyone knows more about getting this to work on a Mac I'd be happy to accept a pull request.

@dobyrch The freebsd branch did not work. I will take a look at the code on the weekend.
go build github.com/dobyrch/termboy-go
# github.com/dobyrch/termboy-go/inputoutput
In file included from inputoutput/keyboard.go:4:
./keyboard.h:7:10: fatal error: 'sys/kbio.h' file not found
#include <sys/kbio.h>
         ^
1 error generated.

Me,tooooooooooo. T_T

+1

bump


[Feature Request] Smoother compatibility with JEI/Favorite list sharing

This mod looks amazing and well organized! Only issue I have is that I lose all my favorite recipes I have from JEI when I install this. Is there a way to share the favorite list or transfer it to EMI? When I try to disable EMI on the settings, it still has JEI gone. It would be neat to either toggle between both mods rather than completely disable one.
Some items in the search index also seem to have become darkened? Most blocks and enchanted items such as potion and books have normal brightness but a lot of random things are hard to look at.

Unfortunately JEI's bookmarks and EMI's favorites cannot share with each other, you'll just have to recreate your favorites, but you'll only need to do this once. Sorry :(
In regards to EMI and JEI both being usable at the same time (say if you disable EMI), this isn't possible due to the way that JEI and EMI interact with each other.
If you have shaders they may be breaking batched item rendering. You can disable this (at a performance cost) in the config.

Yes, I was using a shader and disabling this in your config fixed the brightness problem. Thanks!


flow: Set up to use Flow enums; convert CreateWebPublicStreamPolicy

Following the guide at https://flow.org/en/docs/enums/enabling-enums/ .
There were some surprises with getting ESLint quite on board with Flow enums, and there's at least one place where I haven't yet managed to fix something it does with switch statements, noted in the commit where I convert CreateWebPublicStreamPolicy. But I think I found a good workaround for that; see there.
Apart from making our own code nicer, this should help us be more confident using Flow enums in third-party type definitions. I've been working on some where the library's TypeScript uses TS enums: expo-application and expo-screen-orientation.

The runtime values seem to be working fine; I exercised one of the switch statements on a CreateWebPublicStreamPolicy value in manual testing. Specifically, the one in EditStreamCard; on CZO, I got the message "{realmName} only allows organization owners…", which was expected with CZO's settings.

Fixed CI; in
eslint: Use new hermes-eslint parser, instead of @babel/eslint-parser

there were some (good) new ESLint errors that didn't show up in my local testing, which didn't include --all-files.

Thanks @chrisbobbe! I am also happy about how much cleaner this definition is, and the switch statements. Comments above.

Thanks for the review! Revision pushed, and I've sent a reply, above.

Thanks for the revision!
Sorry for the delay on re-reviewing it, but I've looked just now at the first three commits, and merged those as:
d84ad1203 eslint: Use better-maintained fork ("ft-flow") of "flowtyped" plugin
16d1182f4 flow-todo: Switch parser to @babel/eslint-parser, from babel-eslint
3b7608309 eslint: Use new hermes-eslint parser, instead of @babel/eslint-parser

Thanks for the review! I've just rebased atop main now that it includes those three commits; the six commits in this branch are ready for review.

Thanks for the revision!
All looks good except a small nit mentioned above. Please merge at will.

All looks good except a small nit mentioned above. Please merge at will.

Merged, after fixing that. Thanks for the review!


Use case of jasypt-spring-boot?

Sorry to ask here but I couldn't figure this out from reading the README.
I found https://github.com/ulisesbocchio/jasypt-spring-boot/issues/93 but the answer didn't completely clear things up for me.
From what I understand the use case for jasypt-spring-boot is to be able to commit secret keys in property files to the VCS.
Similar to Ansible Vault.
Otherwise I could provide the secret keys to the app through environment variables, like it is suggested for the JASYPT_ENCRYPTOR_PASSWORD, no?
Is my assessment correct or am I missing something?

Thank you, this helps me.

The encryption password env var is just one option to provide the secret that decrypts all other secrets.

In https://github.com/ulisesbocchio/jasypt-spring-boot#demo-app you describe passing the password as a system property or as an environment variable. Reading your answer I assume that there are other recommended ways to pass in the password?

@ulisesbocchio Thank you, this helps me.

The encryption password env var is just one option to provide the secret that decrypts all other secrets.

In https://github.com/ulisesbocchio/jasypt-spring-boot#demo-app you describe passing the password as a system property or as an environment variable. Reading your answer I assume that there are other recommended ways to pass in the password?

dotenv-java or spring-dotenv


Compatibility with version 6.0+ ?

Is there anything we can do to make it compatible with latest version ? It seems not recognized anymore

Textual 6 uses a different version of Webkit and compatibility will require basically a complete rewrite of the extension, this is something I plan to do but I am very busy in the new couple of months so don't expect it soon


[bug] Markers not being drawn in game

the DrawMarker native seems to no longer function in vRP2, I have even tested it on a completely brand new server with nothing but vRP2. no markers are being drawn anywhere. I believe this is related to recent FiveM updates but I have not yet been able to pinpoint the exact source of the problem

I can't reproduce the issue (updated client & server).

ok so i resolved my issue, vk_interiors is weird in that if there is an error in its config file rather then spitting out an error and stop working like most scripts it instead doesn't say a word and quietly continues to try and work despite being incorrect which results in breaking the drawmarker native for other scripts. not sure why it does this but after fixing the errors things are working correctly again. so for anyone running vk_interiors watch out for that


Docs update: the launcher is in launch/target/sbt-launch.jar

Can one of the admins verify this patch?

Thanks!


refactor(ctrlp): add core agent

Refactor the node,pool,volume agent into a single core agent.
Tidy up the Errors throughout the control plane stack allowing us to
get more concise error kinds at the rest layer and also at each agent
endpoint, which will allow us to expose the correct http responses
at the openapi spec, which will be done as another PR.

bors try

bors merge


Adding a chatbot on the landing page.

Is your feature request related to a problem? Please describe.
The user get a little confused where to go and what to do for they requirements......
Describe the solution you'd like
The chatbot will allow the user to explore the website fully.
Give the direction to user where to go and what to do after getting on landing page.
It will answer the frequently asked questions. [FAQ]
Show the best use of the website for the user.
Give Suggestions - which suits best according to user choice.
Describe alternatives you've considered
An "About us" or "FAQ" page link at landing page.
Additional context
Assign me under Gssoc'2023.

@SrishtiSonam  I would not recommend a chatbot as it would lead to inefficiency with the existing voice assistant, instead, can you provide a similar feature through react-joyride?

No as I don't have much idea about react-joyride...

Okay then I'm closing the issue


min sdkCompileSdk 34 problem

when I use [AdvancedBiometricPromptCompat] in my project  ( sdk 33)  it throw a error...
how to fix it?
And my project is already have meizu_fingerprint.jar.  which have duplicate with Flyme_fingerprint.jar in this project....
Any solution about this ? thx

The ticket looks like wrongly named, the minSDK for this library is 16 (Aka Jelly Bean)
Please check the current targetSDK/compileSDK version of your project, it seems like it lower than 34 (recommended version by Google)
Please, provide a properly oriented screenshot of the error - hard to read and understand what the problem
If you already use Flyme_fingerprint.jar, you can remove your JAR file OR exclude Meizu package from this library via "exclude" option in Gradle
Tnx