Niuslar / Multichannel-Temperature-Control

5 stars 3 forks source link

Use ghcr image #113

Closed duduta closed 2 years ago

duduta commented 2 years ago

Hi, I updated the workflow so that it now uses the ghcr image when building the binary.

On an unrelated note, I noticed that the deploy steps, flash_debug and flash_release, are both deploying on hardware (the same hardware?), potentially at the same time. Steps in workflows are running in different processes, which could run concurrently on a Raspberry, so it shouldn't work or, at best, it might "work" with unexpected crashes. What am I missing?

Vavat commented 2 years ago

Hi, I updated the workflow so that it now uses the ghcr image when building the binary.

On an unrelated note, I noticed that the deploy steps, flash_debug and flash_release, are both deploying on hardware (the same hardware?), potentially at the same time. Steps in workflows are running in different processes, which could run concurrently on a Raspberry, so it shouldn't work or, at best, it might "work" with unexpected crashes. What am I missing? @duduta, You might be right about this not crashing is just us being lucky. The hardware this runs on sits in my office. It's just a rapsberry Pi + nucleo. No hardware attached. We are waiting for the PCB to be manufactured and then we'll have full hardware model of our incubator. The deploy step does not need to flash both debug and release. In fact I'd argue this is completely unnecessary. Flashing and then thoroughly testing release build should be sufficient. Please, feel free to branch, fix, and submit a PR. As I mentioned before we do not have an all seeing management, we try to be self-organising, so everyone throws an idea in the air and if there are not objections we implement it. Except perhaps for myself. I only do what's necessary. @FrozenOxide and the rest wouldn't even let me redesign the elevator and pipetter robot so it's prettier. <-- That's an inside joke, btw. I am responsible for hardware and electronics. No time to be fancy. ;-)

Niuslar commented 2 years ago

@duduta, thanks for changing the workflow. You're right, I didn't add the condition that flash_debug should finish before running flash_release, but I think on a self-hosted runner only one job can run at a time. As @Vavat said, maybe flashing debug and release is unnecessary, feel free to change the code to flash release only.

duduta commented 2 years ago

Hi, I updated the workflow so that it now uses the ghcr image when building the binary. On an unrelated note, I noticed that the deploy steps, flash_debug and flash_release, are both deploying on hardware (the same hardware?), potentially at the same time. Steps in workflows are running in different processes, which could run concurrently on a Raspberry, so it shouldn't work or, at best, it might "work" with unexpected crashes. What am I missing? @duduta, You might be right about this not crashing is just us being lucky. The hardware this runs on sits in my office. It's just a rapsberry Pi + nucleo. No hardware attached. We are waiting for the PCB to be manufactured and then we'll have full hardware model of our incubator. The deploy step does not need to flash both debug and release. In fact I'd argue this is completely unnecessary. Flashing and then thoroughly testing release build should be sufficient. Please, feel free to branch, fix, and submit a PR. As I mentioned before we do not have an all seeing management, we try to be self-organising, so everyone throws an idea in the air and if there are not objections we implement it. Except perhaps for myself. I only do what's necessary. @FrozenOxide and the rest wouldn't even let me redesign the elevator and pipetter robot so it's prettier. <-- That's an inside joke, btw. I am responsible for hardware and electronics. No time to be fancy. ;-) @Vavat Oki doky, I'll open a PR about that. I'm relieved to find out there's no other hardware (other than the Raspberry and Nucleo) attached yet, I've been terrified not to mess up anything. Given that I am null at embedded and engineering. "Elevator" ?? "Pipette"?? . I had to google those, that should tell you about my level, haha.

duduta commented 2 years ago

@duduta, thanks for changing the workflow. You're right, I didn't add the condition that flash_debug should finish before running flash_release, but I think on a self-hosted runner only one job can run at a time. As @Vavat said, maybe flashing debug and release is unnecessary, feel free to change the code to flash release only.

@Niuslar You're welcome, it's my pleasure, I'm grateful that I can contribute. As for the self-hosted runner, I think that the possibility for a race condition is the first thing I will test as soon as I set my Raspberry, it's a yummy subject for me.