olimexino stm32 CAN errors

CAN Support Olimexino STM32
Hello,
First I'm new to Zephyr so there is a high chance that I missed something.
As far as i understand the documentation on the Olimexino stm32 there is no CAN support yet since it's not listed in supported features?

Other hardware features are not supported by the Zephyr kernel.

I tried to get the CAN sample running with the CAN Driver (1.14.0-rc2) but I just can't figure out if I'm doing something wrong in the configuration or if it's just not supported.
My proj.conf has the following settings:

CONFIG_CAN=y
CONFIG_CAN_STM32=y
CONFIG_CAN_INIT_PRIORITY=80
CONFIG_CAN_1=y
CONFIG_CAN_MAX_FILTER=5

I use cmake like:

cmake -GNinja -DBOARD=olimexino_stm32 ..

If I'm trying to compile the sample CAN code with ninja i get many errors like the following:

drivers/can/stm32_can.c:855:24: error: 'DT_CAN_1_BASE_ADDRESS' undeclared here (not in a function); did you mean 'DT_SPI_1_BASE_ADDRESS'?

I figured out that the olimexino_stm32 uses the stm32f103XX soc which has no CAN configuration at all compared to the stm32F03XX in the "dts_fixup.h" file. Also in the "pinmux.c" file of the olimexino_stm32 board there are no pins configured for CAN-RX/TX.
My Question is if there is already CAN support for the olimexino_stm32 before I continue trying to get it to work?

@SebastianStumm DT_CAN_1_BASE_ADDRESS is the macro required by CAN that is supposed to be generated by Device Tree. If this board doesn't have DT nodes defined for CAN then they need to be added.

Welcome to Zephyr @SebastianStumm !
We didn't add CAN support for the olimexino board so far. You can add the CAN controller to the dts for the stm32f103 series and configure the pins (PB8 as CANrx and PB9 as CANtx) in pinmux of the olimexino board. Basically the stm32 CAN driver should work for the stm32f1 series.
Don't forget to turn off the loopback mode when connecting two boards. Otherwise you won't see any messages on the bus.
If it works, pleas submit a PR so we can add the board to the list of supported CAN boards.

Hy @SebastianStumm!
How are you doing with the CAN on the olimexino?
I just created a PR for another board (#15209). You can see there how to bring up CAN on a board.

Hi,
First of all thank you alot for the help and feedback !
I did add the controller but did not submit a pr yet because it does not fully work currently. I took a look at your example with the nucleo_f746zg and I basicly already did the same configuration with some minor changes due the lack of alternate function registers of the stm321f03.
1. stm32f103Xb.dtsi under soc
can1: can@40006400 {
	compatible = "st,stm32-can";
	#address-cells = <1>;
	#size-cells = <0>;
	reg = <0x40006400 0x400>;
	interrupts = <19 0>, <20 0>, <21 0>, <22 0>;
	interrupt-names = "TX", "RX0", "RX1", "SCE";
	clocks = <&rcc STM32_CLOCK_BUS_APB1 0x02000000>;
	status = "disabled";
	label = "CAN_1";
};

2. olimexino_stm32.dts
&can1 {
	bus-speed = <125000>;
	sjw = <1>;
	prop_seg_phase_seg1 = <6>;
	phase_seg2 = <5>;
	status = "ok";
};

3. pinmux.c (in the olimex_stm32 folder)
#ifdef CONFIG_CAN_1
	{STM32_PIN_PB8, STM32F1_PINMUX_FUNC_PB8_CAN_RX},
	{STM32_PIN_PB9, STM32F1_PINMUX_FUNC_PB9_CAN_TX},
#endif /* CONFIG_CAN_1 */

4. pinxmus_stm32f1.h
#define STM32F1_PINMUX_FUNC_PB9_CAN_TX			 STM32_PIN_CAN_TX
#define STM32F1_PINMUX_FUNC_PB8_CAN_RX 			 STM32_PIN_CAN_RX

5. stm32-pinctrlf1.h
#define STM32_PIN_CAN_TX        (STM32_MODE_OUTPUT | STM32_CNF_ALT_FUNC | STM32_CNF_PUSH_PULL | STM32_PUPD_PULL_UP)
#define STM32_PIN_CAN_RX        (STM32_MODE_INPUT | STM32_CNF_IN_FLOAT)

6. dts-fixup.h
#define DT_CAN_1_BASE_ADDRESS		DT_ST_STM32_CAN_40006400_BASE_ADDRESS
#define DT_CAN_1_BUS_SPEED		DT_ST_STM32_CAN_40006400_BUS_SPEED
#define DT_CAN_1_NAME			DT_ST_STM32_CAN_40006400_LABEL
#define DT_CAN_1_IRQ_TX			DT_ST_STM32_CAN_40006400_IRQ_TX
#define DT_CAN_1_IRQ_RX0		DT_ST_STM32_CAN_40006400_IRQ_RX0
#define DT_CAN_1_IRQ_RX1		DT_ST_STM32_CAN_40006400_IRQ_RX1
#define DT_CAN_1_IRQ_SCE		DT_ST_STM32_CAN_40006400_IRQ_SCE
#define DT_CAN_1_IRQ_PRIORITY		DT_ST_STM32_CAN_40006400_IRQ_0_PRIORITY
#define DT_CAN_1_SJW			DT_ST_STM32_CAN_40006400_SJW
#define DT_CAN_1_PROP_SEG_PHASE_SEG1	DT_ST_STM32_CAN_40006400_PROP_SEG_PHASE_SEG1
#define DT_CAN_1_PHASE_SEG2		DT_ST_STM32_CAN_40006400_PHASE_SEG2
#define DT_CAN_1_CLOCK_BUS		DT_ST_STM32_CAN_40006400_CLOCK_BUS
#define DT_CAN_1_CLOCK_BITS		DT_ST_STM32_CAN_40006400_CLOCK_BITS

The CAN sample compiles and flashes now without any errors.
But the sample behaves not as expected.
When reseting the board I get the sample loaded without any problems and the output (from putty) looks like this:

▒***** Booting Zephyr OS v1.14.0-rc3-128-ged139948a54b *****
Finished init. waiting for Interrupts
TX thread is running.
filter id: 1

But when I press the user button the sample does not behave as expected. Occasionally some messages are transmitted but they don't correspond to the amount of button clicks. Sometimes there are 8-10 messages from a single button click, sometimes a single message from multiple button clicks and most of the times no messages at all.
So by now I dug into the stm32f103xx reference manual and found a section under the General-purpose and alternate-function I/Os (GPIOs and AFIOs) registers that states that CAN is by default not mapped to PB8&PB9 but PA11&PA12. So without any change PB8&PB9 are by default set to TIM4_CH3&TIM4_CH4.
I do not know if the unexpected behaviour is rooted in me misconfiguring the CAN controller or if I need to remap the pins first. And if so how do I achieve this within zephyr? I found the following in stm321fxx_ll_gpio.h:
#if defined(AFIO_MAPR_CAN_REMAP_REMAP1)

/**
  * @brief Enable or disable the remapping of CAN alternate function CAN_RX and CAN_TX in devices with a single CAN interface.
  * @rmtoll MAPR          CAN_REMAP           LL_GPIO_AF_RemapPartial1_CAN1
  * @note  CASE 1: CAN_RX mapped to PA11, CAN_TX mapped to PA12
  * @retval None
  */
__STATIC_INLINE void LL_GPIO_AF_RemapPartial1_CAN1(void)
{
  CLEAR_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP);
  SET_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP_REMAP1);
}

/**
  * @brief Enable or disable the remapping of CAN alternate function CAN_RX and CAN_TX in devices with a single CAN interface.
  * @rmtoll MAPR          CAN_REMAP           LL_GPIO_AF_RemapPartial2_CAN1
  * @note  CASE 2: CAN_RX mapped to PB8,  CAN_TX mapped to PB9 (not available on 36-pin package)
  * @retval None
  */
__STATIC_INLINE void LL_GPIO_AF_RemapPartial2_CAN1(void)
{
  CLEAR_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP);
  SET_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP_REMAP2);
}

/**
  * @brief Enable or disable the remapping of CAN alternate function CAN_RX and CAN_TX in devices with a single CAN interface.
  * @rmtoll MAPR          CAN_REMAP           LL_GPIO_AF_RemapPartial3_CAN1
  * @note  CASE 3: CAN_RX mapped to PD0,  CAN_TX mapped to PD1
  * @retval None
  */
__STATIC_INLINE void LL_GPIO_AF_RemapPartial3_CAN1(void)
{
  CLEAR_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP);
  SET_BIT(AFIO->MAPR, AFIO_MAPR_CAN_REMAP_REMAP3);
}
#endif

and similar code in the sm32f1xx_hal_gpio_ex.h
From this I see that there is a possibility to remap the CAN alternate function but I could not figure out where and how to call the remap function. Therefor i could not test if this causes the problem. I also noticed that all the jumpers on the board are smd and therefor the CAN-Bus (CAN_T JMPR) is not terminated but I guess this should not cause any problems in loopback mode?
So my questions are first of all if the configuration of the CAN controller is correct and if so how to remap in zephyr?
Thanks in advance & best regards
Sebastian

@SebastianStumm can you try calling
LL_GPIO_AF_RemapPartial2_CAN1();

in zephyr/boards/arm/olimexino_stm32/pinmux.c after
stm32_setup_pins(pinconf, ARRAY_SIZE(pinconf));

The phenomenon of sending more than one frame could also be a result of bouncing user button.
Enable Asserts and debug log of the CAN driver in menuconfig. Maybe something is wrong with the BS1 and BS2 config, for example the prescaler is not a real number.

If I try to call the remap function it's undeclared.

undefined reference to `LL_GPIO_AF_RemapPartial2_CAN1'

If I inlcude the the header file it does compile
#include <stm32f1xx_ll_gpio.h>

It did not change anything in the behaviour of the sample.
I enabled debug log for CAN, could not find a way to turn on assertion for CAN specificly just globally.
CONFIG_LOG=y
CONFIG_CAN_LOG_LEVEL_DBG=y
CONFIG_ASSERT=y

My output before pressing the user button now is:
▒***** Booting Zephyr OS v1.14.0-rc3-128-ged139948a54b *****
Finished init. waiting for Interrupts
TX thread is running.
filter id: 1
[00:00:00.000,000] <dbg> stm32_can.can_stm32_runtime_configure: Runtime configure of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.config_can_1_irq: Enable CAN1 IRQ
[00:00:00.000,000] <inf> stm32_can: Init of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.can_stm32_runtime_configure: Runtime configure of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x1, mask: 0x7ff
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID without mask (1)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x10, mask: 0x7ff
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID without mask (1)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 1 (index 1)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x12345, mask: 0x1fffffff
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: extended ID without mask (3)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 4 (index 4)

After I press the button it does drop a lot of messages for just pressing the button once or twice. Also it does not stop and randomly drops messages and "presses" the button by itself without any interaction from my part.
Button pressed! Send message 1
Button pressed 1 times
Button pressed! Send message 0
[00:01Button pressed 2 times
:11.83String sent over CAN
0,000] <dbg> stm32_can.can_stm32_send: Sending 1 bytes on CAN_1. Id: 0x10, ID type: standard, Remote Frame: no
[00:01:11.830,000] utton pressed! Send message 1
[0m<dbButton pressed 3 times
g> stm32_can.can_stm32_send: Using mailbox 0
--- 1 messages dropped ---
[00:01:11.830,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:0Button pressed! Send message 0
1:11.8Button pressed 4 times
30,00String sent over CAN
0] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 1
--- 13 messages dropped ---
[00:01:11.850,000]Button pressed! Send message 1
 <Button pressed 5 times
dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
--- 5 messages dropped ---
[00:01:11.870,000] <dbg> stm32_can.can_stm32_send: Using Button pressed! Send message 0
mailboButton pressed 6 times
x 1
   tring sent over CAN
0m
--- 14 messages dropped ---
Button pressed!  Send message 0
m<dbg>Button pressed 8 times
 stm3String sent over CAN
2_can.can_stm32_rx_isr_handler: Message on filter index 1
--- 13 messages dropped ---
[00:01:11.930,000] <dbg> stm32_cButton pressed!  Send message 0
0:01:1Button pressed 10 times
1.950String sent over CAN
,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 1
--- 13 messages dropped ---
[00:01:11.970,0Button pressed! Send message 1
00] utton pressed 11 times
0m<dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
--- 5 messages dropped ---
[00:01:11.990,000] <dbg> stm32_can.can_stm32_send: UButton pressed! Send message 0
sing mButton pressed 12 times
ailboString sent over CAN
x 1
--- 14 messages dropped ---
[00:01:12.010,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter indexButton pressed! Send message 1
 4Button pressed 13 times

--- 5 messages dropped ---
[00:01:12.030,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:01:12.030,000] <dbg> stm32_can.can_stm32_rx_iButton pressed! Send message 0
sr_hanButton pressed 14 times
dler:String sent over CAN
 Message on filter index 1
--- 13 messages dropped ---
[00:01:12.050,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Button pressed! Send message 1
MessagButton pressed 15 times
e on filter index 4
--- 5 messages dropped ---
[00:01:12.070,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:01:12.070,000] <dbg> stButton pressed! Send message 0
m32_caButton pressed 16 times
n.canString sent over CAN
_stm32_rx_isr_handler: Message on filter index 1
--- 13 messages dropped ---
[00:01:12.090,000] <dbg> stm32_can.canButton pressed!  Send message 0
110,00Button pressed 18 times
0]
   tring sent over CAN
0m<dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 1
--- 13 messages dropped ---
[00:01:12.130,000] utton pressed!  Send message 0
box 1utton pressed 20 times
[0m
String sent over CAN
--- 12 messages dropped ---
[00:01:12.170,000] <dbg> stm32_can.can_stm32_send: Using mailbox 2
--- 1 messButton pressed! Send message 1
ages dButton pressed 21 times
ropped ---
[00:01:12.190,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
--- 6 messages dropped ---
[00:01:12.190,000] <dbg> stm32_can.can_stmButton pressed! Send message 0
32_rx_Button pressed 22 times
isr_hString sent over CAN
andler: Message on filter index 1
--- 13 messages dropped ---
[00:01:12.210,000] <dbg> stm32_can.can_stm32_rx_isr_Button pressed!  Id: 0x10, ID type: standard, Remote Frame: no
[00:01:12.250,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:01:12.250,000] <dbg> stm32_can.can_stm32_send: Sending 2 bytes on CAN_1. Id: 0x1, ID type: standard, Remote Frame: no
[00:01:12.250,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:01:12.250,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 1
[00:01:12.2Button pressed! Send message 0
50,000Button pressed 24 times
]
........... and so on

@SebastianStumm The logg looks good actually. Except it doesn't stop sending. I think this behavior is not related to the CAN driver. Can you run the test cases? The location is zephyr/tests/drivers/can/api/.
You can build and flash them with logging enabled. If you see SUCCESS at the end, everything is fine.

@alexanderwachter I also don't think it's the CAN driver. I ran the tests with the following result:
▒[00:00:00.000,000] <dbg> stm32_can.can_stm32_runtime_configure: Runtime configure of CAN_1 done
--- 42 messages dropped ---
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_detach: Detatch filter number 0 (index 0), type 2
[00:00:00.000,000] <dbg> stm32_can.can_stm32_detach: Bank number 0 is empty -> deakivate
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x555, mask: 0x7f0
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID with mask (0)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_detach: Detatch filter number 0 (index 0), type 0
[00:00:00.000,000] <dbg> stm32_can.can_stm32_detach: Bank number 0 is empty -> deakivate
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x15555555, mask: 0x1ffffff0
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: extended ID with mask (2)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
--- 45 messages dropped ---
[00:00:00.110,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
--- 29 messages dropped ---
[00:00:00.120,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 0
[00:00:00.120,000] <dbg> stm32_can.can_stm32_detach: Detatch filter number 0 (index 0), type 2
[00:00:00.120,000] <dbg> stm32_can.can_stm32_detach: Bank number 0 is empty -> deakivate
[00:00:00.120,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x1555555a, ID type: extended, Remote Frame: no
[00:00:00.120,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x15555555, mask: 0x1ffffff0
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: extended ID with mask (2)
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.120,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 0
[00:00:00.120,000] <dbg> stm32_can.can_stm32_detach: Detatch filter number 0 (index 0), type 2
[00:00:00.120,000] <dbg> stm32_can.can_stm32_detach: Bank number 0 is empty -> deakivate
--- 1 messages dropped ---
===================================================================
starting test - test_send_receive_wrong_id
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x555, mask: 0x7ff
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID without mask (1)
[00:00:00.120,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.120,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x55a, ID type: standard, Remote Frame: no
[00:00:00.120,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:00.230,000] <dbg> stm32_can.can_stm32_detach: Detatch filter number 0 (index 0), type 1
[00:00:00.230,000] <dbg> stm32_can.can_stm32_detach: Bank number 0 is empty -> deakivate
PASS - test_send_receive_wrong_id
===================================================================
Test suite can_driver succeeded
===================================================================
**PROJECT EXECUTION SUCCESSFUL**

I also modified the sample by adding a work thread which sends "Hallo Welt" each 5 seconds and this seems to work just fine. So I assume the problem lays outside of the can driver itself, maybe the gpio/user-button.
▒***** Booting Zephyr OS v1.14.0-rc3-128-ged139948a54b *****
Finished init. waiting for Interrupts
TX thread is running.
filter id: 1
[00:00:00.000,000] <dbg> stm32_can.can_stm32_runtime_configure: Runtime configure of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.config_can_1_irq: Enable CAN1 IRQ
[00:00:00.000,000] <inf> stm32_can: Init of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.can_stm32_runtime_configure: Runtime configure of CAN_1 done
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x1, mask: 0x7ff
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID without mask (1)
[00:00:00.000,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 0 (index 0)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x10, mask: 0x7ff
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: standard ID without mask (1)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 1 (index 1)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Setting filter ID: 0x12345, mask: 0x1fffffff
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter type: extended ID without mask (3)
[00:00:00.010,000] <dbg> stm32_can.can_stm32_set_filter: Filter set! Filter number: 4 (index 4)
Sending ...
Hallo Welt
[00:00:05.000,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:05.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:05.000,000] <dbg> stm32_can.can_stm32_send: Sending 3 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:05.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:00:05.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
[00:00:05.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
Sending ...
Hallo Welt
[00:00:10.000,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:10.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:10.000,000] <dbg> stm32_can.can_stm32_send: Sending 3 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:10.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:00:10.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
[00:00:10.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
Sending ...
Hallo Welt
[00:00:15.000,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:15.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:15.000,000] <dbg> stm32_can.can_stm32_send: Sending 3 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:15.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:00:15.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
[00:00:15.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
Sending ...
Hallo Welt
[00:00:20.000,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:20.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:20.000,000] <dbg> stm32_can.can_stm32_send: Sending 3 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:20.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:00:20.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
[00:00:20.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
Sending ...
Hallo Welt
[00:00:25.000,000] <dbg> stm32_can.can_stm32_send: Sending 8 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:25.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 0
[00:00:25.000,000] <dbg> stm32_can.can_stm32_send: Sending 3 bytes on CAN_1. Id: 0x12345, ID type: extended, Remote Frame: no
[00:00:25.000,000] <dbg> stm32_can.can_stm32_send: Using mailbox 1
[00:00:25.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4
[00:00:25.000,000] <dbg> stm32_can.can_stm32_rx_isr_handler: Message on filter index 4

Should I do a pr now for the CAN controller or try to figure out why it's dropping messages when using the user button first?

Should I do a pr now for the CAN controller or try to figure out why it's dropping messages when using the user button first?

Go for it!
If you have time to figure it out you can do that but as long as the CAN driver works, I'm fine with it.

@lucaspeixotot Did you use CAN1 and CAN2 concurrently?

@SebastianStumm @lucaspeixotot can you guys review #13262? Also please leave some comments about feature requests and general thoughts about the API.

Think this has been settled.


Integration with DRF

Hello.
My project uses Django Admin and Django Rest Framework.
I set the flag AXES_REST_FRAMEWORK_ACTIVE to true.
And I got the library exception, when I logged in Django admin.

AttributeError at /admin/login/
Exception Type: 	AttributeError
Exception Value: 	'WSGIRequest' object has no attribute 'data'
Exception Location: 	/lib/python3.6/site-packages/axes/helpers.py in get_client_username, line 147

Thank you for your work!

Thanks, good catch! Upstreaming the proposed change.

@I0x4dI your PR is now released in 5.3.0 on PyPI :)


Code Inspection: npm audit on swagger

lodash:<4.17.12

(error) Prototype Pollution Update to version 4.17.12 or later. - CVE-2019-10744

lodash:4.17.11:

@atomist/automation-client>graphql-code-generator>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-code-generator>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-client>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-client>graphql-codegen-plugin-helpers>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-client>graphql-codegen-typescript-common>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-client>graphql-codegen-typescript-common>graphql-codegen-plugin-helpers>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-common>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-common>graphql-codegen-plugin-helpers>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-server>graphql-codegen-typescript-common>graphql-codegen-core>graphql-toolkit>lodash
@atomist/automation-client>graphql-codegen-typescript-server>graphql-codegen-typescript-common>graphql-codegen-plugin-helpers>graphql-codegen-core>graphql-toolkit>lodash

marked:>=0.3.14 <0.6.2

(warn) Regular Expression Denial of Service Upgrade to version 0.6.2 or later.

marked:0.4.0:

typedoc>marked

[atomist:code-inspection:swagger=@atomist/atomist-sdm]

Issue closed because branch swagger was deleted.

Issue closed because branch swagger was deleted.


When I add a build step and it generates dist files, these are not uploaded with delta settings.

First of all this is the best action I have found so far, especially because of the delta option it is great.
The following is my workflow.
on: push
name: 🚀 Deploy on on teampro New new
jobs:
  deploy-master:
    name: "Deploy on on teampro New new "
    runs-on: ubuntu-latest
    timeout-minutes: 30
    steps:
      - name: Checkout Repository
        uses: actions/checkout@v4
        with:
          fetch-depth: 0

      - name: 🔨 Build Project
        run: |
          cd todo/teamprotodo_vue/
          npm install
          npm run build
      - name: Deploy Files
        uses: milanmk/actions-file-deployer@master
        with:
          remote-protocol: "sftp"
          remote-host: ${{ secrets.DEPLOY_HOST }}
          remote-user: ${{ secrets.DEPLOY_USER }}
          ssh-private-key: ${{ secrets.DEPLOY_PRIVATE_KEY }}
          remote-path: "/home/bitnami/htdocs/teampro/new2"

You will notice I have added a build step.
But the files which are generated from the build are not uploaded probably due to the fact that it finds the difference or changed files later.
Is there a provision for this which I might of missed, if so please guide me.
I need to upload todo/teamprotodo_vue/dist whenever the project is built.
Thanks for the library, Have a nice day.

I have added a pull request to fix this issue.
#42

Hi! I have the same issue. Could you please help with solution? Thanks


Remove swfitlint rule no_extension_access_modifier

Allows access levels for extensions. Should be merged with together with https://github.com/JamitLabs/ProjLintTemplates/pull/5

Thanks @JensK611! 🎉


feat(pwa): refactor pwa module

This PR includes:

update pwa logic removing extra hash computations
use pwa plugin integration entry to configure service worker and webmanifest base/scope properly
remove webmanifest regeneration from ssg hook
configure sw precache manifest properly using prettyUrls option
if sw navigation fallback is not configured when using generateSW strategy, use 404 or 404.html  (using prettyUrls configuration options) as default navigation fallback if present or base if 404 not found.
fix importModules on Windows: check changes on packages/iles/src/node/modules.ts
update pwa plugin to latest

Looks great, love the 404 improvements, thanks Joaquín!


updating e2e ami

Issue #, if available:
Description of changes:
Updating e2e ami
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

/approve

/approve


Replacing init in doc.go as a Register method

Is your feature request related to a problem? Please describe.
As for it would be easier to register swagger by myself through a direct import
Describe the solution you'd like
Replacing init with Register method
Describe alternatives you've considered
Adding a configuration (by default keep init) else self register

@Ferrany1 that's a great idea but we can't break compatibility.
This may be a feature to add maybe in v2.x.x.

Cant it be configured thorough a cli for now? (to not break current usages?)

I'm looking at the pr you make and I'm not sure what exactly do you want to accomplish.
I've understood the fact you may like to have 2 swagger docs in the same packages. Still not sure what is wrong with init func () ?

@ubogdan No, I want to have 1 doc file and make a direct call for register to handle error and get doc name to handle in ReadDoc later while using my middleware.
As for me init func is worse, because I can't control it, also direct import > blank import as injection

@ubogdan No, I want to have 1 doc file and make a direct call for register to handle error and get doc name to handle in ReadDoc later while using my middleware.

So then why are u naming the files by instance name ?

Because in my case I have different microservices stored in monorepo and all documentation stored in doc folder, so in this case each doc will overwrite previous, that's why instance name may be necessary in monorepo cases

The init method allows you to register multiple instance names. Why can't you use that?

I want to get instance name as a string as well to pass to handler for ReadDoc method

Okay, but we can introduce breaking changes.
As you may see this repo has 5k followers, you can imagine there are over 5k projects depending on it.

But right now I'm not proposing to break contract, just to make option to make a modification

It's up to user now handle error or not, this won't break any current repos

If you look closer, the same pattern was used by the SQL drivers. See MySQL implementation func init() {
sql.Register("mysql", &MySQLDriver{})
}
That's been said, the Register method signature cannot be changed and the init method will not be removed.
Please figure out a different way to implement this.
Documentation that was generated with an older version of swagger will stop compiling after a library update because you changed the Register function signature. This is called a breaking change and we can't accept it.


Use of deprecated set-output triggers warnings during workflow.

Is there an existing issue for this?

[X] I have searched the existing issues

Does this issue exist in the latest version?

[X] I'm using the latest release

Describe the bug?
There are still parts of the code using the deprecated variable declaration set-output, which triggers:
The set-output command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
To Reproduce

Add a step in your workflow using: uses<EMAIL_ADDRESS>Observe the Github Actions log

What OS are you seeing the problem on?
ubuntu-latest or ubuntu-20.04
Expected behavior?
That no warning pops up.
Relevant log output
No response
Anything else?
A similar issue was reported here https://github.com/tj-actions/branch-names/issues/180, but it seems that it has not yet been solved.
Code of Conduct

[X] I agree to follow this project's Code of Conduct

@matiasmuller7 This has already been resolved if you are using a self hosted runner be sure to upgrade if you need t.


 Don't use site builders like wix or wordpress, everything else will be fine. Host your website on gh pages and comment down the link

https://shivhek25.github.io

https://archies11.github.io/MyWebsite/

For some reason gh pages was giving error.
https://viu.netlify.com/

https://suneetkumar19.github.io/Color-Game/

https://agamjotpanesar.github.io/TicTacToe/

https://sourabh1031.github.io/sourabhpruthi.github.io/

I also had a backend so I uploaded the website on my hosted server:
Here is the live link :https://truetricks.com/todo/index.php
Why this app?

Trust issues with other 3rd party todo list apps :P

For some reasons gh pages was giving error : - https://priceless-tesla-ba2383.netlify.com/

https://anuj-mittal.github.io/


Provide daily Windows binaries for client with AppVeyor

[x] now build artifacts can be downloaded - https://ci.appveyor.com/project/lxc/lxd/build/artifacts
[x] open the gate for Windows users

I planned to enable junit test reporting, but because there is no tee on Windows, it requires some non-obvious hacks to get both real-time screen output and nice counter on test tab (see https://github.com/golang/go/issues/17542 for details). Maybe later.
This is ready to be merged.

Any chance you can squash all of this into one or two commits?
That makes cherry-picking into the stable branch quite a bit easier :)

From one side it is nice to see elevation of pain for future researchers in devops usability. From the other, nobody is going discover this, so.. sure. =)

Reduced to 5 logical chunks from 13. I suppose you want to merge only few features from the set for now.


Upgrade istio Api and migrate to v1beta1 Api version

What this PR does / why we need it:
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #3153
Type of changes
Please delete options that are not relevant.

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

Feature/Issue validation/testing:
Please describe the tests that you ran to verify your changes and relevant result summary. Provide instructions so it can be reproduced.
Please also list any relevant details for your test configuration.

[ ] Test A

[ ] Test B

Logs

Special notes for your reviewer:

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

Checklist:

[ ] Have you added unit/e2e tests that prove your fix is effective or that this feature works?
[ ] Has code been commented, particularly in hard-to-understand areas?
[ ] Have you made corresponding changes to the documentation?

Release note:

/lgtm
/approve


Cooked Venison Chops chopping duplication

Describe the bug: Cooked Venison Chops duplicate via Chopping.
To Reproduce: Acquire Cooked Venison Chops, and chop them on the cutting board, repeat as desired
Expected behavior: Cooked Venison Chops cutting board recipe to use "item": {delightful:cooked_venison}, not "tag": {delightful:cooked_venison}
Screenshots: https://cdn.discordapp.com/attachments/999310127645589565/1043627687312375908/2022-11-19_12.41.08.png
Versions:
Delightful-1.19-3.1.3
FarmersDelight-1.19-1.2.0
Forge-43.1.43

Fixed in v3.1.4
Will have a better solution soon


Use naming consistent with akka-http

As discussed in #17

Added proper package directories under main/scala
Deprecated HttpMeterMetricsin favor of MeterDirectives
Deprecated HttpTimerMetricsin favor of TimerDirectives
Deprecated recently added StatusCodeMetrics in favor of well-named StatusCodeCounterDirectives

This looks good aside from needing that deprecation. I can get 0.6.0 released today with that.

@adamdecaf it would be great to have 0.6.0, thanks.

@notxcain 0.6.0 has been pushed, can you try it out? https://github.com/Backline/akka-http-metrics/tree/0.6.0
Also, I deleted the deprecated traits/methods in https://github.com/Backline/akka-http-metrics/commit/a7cfb2d1045a731cf93e98fb35e1a3ef8ece88b2 is that what you were thinking?
The tree now looks pretty clean, thanks again! https://github.com/Backline/akka-http-metrics/tree/master/src/main/scala/backline/http/metrics


error: Not an editor command: scriptversion 3

When launching vim with this plugin, I get the following error:
E492: Not an editor command: scriptversion 3

I am using SpaceVim on a Mac with Alacritty.

I won't support SpaceVim.


Exception when using plugin_reconfigure

Describe the bug
When calling the plugin_reconfigure() method of this plugin from Fledge, either an "Invalid argument" exception or a deadlock will occur.
To Reproduce
Steps to reproduce the behavior:

Start Fledge with an HNZ south plugin.
Enable the HNZ south plugin.
Change the configuration of the HNZ south plugin (edit one value in Protocol stack).
Notice that the configuration never sompletes or raises an exception.

Expected behavior
Reconfiguration works as inteded on this plugin.
Additional context
N/A

Analysis
After comparing the implementation of the plugin_reconfigure() method with the one from other plugins, it appears that the Fledge interface was not matched: The handle parameter in this method is actually a PLUGIN_HANDLE* and not a PLUGIN_HANDLE (as it is the case for other methods of the south plugin API, see https://github.com/fledge-iot/fledge/issues/1069)


perlPackages.CryptDES: fix build with gcc14

See the discussion at https://rt.cpan.org/Public/Bug/Display.html?id=133363.
The patch has to be copied to nixpkgs manually, because automatic download with fetchpatch results in empty file (perhaps some form of DDoS protection).

Things done

Built on platform(s)

[x] x86_64-linux
[x] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

Interesting - the number of rebuilds is not that high as I thought. This could probably go to master as well. nixpkgs-review told me about several thousands of packages. I probably misread the output.

I think this will hopefully fix smokeping failing to build since https://github.com/NixOS/nixpkgs/pull/356812.
nixpkgs-review is behaving a bit oddly for me, but nixpkgs-review rev HEAD -b nixos-unstable appears to have successfully finished:
nixpkgs-review result
Generated using nixpkgs-review.
Command: nixpkgs-review

x86_64-linux

:white_check_mark: 52 packages built:

fusionInventory
glpi-agent
ikiwiki
ikiwiki-full
lanraragi
munin
nagiosPlugins.check_nwc_health
nagiosPlugins.check_ups_health
nagiosPlugins.manubulon-snmp-plugins
ocsinventory-agent
ocsinventory-agent.devdoc
perl538Packages.AltCryptRSABigInt
perl538Packages.AltCryptRSABigInt.devdoc
perl538Packages.AuthenPassphrase
perl538Packages.AuthenPassphrase.devdoc
perl538Packages.CatalystControllerHTMLFormFu
perl538Packages.CatalystControllerHTMLFormFu.devdoc
perl538Packages.CryptDES
perl538Packages.CryptDES.devdoc
perl538Packages.CryptDES_EDE3
perl538Packages.CryptDES_EDE3.devdoc
perl538Packages.CryptOpenPGP
perl538Packages.CryptOpenPGP.devdoc
perl538Packages.HTMLFormFuMultiForm
perl538Packages.HTMLFormFuMultiForm.devdoc
perl538Packages.NetSNMP
perl538Packages.NetSNMP.devdoc
perl538Packages.TaskCatalystTutorial
perl538Packages.TaskCatalystTutorial.devdoc
perl538Packages.TieEncryptedHash
perl538Packages.TieEncryptedHash.devdoc
perl540Packages.AltCryptRSABigInt
perl540Packages.AltCryptRSABigInt.devdoc
perl540Packages.AuthenPassphrase
perl540Packages.AuthenPassphrase.devdoc
perl540Packages.CatalystControllerHTMLFormFu
perl540Packages.CatalystControllerHTMLFormFu.devdoc
perl540Packages.CryptDES
perl540Packages.CryptDES.devdoc
perl540Packages.CryptDES_EDE3
perl540Packages.CryptDES_EDE3.devdoc
perl540Packages.CryptOpenPGP
perl540Packages.CryptOpenPGP.devdoc
perl540Packages.HTMLFormFuMultiForm
perl540Packages.HTMLFormFuMultiForm.devdoc
perl540Packages.NetSNMP
perl540Packages.NetSNMP.devdoc
perl540Packages.TaskCatalystTutorial
perl540Packages.TaskCatalystTutorial.devdoc
perl540Packages.TieEncryptedHash
perl540Packages.TieEncryptedHash.devdoc
smokeping


Update base image

failed to build docker image with mhart/alpine-node:4.4.7

Thanks. we'll need to rebuild the containers manually as we dont have a build pipeline for that yet /cc @enxebre


SWN Revised v2.4.0

A few bug/typo fixes bundled with a major update to support a new supplement, Codex of the Black Sun.
No changes to basic functional aesthetics.
All old attributes preserved, just adding new ones.

This PR have conflicts now

Conflicts are in the rendered HTML, source code merges fine. I've incorporated the conflicting changes into the source code, rendered, and marked resolved.

Damn that was quick, great job!

Noticed the other PR yesterday. Once you said "conflicts" I knew right away what it was and how to fix it.


Question: filter null values in map, returning keys

Hi,
Been playing around with the library, but I can't seem to get my head around the following (kind of new to fp):
Map<String, String> = new Map<String, String>{
    'Name' => 'Account',
    'Description' => null,
    'Website' => null
}

Is it possible to only retrieve the keys where the value is null?

It doesn't seem like any of the functions is providing this kind of functionality, so I ended up with this custom FilterByValueFunc which you can append to the .filter(Func prep) method.
public class FilterByValueFunc extends Func {

        public FilterByValueFunc() {
            super(3);
        }

        public override Object exec(Object a, Object b, Object c) {
            Object value = (Object)a;
//            Object key = (Object)b;
            Object testValue = (Object)c;
            return value == testValue;
        }
    }

Or is there a simpler way to achive this? :)

Thanks for your suggestion. There is indeed a simpler way to achieve this already in R.apex. Please check below:
Map<String, String> m = new Map<String, String>{
    'Name' => 'Account',
    'Description' => null,
    'Website' => null
};

R.of(m)
    .filter(R.isNotNull)
    .keys()
    .debug();

Or you can choose a more functional way like this:
Map<String, String> m = new Map<String, String>{
    'Name' => 'Account',
    'Description' => null,
    'Website' => null
};

Func f = (Func)R.pipe.run(
    R.filter.apply(R.isNotNull),
    R.keys
);

System.debug(f.run(m));

The thing here is that many functions in R.apex is polymorphic in that they accept multiple types of arguments. Take filter for example ,
filter can take List<Object>, Set<String>, Map<String, Object> and String as arguments.
When filtering on a map, the expecting predicate function in filter is like this:
pred:: (value, key) => Boolean

Aha, that's indeed a cleaner approach!
Thanks!
Small question, is there a specific reason why the order of pred arguments is
pred:: (value, key)

and not
pred:: (key, value)

Or is this a standard in all other libraries like Lodash etc.?  This difference of usage is commonly seen between lodash and ramdajs.
You can refer to this popular speech to get deeper understanding on this:
http://functionaltalks.org/2013/05/27/brian-lonsdorf-hey-underscore-youre-doing-it-wrong/
Simply put, if we want to 'compose' functions in a more functional way, put the main data at last.
Func filterNotNull = R.filter.apply(R.isNotNull);

This composed function waits for the data to be filtered. If we do it in the other way, it would be like this:
Func filterNotNull = R.otherFilter.apply(R.placeholder, R.isNotNull);

Here the otherFilter takes (list, pred), so we need to use a placeholder to keep room for the data. And obviously that takes more code to compose.

@liumiaowilson Thank you for the explanation! Really appreciate it!
Another thing I'm currently trying to do is; filter the fields that do not have a certain value (or a list of possible values).
So I could pass a Map like this to the filter function:
Map<String, String> m = new Map<String, String>{
    'Name' => new List{ 'TestAccount', 'TestAccount2' }
};

So if the field value for Name in eg an Account is not equal these specific values, the field should be retained.
Is this still possible with the default filter functionality?

It would be difficult to achieve it with the default filter functionality, I might say.
Well, even if it is possible, I would still suggest that you create a custom function to implement this logic.
It would be a shame if you go too far with functional composition in R.apex and lose the code readability. Do not do functional just for the sake of being functional programming. Just strike a balance between functional style and code readability.
 If it is kind of commonly used, I would put it in a class to reference it like this:
public class CustomFuncs {
    public static final Func filter = new CustomFilter();
}

So I can reuse it wherever I want without creating another new instance.
Object result = CustomFuncs.filter.run(m, data);

Thanks!
I came up with this:
private class PropInFunc extends Func {

        public PropInFunc() {
            super(3);
        }

        public override Object exec(Object a, Object b, Object c) {
            Object value = a;
            Object key = b;
            Map<String, Object> mMap;

            if((Boolean)R.isMapLike.run(c)) {
                mMap = (Map<String, Object>)c;
                Object mValue = mMap.get((String)key);

                if(mValue != null && (Boolean)R.isListLike.run(mValue)) {
                    return R.of(mValue).contains(value);
                }
            }

            return false;
        }
    }

and then call it like:
R.filter.apply(new PropInFunc().apply(R.placeholder, R.placeholder, m)),

with m the map with the allowed field values.
I could add it in an MR if you think it's reusable in R.apex?
Anyway, thanks for the help!

@glenncoppens Very good implementation.
If you put the map as the first argument, you can call it like:
R.filter.apply(new PropInFunc().apply(m))

That would be simpler, right?
When you use R.of(mValue).contains(value), it actually returns an instance of R. To get the value out of R, you can try:
R.of(mValue).contains(value).toBoolean()

isMapLike not only checks if the argument is an instance of Map<String, Object>, but checks if it is anything that can be converted to Map<String, Object>, including SObject and R instances.
So you can improve it to:
if((Boolean)R.isMapLike.run(c)) {
    mMap = (Map<String, Object>)R.toMap.run(c);
 }

toMap is a corresponding function to isMapLike, which converts any map-like objects into maps. So is true with isListLike/toList, isSetLike/toSet, and isStringLike/toString.
Sure you can add it in a PR, and do make sure to include tests and examples of how people are supposed to use this new functions. Good job.


How to get a pin's mask or pin number

I cannot seem to figure out how can I retrieve the pin number programmatically.
My intention is do be able to write something similar to what you do in  /avr-generic/port.rs does but in my main code base:
unsafe {
    (*<$PORTX>::ptr()).$reg_port.modify(|r, w| {
        w.bits(r.bits() & !(1 << $i))
    });
}

For which I need $i.
But I am not able to find an way on how to obtain that number. Could you provide an example on how to achieve this?

I don't quite understand what you are trying to do.  Can you please clarify, what your goal is?

Similar to what your macro I described above is doing. I want to change a bit on a register.
The bit on the register I want to change is the pin number:
Example from src/atmega328p/port.rs
pc3: (PC3, 3) The 3 here.
As currently analog read is not implemented I am trying to do it myself in the meantime:
dp.ADC.admux.modify(|r, w| { w.bits(r.bits() | mask) }); //Enable ADC for a given pin
But I need to know the mask of the pin.
So, for a given pin, i need the mask to use.
Sorry if I am not making myself clear enough, let me know if more info is needed and thanks for the help and effort!

Still not quite sure ... But I think I got something for you:
If you downgrade the pins, you can match them like this (or slightly different, this code is untested):
let pin = pc3.downgrade();

if let atmega328p_hal::port::Pin::C(id, _) = pin {
    // ...
} else {
    panic!("Only pins of port C can be used for analog reads!");
}

Yeah! This is exactly what I was looking for, that "id". Only correction "i think" is that this is the correct import that worked for me:
let pin = pc3.downgrade();

if let arduino_uno::hal::port::Pin::C(id, _) = pin {
    // ...
} else {
    panic!("Only pins of port C can be used for analog reads!");
}

Thanks a lot for the help and assistance! Great work!


:> Exception in thread Thread-1: Traceback (most recent call last):

The program was running a  loop in which I was plotting 3 variables.
The loop continue while à push a button.
and when I pushed the button this error append.
and no more variable were received ...
:> Exception in thread Thread-1:
Traceback (most recent call last):
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 914, in _bootstrap_inner
self.run()
File "/usr/local/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/threading.py", line 862, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.5/site-packages/pytelemetrycli/runner.py", line 43, in run
self.telemetryWrapper.update()
File "/usr/local/lib/python3.5/site-packages/pytelemetry/pytelemetry.py", line 65, in update
self.api.update()
File "/usr/local/lib/python3.5/site-packages/pytelemetry/telemetry/telemetry.py", line 145, in update
self.delimiter.decode(c)
File "/usr/local/lib/python3.5/site-packages/pytelemetry/telemetry/framing.py", line 52, in decode
self.on_frame_decoded_callback(self.payload)
File "/usr/local/lib/python3.5/site-packages/pytelemetry/telemetry/telemetry.py", line 148, in _on_frame_detected
topic_data = self._decode_frame(frame)
File "/usr/local/lib/python3.5/site-packages/pytelemetry/telemetry/telemetry.py", line 121, in _decode_frame
data, = unpack_from(fmt, frame, i+1)
struct.error: unpack_from requires a buffer of at least 8 bytes

This is a problem with pytelemetrycli.
Looks like a badly formatted frame, without logs I cannot figure what is going on. Logging is now fully implemented, I just need to make the release on pypi.
Could you post the embedded code that communicates with the command line interface ? It could help me understand what is going on

In the future, please post issues related with the command line interface in the right repository for clarity ;)

Fixed by https://github.com/Overdrivr/pytelemetry/commit/f1648e46a8931386ce99ab7498eef34530b12429


fn: Added HasDuplicates function to slice

Change Description
This PR adds a new function to check if the values in a slice have duplicates.
Steps to Test
Steps for reviewers to follow to test the change.
Pull Request Checklist
Testing

[ ] Your PR passes all CI checks.
[ ] Tests covering the positive and negative (error paths) are included.
[ ] Bug fixes contain tests triggering the bug to prevent regressions.

Code Style and Documentation

[ ] The change obeys the Code Documentation and Commenting guidelines, and lines wrap at 80.
[ ] Commits follow the Ideal Git Commit Structure.
[ ] Any new logging statements use an appropriate subsystem and logging level.
[ ] Any new lncli commands have appropriate tags in the comments for the rpc in the proto file.
[ ]  There is a change description in the release notes, or [skip ci] in the commit message for small changes.

📝 Please see our  Contribution Guidelines for further guidance.

Pushed a new tag fn/v1.0.7.


Add native lazy loading for images and iframes

This feature is available only in Chrome >= 76 for now.
See https://web.dev/native-lazy-loading

FI, with Firefox (didn't test with Chrome), lazy loading is a bit painful because images/iframes do not have an intrinsic size. Therefore, when scrolling a bit too fast (like when skipping a section), the layout jumps when images load. Also, maybe Chrome is smarter to keep the scroll position. Firefox has scroll anchoring since 66 but for some reason, it does not work well in this case.
No need to change, this is just a feedback.

The behavior in Firefox is noticed here too: https://bugzilla.mozilla.org/show_bug.cgi?id=1618240. It seems the implementation is widely different between Firefox (0px) and Chrome (1800 → 3000px depending on bandwidth). The specification doesn't set the threshold.


Fixed Markdown Formatting Errors in README.md

I fixed a few mistakes that were made in the README.md in regard to the formatting of the Markdown. I removed the html for the images, added spacing between the header and the body, and fixed spacing in the unordered list

@microsoft-github-policy-service agree

Sorry but these don't seem worthwhile fixes (especially removing the html because that changes how the content renders)

Sorry but these don't seem worthwhile fixes (especially removing the html because that changes how the content renders)

What if I changed it back to HTML? Or still no? Thanks for your time regardless

Yes but please consider that PRs like this take time to review. Minor stylistic/grammar preferences generally aren't worth the time


Fixing wrong datePickerMode test when using UIDatePickerModeTime

When testing for not initialized self.datePickerMode property, the code is not taking into account that UIDatePickerModeTime constant is defined to 0.
This produce an incorrect behaviour.

self.datePickerMode = UIDatePickerModeTime = 0

is always evaluated to false and the property is always reset to the default value of UIDatePickerModeDate, having no way to use the time mode.
The fix allows you to close the issue #2 .

Thanks for the PR! This was a oversight during porting of the library from Swift to Objective-C.


webkitgtk: Add /run/opengl-driver to bubblewrap bind mounts

Motivation for this change
Without access to the /run/opengl-driver directory, webkit fails to create an EGL context, since it can't identify a suitable EGL
vendor. This results in a blank window and the following error output:
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot create EGL context: invalid display (last error: EGL_SUCCESS)

Fixes #98819 and possibly #32580.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Yep, makes total sense.

After 2.5h compilation process, I can confirm this fixes my issues on Intel graphics, at least.
The following works fine and results in no error output when visiting my previous test case sites of Facebook, Messenger, and Hangouts.
WEBKIT_DISABLE_COMPOSITING_MODE=0 epiphany

What about without setting that? We'd want it to work as intended

What about without setting that? We'd want it to work as intended

It works both ways, I just wanted to show that under normal circumstances when WEBKIT_DISABLE_COMPOSITING_MODE is set to 0 (the default) it works fine, meaning the workaround to enabling WEBKIT_DISABLE_COMPOSITING_MODE is not needed, at least on my hardware.

@austinbutler Gotcha, thanks.

@talyz If you could open a backport PR that would be great. We could possibly readd epiphany now.

@worldofpeace I opened two new PRs, one to revert the epiphany removal (#108107) and another to backport both that and this one (#107981).

@worldofpeace I opened two new PRs, one to revert the epiphany removal (#108107) and another to backport both that and this one (#107981).


chenna committed

@Mynameischenna Hi, Do u think this PR adds any value to this repo ? Would love to merge your PR if that's genuinely add some value. Thanks.


Updated Private DNS zone names for Azure China

Added private DNS zone names for services which are available in Azure China

@faister : Thanks for your contribution! The author(s) have been notified to review your proposed change.

#label:"aq-pr-triaged"

#label:"aq-pr-triaged"

how is this PR review coming along please?


Release 0.13

Closes #1306
Unless I'm given a reason to wait, I'll release this in two days' time.
I suggest the following release text:

The major feature for this PyO3 release is support for the CPython limited API. This is an opt-in feature when building extension modules which makes it possible for the built wheel to be installable on multiple Python versions.
As well as this, a number of other refinements, fixes, and performance improvements have been merged into this release. For full details, see the CHANGELOG.
Thank you to everyone who contributed code, documentation fixes, design ideas, bug reports, and feedback. The following users' commits are included in this release:
@AleksaC
@alex
@Askaholic
@aviramha
@birkenfeld
@Daggy1234
@davidhewitt
@dvermd
@kngwyu
@konstin
@Palladinium
@roblabla
@scalexm
@Stranger6667

Thanks!
You may want to note the renaming of proc-macro crates?

👍 Edited the release text draft above to mention.

I also want to say thanks to everyone who contributed to this version. ❤
Especially, thanks @alex for abi3 support and thanks @davidhewitt for your continuous efforts to keep this project solid!


feat(web-modeler): add Web Modeler to combined Ingress

Which problem does the PR fix?
Closes https://github.com/camunda/web-modeler/issues/3179.
What's in this PR?
Add support for Web Modeler in the combined Ingress.
Checklist
Please make sure to follow our Contributing Guide.

Before opening the PR:

[x] There is no other open pull request for the same update/change.
[x] The commits follow our Commit Guidelines.
[x] Tests for charts are added (if needed).
[x] The main Helm chart and sub-chart are updated (if needed).
[x] In-repo documentation are updated (if needed).

After opening the PR:

[x] Did you sign our CLA (Contributor License Agreement)? It will show once you open the PR.
[x] Did all checks/tests pass in the PR?

just 1 question, did you test it manually with Ingress and TLS?

Hi @aabouzaid,
yes, I tested it with a local kind cluster and self-signed certificates. It worked fine :)

@jfriedenstab then all good to go :+1:


Use tough-cookie

Hi,
I used the typings generator to restructure the project a bit and then I updated the definitions to use CookieJar and Cookie from tough-cookie.
It should fix #1

Hi @Demurgos, Thanks for contributing!
I have left you a couple of comments. Otherwise LGTM. I'm going to test this and merge it asap.

Hi!
I just updated the files according to your comments.

Is it OK ? I'm waiting for this PR to update some dependant projects.

Yeah sorry. Merged.


how to notify

Describe your problem here.
why do I not get notifications from the issues im subscribed to???????????
(kinda of topic but where else do I say it? on youtube?)
Are you modding a build from source or with Lua?
uh
What is your build target?
...
Did you edit anything in this build? If so, mention or summarize your changes.
this isn't really necessary

1 second later I regret saying this
but I'll see what happens

I conveniently found out why right now


inference face error

I trained with the data of more than 200 people, all the training data was checked, and the training data was not corrupted.
sync loss has been reduced to about 0.18, some faces can be inferred normally, but some faces will have garbled characters.
What might be the cause of this? How to fix it?

you need to train the generator as you can see the quality is good then apply syncnet


Minor update to the version of syn as-listed in bower 0.0.3 -> 0.13.0

Same thing as #166 .
Does anyone know how to submit while awaiting review without running into package lock problems?
Thanks!

I would just merge this change in.
After you merge to master, be sure to git checkout master and git pull to get the latest changes. Hopefully new branches don’t have that dependency issue.

Still seeing error: Cannot find module 'lodash'

@kdillon When you created the updating_bower_to_current_syn_ver branch, it did not have the package-lock.json change that fixed this issue. You can merge the latest master into this branch to fix the issue. Make sure you git checkout master and git pull before creating a new branch, so new branches have the fix.

On an unrelated note; would you maybe want to just remove the Bower file? When you run the npm release scripts, it doesn’t publish to Bower, so I don’t think there’s really any use for the file anymore.

@chasenlehara I did git checkout master and pull before branching this, but the previous branch hadn't been merged until after this was submitted. So trunk now is different than when this was branched.
I'm not sure why that would block anything. It seems like it would be a fairly standard workflow. Otherwise you can only have on submission under review at a time.


DBZ-2861 Not building dependent projects for testing, as we cannot bu…

…ild the components they depend on with a single call
https://issues.redhat.com/browse/DBZ-2861
@jpechane, I think that's good enough.

// CC @ani-sha
Also asked on Twitter, just in case someone has an idea. But I think we can go with this, as the alternative (explicitly listing all the modules of the tree we need) is even less desirable.

// CC @ani-sha
Also asked on Twitter, just in case someone has an idea. But I think we can go with this, as the alternative (explicitly listing all the modules of the tree we need) is even less desirable.


Cleanup the return value type for the bastion host outputs

single host = single output value

Needed for iVox.

But there's an instance_count variable, so you can actually create multiple instances

@iuriaranda good catch. This is dropped now. I discussed this with @MattiasGees to not support setting up multiple bastions in one resource definition.


Display data in Edit User Modal

Pull request corresponding to issue #253 Display data in Edit User Modal. User Modal component displays corresponding data.

Hey @sakshi172015
Can you please make a subfolder inside the ./dashboard directory for "Users"?

Sure @lakshya-20
the subfolder "users" created under ./dashboard directory.


ti.barcode and SDK 5.1.2 GA

Hello everybody!
Is possible to use ti.barcode module with the SDK 5.1.2 Titanium version?
Thanks in advance.
Best regards,
Mirco

Yes


README: Fix broken SourceLevel image and link

💁 It looks like SourceLevel changed their URL structure at some point between when this badge was added to README.md and now. These changes fix those URLs and enable the badge image to render again.

Coverage decreased (-0.4%) to 73.333% when pulling 4780a34816c4b5d8cf5d634abf99d89be11473e5 on sgerrand:patch-1 into c2512dee7880b6cecccc17093eff9e243077fba7 on Nebo15:master.

@sgerrand can you please fix the conflict and I'll merge it :). Thank you ❤

Shall do!

👋 @AndrewDryga: All done, awaiting your review.

Thank you :)


various nits on versionReport examples

(1) the body contains a method self executionStoneName.  I had a bit of trouble figuring out where this was implemented (had to grep the distributions).  I also see lots of use of self stdOut. While these methods are self-explanatory, my first reaction is to wonder
what the set of supported functions I can call are.  Examples in particular should have a documented set of available, supported functions.  (I was trying to lookup how executionStoneName was implemented since the solo was reporting a bogus stone name, and my first reaction is to lookup what the method is actually trying to do...)
(2) versionReport.solo reports it's on gs64stone, which makes no sense since there is no stone.  The comment says  "Write the Gem Version report for the current solo extent on stdout.", but it's not for the extent, it's the gem version report, and thus will be for whatever the linked topaz execution environment is. Perhaps something like "Write the Gem Version report for the current execution environment on stdout."
(3) versionReport.solo usage has a couple of examples with an additional argument, which are unexplained; I sorta think they are some kind of version key? and maybe you use it for something mysterious that is not visible in the script?  There should be an explanation or they should be removed...
versionReport.solo -- gs_360
versionReport.solo -- gs_360 -T 100000

(1) the class SuperDoitExecution is the superclass of the generated class for the doit ... so there are a number of public methods in that class that are provided for use by the scripts ... and yes this class is basically hidden . We could provide a solo script that could be used to list the selectors available and list method source on request or ???
(2)  sounds good
(3) if you are talking about gs_360 and 360 -T 10000 they are bogus leftovers from when I (probably) copied versionReport.stone to versionReport.solo ... they should be removed ...
THANKS!


Search Documentation Out of Order

Reviewing https://docs.maap-project.org/en/develop/technical_tutorials/searching.html we realized the CMR to STAC migration is the landing page for the whole Search Section, rather than a subtopic. This section needs a re-ordering, and a correct Table of Contents.
Acceptance Criteria:

[x] Landing page with Dual Catalog Explanation, links to sub pages
[x] Landing page correct TOC
[x] Prioritize still relevant Search docs

https://github.com/MAAP-Project/maap-documentation/pull/175


feat: add hostname to log file

Fixes #15004
Type of change

Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?
Added host-name there by enabling/making sure the log files have different name and there-by, keeping the data consistent.

/ok-to-test sha=eec82ab


healer will not build/config

i am getting this error when i try to prepare config files

i was trying to prepare the working directory , what files need in the bin folder and desc folder i have these, are these enough?

please guide in making working directory

Sorry for the late. The code and documentation you use are pretty old. Please read the latest documentation and build the code from the main branch. Let me know if there are any other problems.


WavPack crashes with SEGFAULT

Hello!
This bug was found by Crusher (fuzzer developing in ISP RAS), thanks to following colleagues:
Vitalii Akolzin, Shamil Kurmangaleev, Maxim Mishechkin, Fedor Nis'kov, Ivan Gulakov, Denis Straghkov,  Andrey Fedotov, Alexey Vishnyakov, Daniil Kutz, Alexander Novikov.
Product version
Commit 940a8b7f35205efbd5d64a88875481a7dbfa7e52 (latest commit on master at current moment).
Environment
Ubuntu 16.04/18.04
To reproduce

Extract crash.wav from crash.wav.tar.gz
Run:

wavpack -y crash.wav

Program crashes with SEGFAULT.
Error message:
 WAVPACK  Hybrid Lossless Audio Compressor  Linux Version 5.3.2
 Copyright (c) 1998 - 2020 David Bryant.  All Rights Reserved.

creating crash.wv,Segmentation fault (core dumped)

Valgrind output:
creating crash.wv,==29284== Invalid write of size 4
==29284==    at 0x122C08: WavpackPackSamples (pack_utils.c:662)
==29284==    by 0x1111ED: pack_audio (wavpack.c:2407)
==29284==    by 0x1111ED: pack_file (wavpack.c:1911)
==29284==    by 0x10B792: main (wavpack.c:1278)
==29284==  Address 0x559d3f0 is 0 bytes after a block of size 162,800 alloc'd
==29284==    at 0x4C2FB0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==29284==    by 0x12282B: WavpackPackInit (pack_utils.c:561)
==29284==    by 0x110FE6: pack_audio (wavpack.c:2323)
==29284==    by 0x110FE6: pack_file (wavpack.c:1911)
==29284==    by 0x10B792: main (wavpack.c:1278)
==29284==
==29284== Invalid write of size 4
==29284==    at 0x122C17: WavpackPackSamples (pack_utils.c:663)
==29284==    by 0x1111ED: pack_audio (wavpack.c:2407)
==29284==    by 0x1111ED: pack_file (wavpack.c:1911)
==29284==    by 0x10B792: main (wavpack.c:1278)
==29284==  Address 0x559d3f4 is 4 bytes after a block of size 162,800 alloc'd
==29284==    at 0x4C2FB0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==29284==    by 0x12282B: WavpackPackInit (pack_utils.c:561)
==29284==    by 0x110FE6: pack_audio (wavpack.c:2323)
==29284==    by 0x110FE6: pack_file (wavpack.c:1911)
==29284==    by 0x10B792: main (wavpack.c:1278)
==29284==
   0% done...--29284-- VALGRIND INTERNAL ERROR: Valgrind received a signal 11 (SIGSEGV) - exiting
--29284-- si_code=1;  Faulting address: 0x7F0563D49E;  sp: 0x1002dade30

valgrind: the 'impossible' happened:
   Killed by fatal signal

host stacktrace:
==29284==    at 0x58053139: ??? (in /usr/lib/valgrind/memcheck-amd64-linux)
==29284==    by 0x5800BA84: ??? (in /usr/lib/valgrind/memcheck-amd64-linux)
==29284==    by 0x5800BC66: ??? (in /usr/lib/valgrind/memcheck-amd64-linux)
==29284==    by 0x5809F785: ??? (in /usr/lib/valgrind/memcheck-amd64-linux)
==29284==    by 0x580AED50: ??? (in /usr/lib/valgrind/memcheck-amd64-linux)

sched status:
  running_tid=1

Thread 1: status = VgTs_Runnable (lwpid 29284)
==29284==    at 0x4C2FB0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==29284==    by 0x1211E2: pack_streams (pack_utils.c:955)
==29284==    by 0x122DB1: WavpackFlushSamples (pack_utils.c:727)
==29284==    by 0x112537: pack_audio (wavpack.c:2444)
==29284==    by 0x112537: pack_file (wavpack.c:1911)
==29284==    by 0x10B792: main (wavpack.c:1278)

Analysis

In https://github.com/dbry/WavPack/blob/940a8b7f35205efbd5d64a88875481a7dbfa7e52/src/pack_utils.c#L561
malloc's argument overflows size_t type and results in small positive number.
So, only a short memory region is allocated.

Then https://github.com/dbry/WavPack/blob/940a8b7f35205efbd5d64a88875481a7dbfa7e52/src/pack_utils.c#L612
dptr now points to address in previously allocated region

Finally https://github.com/dbry/WavPack/blob/940a8b7f35205efbd5d64a88875481a7dbfa7e52/src/pack_utils.c#L662
we write in memory by dptr pointer. But in one moment dptr points to memory outside of allocated region. Segmentation fault.

Appears that CVE-2020-35738 was assigned for this issue.

Hi, not sure if it helps but..
I couldn't reproduce this in version 4.70.0 (Debian Jessie):
root@18227e5bad53:/# wavpack -y crash.wav

 WAVPACK  Hybrid Lossless Audio Compressor  Linux Version 4.70.0
 Copyright (c) 1998 - 2013 Conifer Software.  All Rights Reserved.

created crash.wv in 0.09 secs (lossless, 59.17%)

However, could reproduce this in version 5.0.0 (Debian Stretch):
root@8eb0c583e3cf:/# wavpack -y crash.wav

 WAVPACK  Hybrid Lossless Audio Compressor  Linux Version 5.0.0
 Copyright (c) 1998 - 2016 David Bryant.  All Rights Reserved.

creating crash.wv,Segmentation fault (core dumped)

By this, I am also inclined towards believing that vulnerable code wasn't present in v4.70.0. Please let me know if I am mistaken somehow :)

@utkarsh2102 FYI: If you want to be sure you should not rely only on reproducibility with a POC but inspect the code as well (but note that in 38dba75b9ae22693b86ff47603dc661a329a28d8 a code reorganization and cleanup was done).

Aah, well. Right, let's wait for the fix and then re-analyze the situation from there.

Aah, well. Right, let's wait for the fix and then re-analyze the situation from there.

Hm, so as I see it, in Debian Jessie (v4.70.0), there's no check on sample_rate so https://github.com/dbry/WavPack/commit/63f3ec70129843dd64e11aa4c21c4a1cf00c9f1c doesn't apply.
As for https://github.com/dbry/WavPack/commit/89df160596132e3bd666322e1c20b2ebd4b92cd0, the only applicable diff is:
--- a/src/wputils.c
+++ b/src/wputils.c
@@ -1096,10 +1096,10 @@ int WavpackPackInit (WavpackContext *wpc)
     else
         wpc->block_samples = wpc->config.sample_rate;

-    while (wpc->block_samples * wpc->config.num_channels > 150000)
+    while ((int64_t) wpc->block_samples * wpc->config.num_channels > 150000)
         wpc->block_samples /= 2;

-    while (wpc->block_samples * wpc->config.num_channels < 40000)
+    while ((int64_t) wpc->block_samples * wpc->config.num_channels < 40000)
         wpc->block_samples *= 2;

     if (wpc->config.block_samples) {

I am not sure if backporting this diff is worthy enough to avoid causing buffer overruns and avoiding integer overflows. Does anybody has an opinion on this? Do you think it's still "safe and recommended" to backport this diff to v4.70.0?

First of all, thank you @wakolzin for finding and reporting this issue! This is now fixed in the master branch.
I have also carefully analyzed the issue and I believe that this is an extremely low risk from a security perspective. The buffer overflow could be exploited to corrupt the next heap entry and possibly force the next malloc to return an arbitrary address, but unfortunately that next malloc is for the compressed audio block and there’s no method for the attacker to control what gets written there. Another complicating factor is that the compressor modifies the audio data “in-place” during decorrrelation, so again there’s no way to control the final contents. I’m certainly no expert in this, but I think it would be extraordinarily difficult, if not impossible, to create an exploit for this overrun.
But more problematic, even if it were possible to create an exploit, it would be nearly impossible to trigger it from a practical standpoint. The WavPack command-line program is not a default application for WAV files (or any file type) and is not supplied by default in any distro. Therefore the attacker would have to convince a user to install the command-line program, manually download the maliciously crafted file, and attempt, using the terminal, to compress it using WavPack. If you can get someone to do that, there are far simpler ways of gaining control of their system.

@utkarsh2102 With respect to 4.70.0, I actually find it a little frightening that that 7+ year-old release is still being patched, but I’m sure there are some good reasons for this. Personally, I am of the opinion that it’s good practice to maintain backward compatibility unless absolutely unavoidable (maybe I’m just old) and I have worked very hard to make sure that the latest version is a “drop-in” replacement for older versions (see first paragraph of porting guide).
In any event, assuming all the other “real” security issues fixed since 2013 have been patched, the patch you suggest is safe, and I would add the other checks too:
@@ -947,6 +947,21 @@ int WavpackSetConfiguration (WavpackContext *wpc, WavpackConfig *config, uint32_
     int num_chans = config->num_channels;
     int i;

+    if (config->sample_rate <= 0) {
+        strcpy (wpc->error_message, "sample rate cannot be zero or negative!");
+        return FALSE;
+    }
+
+    if (num_chans <= 0 || num_chans > NEW_MAX_STREAMS * 2) {
+        strcpy (wpc->error_message, "invalid channel count!");
+        return FALSE;
+    }
+
+    if (config->block_samples && (config->block_samples < 16 || config->block_samples > 131072)) {
+        strcpy (wpc->error_message, "invalid custom block samples!");
+        return FALSE;
+    }
+
     wpc->total_samples = total_samples;
     wpc->config.sample_rate = config->sample_rate;
     wpc->config.num_channels = config->num_channels;
@@ -1096,10 +1111,10 @@ int WavpackPackInit (WavpackContext *wpc)
     else
         wpc->block_samples = wpc->config.sample_rate;

-    while (wpc->block_samples * wpc->config.num_channels > 150000)
+    while ((int64_t) wpc->block_samples * wpc->config.num_channels > 150000)
         wpc->block_samples /= 2;

-    while (wpc->block_samples * wpc->config.num_channels < 40000)
+    while ((int64_t) wpc->block_samples * wpc->config.num_channels < 40000)
         wpc->block_samples *= 2;

     if (wpc->config.block_samples) {

As for whether these are recommended, I refer you to my statements above. I really appreciate the work of volunteer maintainers, but I hate to see time and effort spent on vulnerabilities that aren’t real threats. I guess it depends on the threat level eventually assigned to this CVE (which I hope is very low).
Thanks!

@dbry Thank you for analysis and fix!

@dbry are you going to release a new version or should we backport the changes to 5.3.0?

@dbry are you going to release a new version or should we backport the changes to 5.3.0?

@juanfra684 I will release a new version in a few days from current source (so it will include a few other updates also, mostly minor fixes but also the quick verify (-vv) feature).
@wakolzin If you have any other issues like this that you know about it would be great to see them before I generate a release.
Thanks!

@juanfra684 I will release a new version in a few days from current source (so it will include a few other updates also, mostly minor fixes but also the quick verify (-vv) feature).
@wakolzin If you have any other issues like this that you know about it would be great to see them before I generate a release.
Thanks!

@dbry This issue was the only I know about.

@dbry This issue was the only I know about.

Note that this issue has two patches associated with it, 63f3ec70129843dd64e11aa4c21c4a1cf00c9f1c and 89df160596132e3bd666322e1c20b2ebd4b92cd0. Unfortunately the first one failed the Travis build (for an unrelated reason), but they are both in the commit log tagged with issue #91.
It's a little tricky to verify that both were picked up everywhere, but I noticed on this page that at least Ubuntu may not have.
The good news is that 89df160596132e3bd666322e1c20b2ebd4b92cd0 is sufficient by itself to resolve the SEGFAULT because the potentially negative sample rate is assigned to block_samples, which is unsigned. I verified this with both crashers.
However, if anyone mistakenly only brings in 63f3ec70129843dd64e11aa4c21c4a1cf00c9f1c, then that would be insufficient to resolve the issue.

Note that this issue has two patches associated with it, 63f3ec70129843dd64e11aa4c21c4a1cf00c9f1c and 89df160596132e3bd666322e1c20b2ebd4b92cd0. Unfortunately the first one failed the Travis build (for an unrelated reason), but they are both in the commit log tagged with issue #91.
It's a little tricky to verify that both were picked up everywhere, but I noticed on this page that at least Ubuntu may not have.
The good news is that 89df160596132e3bd666322e1c20b2ebd4b92cd0 is sufficient by itself to resolve the SEGFAULT because the potentially negative sample rate is assigned to block_samples, which is unsigned. I verified this with both crashers.
However, if anyone mistakenly only brings in 63f3ec70129843dd64e11aa4c21c4a1cf00c9f1c, then that would be insufficient to resolve the issue.

WavPack 5.4.0 has been released with this fix. Thanks again!

WavPack 5.4.0 has been released with this fix. Thanks again!

Hello @dbry,

But more problematic, even if it were possible to create an exploit, it would be nearly impossible to trigger it from a practical standpoint. The WavPack command-line program is not a default application for WAV files (or any file type) and is not supplied by default in any distro.

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

@utkarsh2102 With respect to 4.70.0, I actually find it a little frightening that that 7+ year-old release is still being patched, but I’m sure there are some good reasons for this.

Haha, yes. There exists Debian LTS and ELTS, where the packages in the Debian archive are supported (only against security vulnerabilities) for extended 2 years for LTS and then another 2 years for ELTS.

Personally, I am of the opinion that it’s good practice to maintain backward compatibility unless absolutely unavoidable (maybe I’m just old) and I have worked very hard to make sure that the latest version is a “drop-in” replacement for older versions (see first paragraph of porting guide).
In any event, assuming all the other “real” security issues fixed since 2013 have been patched, the patch you suggest is safe, and I would add the other checks too..

Thank you so much for your help and effort in writing this patch and of course, for your hard work in best maintaining the backward compatibility! ❤
This really helps in maintaining and backporting security patches to the older versions! \o/

Hello @dbry,

But more problematic, even if it were possible to create an exploit, it would be nearly impossible to trigger it from a practical standpoint. The WavPack command-line program is not a default application for WAV files (or any file type) and is not supplied by default in any distro.

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

@utkarsh2102 With respect to 4.70.0, I actually find it a little frightening that that 7+ year-old release is still being patched, but I’m sure there are some good reasons for this.

Haha, yes. There exists Debian LTS and ELTS, where the packages in the Debian archive are supported (only against security vulnerabilities) for extended 2 years for LTS and then another 2 years for ELTS.

Personally, I am of the opinion that it’s good practice to maintain backward compatibility unless absolutely unavoidable (maybe I’m just old) and I have worked very hard to make sure that the latest version is a “drop-in” replacement for older versions (see first paragraph of porting guide).
In any event, assuming all the other “real” security issues fixed since 2013 have been patched, the patch you suggest is safe, and I would add the other checks too..

Thank you so much for your help and effort in writing this patch and of course, for your hard work in best maintaining the backward compatibility! ❤
This really helps in maintaining and backporting security patches to the older versions! \o/

Hello @dbry,

But more problematic, even if it were possible to create an exploit, it would be nearly impossible to trigger it from a practical standpoint. The WavPack command-line program is not a default application for WAV files (or any file type) and is not supplied by default in any distro.

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

Yes, the vulnerability is in libwavpack, and that's widely distributed and used, but it’s in the encoder portion, not the decoder. The decoder is constantly fuzzed in Google’s OSS-Fuzz because that’s where serious vulnerabilities will be located given that libwavpack is one of the only consumers of WavPack files (aside from the native FFmpeg decoder). Many of the programs that use libwavpack only do decoding (like cmus that you mention), so they’re going to be fine.
The vulnerability here is when crazy values for sample rate and/or channel count are passed to libwavpack for encoding. So any program using the library for encoding regular audio is not going to be affected because the parameters are going to be fixed (like a CD ripper). The program would have to be attempting to convert one of these crafted files and the most likely scenario is that the program would immediately recognize the corruption and would never end up trying to pass it to libwavpack (or the command-line program). For example, I just tested FFmpeg, Foobar2000, and Gstreamer and they all refused to even open either of these files.
So this vulnerability is best suited for the command-line WavPack program because it accepts a wide range of encoding parameters (because the Wavpack format supports a wide range of parameters). I would be very surprised if another libwavpack application could be coaxed into even triggering this crash, much less used in an actual exploit.

Thank you so much for your help and effort in writing this patch and of course, for your hard work in best maintaining the backward compatibility!
This really helps in maintaining and backporting security patches to the older versions! \o/

I'm glad to help, and I will be happy to respond to your other queries as time permits!  :+1:

Hello @dbry,

But more problematic, even if it were possible to create an exploit, it would be nearly impossible to trigger it from a practical standpoint. The WavPack command-line program is not a default application for WAV files (or any file type) and is not supplied by default in any distro.

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

Yes, the vulnerability is in libwavpack, and that's widely distributed and used, but it’s in the encoder portion, not the decoder. The decoder is constantly fuzzed in Google’s OSS-Fuzz because that’s where serious vulnerabilities will be located given that libwavpack is one of the only consumers of WavPack files (aside from the native FFmpeg decoder). Many of the programs that use libwavpack only do decoding (like cmus that you mention), so they’re going to be fine.
The vulnerability here is when crazy values for sample rate and/or channel count are passed to libwavpack for encoding. So any program using the library for encoding regular audio is not going to be affected because the parameters are going to be fixed (like a CD ripper). The program would have to be attempting to convert one of these crafted files and the most likely scenario is that the program would immediately recognize the corruption and would never end up trying to pass it to libwavpack (or the command-line program). For example, I just tested FFmpeg, Foobar2000, and Gstreamer and they all refused to even open either of these files.
So this vulnerability is best suited for the command-line WavPack program because it accepts a wide range of encoding parameters (because the Wavpack format supports a wide range of parameters). I would be very surprised if another libwavpack application could be coaxed into even triggering this crash, much less used in an actual exploit.

Thank you so much for your help and effort in writing this patch and of course, for your hard work in best maintaining the backward compatibility!
This really helps in maintaining and backporting security patches to the older versions! \o/

I'm glad to help, and I will be happy to respond to your other queries as time permits!  :+1:

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

Yes, the vulnerability is in libwavpack, and that's widely distributed and used, but it’s in the encoder portion, not the decoder. The decoder is constantly fuzzed in Google’s OSS-Fuzz because that’s where serious vulnerabilities will be located given that libwavpack is one of the only consumers of WavPack files (aside from the native FFmpeg decoder). Many of the programs that use libwavpack only do decoding (like cmus that you mention), so they’re going to be fine.
The vulnerability here is when crazy values for sample rate and/or channel count are passed to libwavpack for encoding. So any program using the library for encoding regular audio is not going to be affected because the parameters are going to be fixed (like a CD ripper). The program would have to be attempting to convert one of these crafted files and the most likely scenario is that the program would immediately recognize the corruption and would never end up trying to pass it to libwavpack (or the command-line program). For example, I just tested FFmpeg, Foobar2000, and Gstreamer and they all refused to even open either of these files.
So this vulnerability is best suited for the command-line WavPack program because it accepts a wide range of encoding parameters (because the Wavpack format supports a wide range of parameters). I would be very surprised if another libwavpack application could be coaxed into even triggering this crash, much less used in an actual exploit.

Aah, okay. Thanks for the explanation! 👍🏻

I'm glad to help, and I will be happy to respond to your other queries as time permits! +1

Great, thank you!

That isn't true. The vulnerability isn't in the wavpack binary but in the "libwavpack" which is being used widely by a bunch of other programs and applications. For example, ffmpeg, cmus, audiotools, et al.

Yes, the vulnerability is in libwavpack, and that's widely distributed and used, but it’s in the encoder portion, not the decoder. The decoder is constantly fuzzed in Google’s OSS-Fuzz because that’s where serious vulnerabilities will be located given that libwavpack is one of the only consumers of WavPack files (aside from the native FFmpeg decoder). Many of the programs that use libwavpack only do decoding (like cmus that you mention), so they’re going to be fine.
The vulnerability here is when crazy values for sample rate and/or channel count are passed to libwavpack for encoding. So any program using the library for encoding regular audio is not going to be affected because the parameters are going to be fixed (like a CD ripper). The program would have to be attempting to convert one of these crafted files and the most likely scenario is that the program would immediately recognize the corruption and would never end up trying to pass it to libwavpack (or the command-line program). For example, I just tested FFmpeg, Foobar2000, and Gstreamer and they all refused to even open either of these files.
So this vulnerability is best suited for the command-line WavPack program because it accepts a wide range of encoding parameters (because the Wavpack format supports a wide range of parameters). I would be very surprised if another libwavpack application could be coaxed into even triggering this crash, much less used in an actual exploit.

Aah, okay. Thanks for the explanation! 👍🏻

I'm glad to help, and I will be happy to respond to your other queries as time permits! +1

Great, thank you!


Build Error: Missing Required Mixin(s) libexpat1 in Paketo Buildpacks

Description:
I encountered an error while trying to build a function using func run --builder-image=registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base. The error states that the required mixin libexpat1 is missing.  registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base is equal to the gcr.io/paketo-buildpacks/builder:base
Logs:
Error: failed to build the function: validating stack mixins: index.docker.io/paketobuildpacks/run:base-cnb missing required mixin(s): libexpat1
Environment:
OS:    CentOS Linux release 7.9.2009 (Core)
func CLI version:   v0.38.0-12-g0d6e2106
Docker version:   23.0.6
Steps to Reproduce:
Run the command func run --builder-image=registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base
Observe the error message.
Expected Outcome:
The function should build successfully.
Actual Outcome:
Received an error message about missing mixin(s) libexpat1.
Questions:
Why am I encountering this issue?
How can this issue be resolved?

What language did you try to compile?

What language did you try to compile?
I tried to compile Go (or Golang) code

Where does registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base comes from? You should use ghcr.io/knative/builder-jammy-base with Func Go.

Oh wait actually latest released version still uses gcr.io/paketo-buildpacks/builder:base.

I have trouble to reproduce this.

Did you just docker tag gcr.io/paketo-buildpacks/builder:base registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base ? What is the digest of the image?

Maybe this was some temporary error that they already fixed?

Did you just docker tag gcr.io/paketo-buildpacks/builder:base registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base ? What is the digest of the image?

yes .  I just do  docker tag gcr.io/paketo-buildpacks/builder:base registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base

Maybe this was some temporary error that they already fixed?

"No, the error still exists, and I haven't found the reason for it yet."

"Is it possible to customize or configure the index.docker.io/paketobuildpacks/run:base-cnb image in Knative Func? I'd like to include specific libraries or mixins in the default build image, and I'm wondering if there's a way to achieve this through configuration or customization."

"Is it possible to customize or configure the index.docker.io/paketobuildpacks/run:base-cnb image in Knative Func? I'd like to include specific libraries or mixins in the default build image, and I'm wondering if there's a way to achieve this through configuration or customization."

In is not configurable this way. However you can create your own builder image that refers your run images.

I was not able to reproduce this issue. When I just tagged docker tag gcr.io/paketo-buildpacks/builder:base registry.cnbita.com:5000/knative-releases/paketo-buildpacks/builder:base and run build it worked for me.

Is there anything special you are doing? What does you project looks like? What CLI options did you use?

What about using full builder: https://github.com/knative/func/pkgs/container/builder-jammy-full would it solve your problems?


Add back parallel_tests

This adds back the parallel_tests gem and rake tasks that were dropped by https://github.com/ManageIQ/manageiq/pull/21976
The rationale was that it wasn't being used on CI after we moved to github actions, however particularly as local development machines become more and more powerful I think it makes sense to keep this even if we don't use it on CI.  Of course if we do allow creating 2x databases in our manageiq/postgresql service we could (aprox) halve the time it takes to run the CI suite.
For example locally running the whole core test suite:
$ time bundle exec rake

real	5m23.523s
user	4m22.581s
sys	0m9.156s

and 97% idle CPU
%Cpu(s):  2.5 us,  0.2 sy,  0.0 ni, 97.2 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st

So 5mins to run the whole suite locally, also known as "I never actually do this"
When running with parallel_tests:
$ time bundle exec rake parallel:spec

real	0m47.115s
user	16m47.186s
sys	0m52.796s

And less than 5% idle CPU
%Cpu(s): 90.1 us,  4.0 sy,  0.0 ni,  4.5 id,  1.4 wa,  0.0 hi,  0.0 si,  0.0 st

When it takes ~45seconds to run everything I do this way more often, and it is faster than punting it up to GHA to run and checking back periodically to see if it finished.
I didn't do a full-revert of https://github.com/ManageIQ/manageiq/pull/21976 since it was simpler for me to just use rake parallel:rake[test:vmdb:setup] and rake parallel:spec instead of our own custom rake tasks, plus if reducing code was one of the original goals this doesn't add back that much.

Would love to do this on CI, however, will we need the rest of the revert to do that? (Assuming we can figure out the database setup as well?)

Would love to do this on CI, however, will we need the rest of the revert to do that?

Yeah the bigger blocker to running this on CI is to support creating >1 postgres database


Curl Error

Any Solution For Curl Error?
It Just Says ERROR : Curl Failed

Sorry for the delayed response check #1

Thank You For Reply It Works Like A Charm Now

Great !! 👍


Merge over Sequential models

Hi all,
This is kind of an information request issue.
Is the following architecture possible with the Sequential model: LSTM with its output layer connected to several MLPs?
I tried to achieve this as follows:
Sequential(     LSTM,     Merge([Sequential(MLP), ... Sequential(MLP)], mode='concat') )
but run into a problem that Merge layer expects Tensors, not Sequential models.
How do I get such architecture to work?

Shouldn't it be enough to merge the output layers of each Sequential?

I strongly suggest you to design the net as a Graph:
input1 = Input(shape=(1, 128, 128))
input2 = Input(shape=(1, 128, 128))

conv1 = Convolution2D(1, 3, 3, border_mode='same')(input1)
conv1 = Convolution2D(1, 3, 3, border_mode='same')(conv1)
conv1 = Convolution2D(1, 3, 3, border_mode='same')(conv1)

conv2 = Convolution2D(1, 3, 3, border_mode='same')(input2)
conv2 = Convolution2D(1, 3, 3, border_mode='same')(conv2)
conv2 = Convolution2D(1, 3, 3, border_mode='same')(conv2)

merged = merge([conv1,conv2],mode='sum') #or 'concat' or 'mul'
lstm_output = LSTM(128, dropout_W=0.2)(merged)

model = Model(input=[input1,input2],output=lstm_output)

I am used to work with images, thus I don't know how the LSTM input expects, but I hope you have understood the idea.

Thanks all! In the end, I went with Functional API (i.e. defined the model as a graph).


Only the labelKey field is searched when using groupBy option.

I'm currently using version 4.5.0 but this issue is also reproducible on the demo site (https://cuppalabs.github.io/angular2-multiselect-dropdown/#/basic) which I assume is running latest.
The issue I'm seeing is that only the labelKey value will be searched if I am using the groupBy option. For example on the demo site example of group by (https://cuppalabs.github.io/angular2-multiselect-dropdown/#/groupby) I try filtering by 'Asia' and will get back no results in my filter, but I would expect both the Asia and Asia Pacific countries to be listed.  I also created my own version of this where gave each list item a 'region' property that was a duplicate value of the current category property. This still didn't solve the issue. I also specifically overrode the searchBy setting and included both the category and region properties.  Still it didn't filter on those properties.

Fixed. Fix available in v4.6.1


Small enhancements

Codecov Report

Merging #125 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #125   +/-   ##
=======================================
  Coverage   89.25%   89.25%
=======================================
  Files           7        7
  Lines         121      121
  Branches       18       18
=======================================
  Hits          108      108
  Misses         13       13

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1769171...73af1f6. Read the comment docs.


Is the executor part of the code closed source?

While reading through the code, I tried to find the implementation of the executor but couldn't find it after searching for a while. However, I did find several static libraries in the cpp/tensorrt_llm/executor directory. I'd like to know if this part is closed source?

Yes, these codes are closed.