Postgres alpine

I don't know if we want variants as subdirectory under each version or add the alpine variant as its own version. I went for flatter structure here as it seems simpler.

As far as structure goes, I'd prefer to stay consistent with the other repos and stick the variants as subdirectories.
Relevant diff: (for easier review)
--- Dockerfile	2016-01-28 12:44:39.611831695 -0800
+++ /dev/fd/63	2016-01-29 13:01:40.760263290 -0800
@@ -1,40 +1,71 @@
 # vim:set ft=dockerfile:
-FROM debian:jessie
+FROM alpine:3.3

 # explicitly set user/group IDs
-RUN groupadd -r postgres --gid=999 && useradd -r -g postgres --uid=999 postgres
-
-# grab gosu for easy step-down from root
-RUN gpg --keyserver ha.pool.sks-keyservers.net --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4
-RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates wget && rm -rf /var/lib/apt/lists/* \
-	&& wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/1.2/gosu-$(dpkg --print-architecture)" \
-	&& wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/1.2/gosu-$(dpkg --print-architecture).asc" \
-	&& gpg --verify /usr/local/bin/gosu.asc \
-	&& rm /usr/local/bin/gosu.asc \
-	&& chmod +x /usr/local/bin/gosu \
-	&& apt-get purge -y --auto-remove ca-certificates wget
+#RUN adduser -S -G postgres -u 999 postgres

 # make the "en_US.UTF-8" locale so postgres will be utf-8 enabled by default
-RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \
-	&& localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
 ENV LANG en_US.utf8

 RUN mkdir /docker-entrypoint-initdb.d

-RUN apt-key adv --keyserver ha.pool.sks-keyservers.net --recv-keys B97B0AFCAA1A47F044F244A07FCC7D46ACCC4CF8
-
 ENV PG_MAJOR 9.5
-ENV PG_VERSION 9.5.0-1.pgdg80+2
+ENV PG_VERSION 9.5.0
+ENV PG_SHA256 f1c0d3a1a8aa8c92738cab0153fbfffcc4d4158b3fee84f7aa6bfea8283978bc

-RUN echo 'deb http://apt.postgresql.org/pub/repos/apt/ jessie-pgdg main' $PG_MAJOR > /etc/apt/sources.list.d/pgdg.list

-RUN apt-get update \
-	&& apt-get install -y postgresql-common \
-	&& sed -ri 's/#(create_main_cluster) .*$/\1 = false/' /etc/postgresql-common/createcluster.conf \
-	&& apt-get install -y \
-		postgresql-$PG_MAJOR=$PG_VERSION \
-		postgresql-contrib-$PG_MAJOR=$PG_VERSION \
-	&& rm -rf /var/lib/apt/lists/*
+# configure options taken from:
+# https://anonscm.debian.org/cgit/pkg-postgresql/postgresql.git/tree/debian/rules?h=9.5
+RUN set -x \
+	&& apk add --no-cache --virtual .build-deps \
+		su-exec \
+		bash \
+		bison \
+		curl \
+		flex \
+		gcc \
+		krb5-dev \
+		libc-dev \
+		libedit-dev \
+		libxml2-dev \
+		libxslt-dev \
+		make \
+		openldap-dev \
+		openssl-dev \
+		perl \
+		perl-dev \
+		python3-dev \
+		tcl-dev \
+		util-linux-dev \
+		zlib-dev \
+	&& curl -fSL "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2" -o postgresql.tar.bz2 \
+	&& echo "$PG_SHA256  postgresql.tar.bz2" | sha256sum -c - \
+	&& mkdir -p /usr/src \
+	&& tar -jxf postgresql.tar.bz2 -C /usr/src \
+	&& rm postgresql.tar.bz2 \
+	&& cd /usr/src/postgresql-$PG_VERSION \
+	&& ./configure \
+		--enable-integer-datetimes \
+		--enable-tap-tests \
+		--enable-thread-safety \
+		--prefix=/usr/local \
+		--with-libedit-preferred \
+		--with-openssl \
+		--with-uuid=e2fs \
+	&& make -j$(getconf _NPROCESSORS_ONLN) world \
+	&& make install-world \
+	&& make -C contrib install \
+	&& runDeps="$( \
+		scanelf --needed --nobanner --recursive /usr/local \
+			| awk '{ gsub(/,/, "\nso:", $2); print "so:" $2 }' \
+			| sort -u \
+			| xargs -r apk info --installed \
+			| sort -u \
+	)" \
+	&& apk add --virtual .postgresql-rundeps $runDeps su-exec \
+	&& apk del .build-deps \
+	&& cd / && rm -rf /usr/src/postgresql-* /usr/local/include/* \
+	&& find /usr/local -name '*.a' -delete

 RUN mkdir -p /var/run/postgresql && chown -R postgres /var/run/postgresql

--- docker-entrypoint.sh	2016-01-28 12:44:39.608831780 -0800
+++ /dev/fd/63	2016-01-29 13:02:19.922170280 -0800
@@ -1,5 +1,4 @@
-#!/bin/bash
-set -e
+#!/bin/sh -e

 set_listen_addresses() {
 	sedEscapedValue="$(echo "$1" | sed 's/[\/&]/\\&/g')"
@@ -11,12 +10,12 @@
 	chmod 700 "$PGDATA"
 	chown -R postgres "$PGDATA"

-	chmod g+s /run/postgresql
-	chown -R postgres /run/postgresql
+	chmod g+s /var/run/postgresql
+	chown -R postgres /var/run/postgresql

 	# look specifically for PG_VERSION, as it is expected in the DB dir
 	if [ ! -s "$PGDATA/PG_VERSION" ]; then
-		gosu postgres initdb
+		su-exec postgres initdb

 		# check password first so we can output the warning before postgres
 		# messes it up
@@ -47,7 +46,7 @@

 		# internal start of server in order to allow set-up using psql-client
 		# does not listen on TCP/IP and waits until start finishes
-		gosu postgres pg_ctl -D "$PGDATA" \
+		su-exec postgres pg_ctl -D "$PGDATA" \
 			-o "-c listen_addresses=''" \
 			-w start

@@ -77,17 +76,13 @@
 		for f in /docker-entrypoint-initdb.d/*; do
 			case "$f" in
 				*.sh)  echo "$0: running $f"; . "$f" ;;
-				*.sql)
-					echo "$0: running $f";
-					psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" < "$f"
-					echo
-					;;
+				*.sql) echo "$0: running $f"; psql --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" < "$f" && echo ;;
 				*)     echo "$0: ignoring $f" ;;
 			esac
 			echo
 		done

-		gosu postgres pg_ctl -D "$PGDATA" -m fast -w stop
+		su-exec postgres pg_ctl -D "$PGDATA" -m fast -w stop
 		set_listen_addresses '*'

 		echo
@@ -95,7 +90,7 @@
 		echo
 	fi

-	exec gosu postgres "$@"
+	exec su-exec postgres "$@"
 fi

 exec "$@"

I was curious about the change from gosu to su-exec? Is that indeed the recommended way when working with alpine?

See https://github.com/docker-library/redis/pull/40#issuecomment-169916910
for more discussion on that point.

Thanks @tianon I also share your concerns about the switch as also prefer consistency. However happy that the switch will only happen after parity tests. Thx for taking the time, I know your busy!

Why don't you use upstream package instead of building form source? Alpine Linux already has postgres package available (https://pkgs.alpinelinux.org/package/main/x86_64/postgresql). Are there any reasons for not using that package? I'm just curious.

rebased with variants in subdirs

I was testing out the fpm alpine variant and I think there is an issue with the the following code:
modules=""
for module; do
	if [ -z "$module" ]; then
		continue
	fi
	if [ -f "$module.so" ] && ! [ -f "$module" ]; then
		# allow ".so" to be optional
		module="$module.so"
	fi
	if ! [ -f "$module" ]; then
		echo >&2 "error: $(readlink -f "$module") does not exist"
		echo >&2
		usage >&2
		exit 1
	fi
	modules="$modules $module"
done

When running docker-php-ext-enable + install and going to: /usr/local/etc/php/conf.d/
-rw-r--r--   13 root     root            17 Feb 18 06:18 docker-php-ext- gd.ini
-rw-r--r--   13 root     root            23 Feb 18 06:18 docker-php-ext- mbstring.ini
-rw-r--r--   13 root     root            21 Feb 18 06:18 docker-php-ext- mcrypt.ini
-rw-r--r--    7 root     root            21 Feb 18 06:25 docker-php-ext- mysqli.ini
-rw-r--r--    7 root     root            24 Feb 18 06:26 docker-php-ext- pdo_mysql.ini
-rw-r--r--    7 root     root            24 Feb 18 06:26 docker-php-ext- pdo_pgsql.ini
-rw-r--r--    7 root     root            20 Feb 18 06:26 docker-php-ext- pgsql.ini
-rw-r--r--    7 root     root            21 Feb 18 06:26 docker-php-ext- xdebug.ini
-rw-r--r--   13 root     root            18 Feb 18 06:18 docker-php-ext- zip.ini

You can notice there is whitespace before the extension. This whitespace is also present when checking if library is already enabled so that check won't ever work either.

@sylus i assume your comment was supposed for the php-alpine pull request and not the postgres.
But yes looks like you are right. fix is on the way.

@ncopa yes sorry about that :) thx so much for taking a look :)

Could this commit be merged soon?
alpine:3.3 is now the default base image for docker, as per shykes which means that it's likely going to be present on the image cache on each vm/host.

@gittycat, We are looking into it. As for the "switching the Docker official image library from ubuntu to Alpine" as stated by Solomon that is misleading: most are based on Debian and there is no "switching" to Alpine, the default is still Debian.  What we are doing is adding Alpine Linux based variants so that if a user wants a slimmer base they can use the Alpine based images with the caveats linked on their descriptions like golang.

What's Alpine's backport policy for things like su-exec?  Any way we could get su-exec 0.2 into Alpine 3.3, or do we need to wait for Alpine 3.4?

The other easy option I see would be to just stick with gosu for now, and switch to su-exec once Alpine 3.4 comes out. :+1:

The backport policy is "don't break things for existing users". I don't think there are many su-exec users, and the 0.2 release can be considered as a bug-fix. I'll cherry-pick it for 3.3-stable.

su-exec-0.2 was pushed to alpine 3.3-stable

What's the crack for this PR guys!? are we gonna merge it? or is it on hold for now? it will be nice to see a Alpine flavour for  Postgres cheers!

At least the PR would probably need to be updated from 9.5.0 to 9.5.2

Excited for this to get in ^_^

Would love to see this get merged. 👍 Any updates on getting this merged with upstream?

I have been using ncopa's build for a while now without issue. If that data point helps. ^_^

Is the on disk format unchanged? Can I mount the same data to the alpine based image or do I have to do a dump and restore?

I was also using @ncopa's image and it works for me. What are the reasons there is still no alpine image of postgresql? Is this project dead or Docker is planing to do things the other way? Maybe there are some issues to be resolved?

@tianon whats the blocker here?

I'm with @ptman, what are the implications for existing postgres users? Is this a breaking change in some way? What about existing initd script files in downstream images?

@Starefossen , there is no change regarding init scripts contained in postgresql docker image since they are independent of distribution provided scripts. Also there should be no difference in internal representation of data base files between Alpine and Debian images (within the same version) but it's always good practice to have backup before doing migration.

With the release of Alpine 3.4, the creation of a postgres image is now even simpler.  I wrote my own one-off build at deinspanjer/docker-postgres95-alpine34, but the code might be of interest to @ncopa for this PR as well.

I think the main concern here would be the same as the comment from @yosifkit over in https://github.com/docker-library/mariadb/issues/53#issuecomment-211571534:

Yeah, mariadb, mysql, and percona use Debian packages that are provided by upstream directly, so I think it is unwise that we provide something that they do not support.

Since we're not building from source (per upstream's recommendations), do we have anything from them noting that they do officially support Alpine, and that compiling from source is the recommended means by which we should obtain the latest releases of PostgreSQL in such an environment?
If we can't find something suitable which makes it clear upstream will support this configuration, it would be prudent to post on the pgsql-pkg-docker mailing list to solicit comments (upstream is reasonably active there).

Just for my own edification and potentially others what exactly are the main benefits of preferring packages over building from source. I have always found particularly for alpine + musl that building from source seems to be the recommended workflow.

In the case of the official images, it's not necessarily about "benefits",
but more about upstream preference (and thus upstream's willingness to
support our endeavors).  Many upstreams are only willing to officially
support binary artifacts which they've built themselves (I don't believe
PostgreSQL is such an upstream, but we do try to strive for sticking as
closely to upstream's preferences as we can, especially since we've had
issues with that in the past).

That being said, it likely is worth noting that Dockerfiles which pull
from pre-built packages do build significantly faster on average,
which IMO should be considered a strong benefit.

Speaking to the example of NGINX, that image is maintained directly by
a team from upstream, so they can speak with authority as to what
they're going to be willing to support. :smile:

Ah! Thank you so much for this, greatly appreciate you taking the time to help explain ^_^

I have posted the question in the mailing list @ https://www.postgresql.org/list/pgsql-pkg-docker/2016-06/

FYI - No issues encountered so far in my local testing with this PR + alpine:3.4.

I think the discussion around compiling from source vs. installing Alpine's packages is rather overblown, because this it the only patch Alpine 3.3 applies:
--- ./src/bin/initdb/initdb.c.orig	2013-09-09 14:38:21.712409752 +0000
+++ ./src/bin/initdb/initdb.c	2013-09-09 14:40:19.453755379 +0000
@@ -3652,14 +3652,6 @@
 	strlcpy(bin_dir, argv[0], sizeof(bin_dir));
 	get_parent_directory(bin_dir);

-	printf(_("\nSuccess. You can now start the database server using:\n\n"
-			 "    %s%s%spostgres%s -D %s%s%s\n"
-			 "or\n"
-			 "    %s%s%spg_ctl%s -D %s%s%s -l logfile start\n\n"),
-	   QUOTE_PATH, bin_dir, (strlen(bin_dir) > 0) ? DIR_SEP : "", QUOTE_PATH,
-		   QUOTE_PATH, pgdata_native, QUOTE_PATH,
-	   QUOTE_PATH, bin_dir, (strlen(bin_dir) > 0) ? DIR_SEP : "", QUOTE_PATH,
-		   QUOTE_PATH, pgdata_native, QUOTE_PATH);
-
+	printf(_("\nSuccess.\n\n"));
 	return 0;
 }

and this is the only patch Alpine 3.4 applies:
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c
index feeff9e..e6a4536 100644
--- a/src/bin/initdb/initdb.c
+++ b/src/bin/initdb/initdb.c
@@ -3641,10 +3641,7 @@ main(int argc, char *argv[])
 	strlcpy(bin_dir, argv[0], sizeof(bin_dir));
 	get_parent_directory(bin_dir);

-	printf(_("\nSuccess. You can now start the database server using:\n\n"
-			 "    %s%s%spg_ctl%s -D %s%s%s -l logfile start\n\n"),
-	   QUOTE_PATH, bin_dir, (strlen(bin_dir) > 0) ? DIR_SEP : "", QUOTE_PATH,
-		   QUOTE_PATH, pgdata_native, QUOTE_PATH);
+	printf(_("\nSuccess.\n\n"));

 	return 0;
 }

Neither patch should impact how PostgreSQL operates.
I didn't see any response on the Postgres mailing list to their support for compiling from source vs. using Alpine packages, so I assume they don't have an opinion either way.
Personally, for what it's worth, I would prefer to use the Alpine packages, both because they make building images faster and they would be more aware of how their package integrates with the rest of their OS.

Agreed I don't think we are going to be getting a response from the mailing list. I'd really like this issue to be closed though as it has been stalled for quite a while. Would be great to have an alpine based postgresql image as it would be my last debian derived container to remove.

Reduced size is a nice benefit, but I think the biggest benefit is the reduced attack surface.  IOW, better security because there are fewer things that need to be patched.

Alpine also uses PaX, which helps prevent some buffer overflow attacks and direct code execution, grsecurity patches, and compiles their packages as position-independent executables with stack-smashing protection.
So when used for web development, this makes Postgres running on Alpine more difficult to successfully attack than, say, your run-of-the-mill Debian distribution.

You will only benefit from PaX when you run a kernel with the grsecurity patch. If you run the alpine postgresql package in docker but not use grsecurity patched kernel on the host, then you'll not have the PaX benefits.

Oh right, I forgot containerization != virtualization. 😆
But the PIE executables and the stack-smashing protection should still work.

So potential next steps given the above?
I really don't want to see this issue queue  stalled for another few months. Especially since the P.R. works great.

I suspect it would need to be updated to support postgres 9.6 now that it has been released.

Ok, I did a little research on what operating systems are supported by Postgres (since that is my major reservation in adding an Alpine Linux based version).  I found that "PostgreSQL can be expected to work on these operating systems: Linux (all recent distributions)" source, so I think it is fair to move this forward.  (cc @tianon)
It looks like #210, is just a copy and update of this PR, so @tianon and I will review the two PRs and hopefully get something merged soon. :tada:

After playing a bit, I can see exactly why you didn't include Perl, Python, or TCL support...  This PR clocks in an image at ~43.54MB, but with Perl, Python, and TCL enabled, it goes up to ~166.5MB. :sweat_smile:


✨ Use HttpClient instead of WebClient

Android clients have not been able to load the store since at least May 8th.
Debugging shows:
{System.Net.WebException: Error: TrustFailure (Authentication failed, see inner exception.) ---> System.Security.Authentication.AuthenticationException: Authentication failed, see inner exception. ---> Mono.Btls.MonoBtlsException: Ssl error:1000007d:SSL routines:OPENSSL_internal:CERTIFICATE_VERIFY_FAILED

There are many threads online related to this issue, especially since Let's Encrypt changed root chains a few years ago. I cannot verify this, but I must assume Cloudflare also changed something on their end when renewing our osu-stream.com certificate (so the issue might be happening since April 22nd).
The solution is "simply" to use Android's TLS implementation rather than the legacy one (Mono's?), however this doesn't appear to be possible when using WebClient (I couldn't find any related documentation).
So I rewrote DataNetRequest to use HttpClient instead of WebClient. We lost the upload progress feature, but this doesn't appear to be used anywhere. Also had to bump the desktop project from .NET Framework 3.5 to .NET Framework 4.5.

@ThePooN are you able to organise a deploy to the play store with new changes?


User warning about the time needed for PeerOS to load management

Expected Behavior

Right after how Vagrant is done with peer creation process, there should be a message telling that it takes time to load management. Only after that user can enter Subutai Console using the peer parameters.
Current Behavior

Vagrant says that everything is completed, but actually not yet.
Possible Solution

We can just add message telling user that it will take some time and this is not a big deal.
Steps to Reproduce

Start peer creation process through Control Center
Vagrant will notify user about the completion of the process
Try to enter Subutai Console using the parameters of the peer
And here you fail, because PeerOS needs time to load management

fixed on master.

fixed on prod.


Other users can't see Scene Presets

I am having trouble getting other users to see Scene Presets in their sidebars, as well as through a dashboard button that links to that page via nav. Is this intentional? Would love to let my other users set scenes in our home, but only I, the admin our our HAOS instance, can see it.

Is this intentional?

Nope. Thanks for pointing that out
It's just a setting that was set incorrectly likely because I copy-pasted stuff from components that should be admin only.
I then didn't notice because I'm the only user of my instance. Super simple fix:
https://github.com/Hypfer/hass-scene_presets/commit/6d3458512db78163b2b32ce67cf6562c06e13932
and fixed with 1.2.1

Thanks!


How does dl8.5 work with more than 2 classes?

Hi,
I'd love to use pydl8.5 with one of my projects. However, it is not immediately obvious how to binarize the dataset or how to use the decision trees for more than 2 classes. Am I missing something or is it not possible to use dl8.5 for more than 2 classes?

Nice, so I don't have to binarize manually? Pydl8.5 will handle it on its own?

You have to binarize your data before running PyDL8.5. I described you in the first paragraph of my answer, how you can do this.


Implement the blocking hal api for SPIM.

This is a partial impl of #136

Ok should be ready for review again :)

The issues I commented also apply to the spi::Write impl, it seems you only updated htem in Transfer.

Ash sorry I missed that, will address.
On Wed, 5 May 2021, 18:47 Dario Nieuwenhuis, @.***>
wrote:

The issues I commented also apply to the spi::Write impl, it seems you
only updated htem in Transfer.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/embassy-rs/embassy/pull/158#issuecomment-832886051,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAKT4XSMEFLZMDV7ME7WUB3TMGADJANCNFSM44E224ZA
.

Ok they should be in both transfer and write now.

Awesome, thank you! :)


Incremental compilation with literals in 3.4

Incremental Compilation, the Java Library Plugin, and other performance features in Gradle 3.4 said as follows:

Similarly, if the constant is changed, but that the dependents didn’t have a literal in their bytecode of the old value, we don’t need to recompile them: we would only recompile the classes that have candidate literals.

To find the usage of a literal, using its old value doesn't work if it is used for calculation and the result is inlined.
This was originally asked on the blog: https://blog.gradle.org/incremental-compiler-avoidance#comment-3178668770
/cc @melix

Thanks @izeye

Actually it seems we don't have the problem. Even if Java inlines the constant, class A is still visible in the constant pool table.
I made a simple test, and changing the constant value in A triggers a recompilation of B:

Incremental compilation of 2 classes completed in 0.034 secs.

I'm not sure why, but it doesn't appear to be that simple (maybe it depends on the compiler version). The test case linked above fails.

As of JDK-7153958, which was included in Java 8, javac includes a reference to the the constant field in the dependent class' constant pool.  So, I think this bug seems to be valid for javac <7, and the constant tracking infrastructure seems unnecessary for javac >8.

It doesn't seem to be the case on all versions of Java 8, at least. I ran 8u91 and the test case still fails. Which is strange considering that it's supposed to be fixed in b68.

So it's actually a combination of 2 bugs:

with Java < 8, we don't recognize that A was referenced
the compile classpath snapshotter, which computes the ABI of a component, ignores the constant values of API members

The latter is pretty serious.

See #1476


fixed focus oak-d-lite doesn't throw errors on autofocus APIs or declare it is fixed focus

I got my oak-d-lite fixed focus cameras and discovered that they do not id themselves as fixed nor do the autofocus apis throw errors.
At a minimum, I believe autofocus apis/commands to fail or throw errors.
Setup

Microsoft Windows [Version 10.0.19044.1466]
VS2019 v16.11.8
depthai-core v2.13.3 + xlink move/thread fixes
oak-d-lite fixed focus

Repro

cmake config and build depthai-core for x64, debug, shared lib
cmake install
create main app to include code similar to below
point main app config to install location
config and build main app
Run main app and also watch console/debug output

rgbCamera->initialControl.setAutoFocusMode(dai::CameraControl::AutoFocusMode::CONTINUOUS_VIDEO);
device = std::make_unique<dai::Device>(config, DeviceInfo);

Result
App runs.
No exceptions, errors, nor console/debug log output indicating that the autofocus apis will not and did not work on the fixed focus camera.
Expected
API to throw exceptions or return errors that indicate the specific problem of "no autofocus on this camera". I consider this to be the same level of error as calling an API for a sensor that doesn't exist on the device.
Notes
The way in which the API failure will likely be different for each api or scenario. For example

rgbCamera->initialControl.setAutoFocusMode() is called before the camera pipeline starts. So without prior knowledge of the specific cameras abilities, no error is possible here. Caveat, future knowledge of the sensor might be possible with #285
std::make_unique<dai::Device>() is a good place to throw exception or return an error. However, there are many errors that can occur here (no autofocus, no IMU, etc.). How does an app discern which error has occurred? I would prefer specific exceptions for each error case. If not that, then at a minimum, the exception::what() text should be specific, customer ready language, and unchanging.
later runtime calls to APIs like dai::CameraControl::setAutoExposureRegion() should throw exceptions since the knowledge is readily available that the camera has no autofocus. One doesn't even need to spin up an XLink packet since the host-side depthai-core code can cache the knowledge that there is no autofocus.

Workarounds?
I do not know of any workarounds.
Is there any command or api that can detect a fixed focus color camera? Something that declares it or will fail/throw?
If such exist, then I can probe and persist the knowledge.

Thanks!  CC: @alex-luxonis and @saching13 - I'm not sure if we declared this in the EEPROM that they're fixed focus.  I didn't think of it at least.

Comparing my oak-d (self calibrated with cali script) and oak-d-lite (factory calibrated)...

OAK-D eeprom::cameradata::rgb::lensPosition=135. That was the default autofocus value in the cali script
OAK-D-Lite ...::lensPosition=0

Maybe I can risk assuming that any oak-d-lite that has a lensPosition=0 is a fixed focus?
Sure it is possible someone custom calibrates using the cali scripts and uses a custom focus value...but that is probably a very small set of people. 🤷♀

Maybe I can risk assuming that any oak-d-lite that has a lensPosition=0 is a fixed focus?
Yes.
So there was no programmatic way to detect that. But during calibration, it is set to zero. Since all the autofocus will have a number for lensPosition we can just go with lensPosition = 0 being the Fixed focus. Will add a new field for this when we do another major upgrade for EEPROM data.

Sure it is possible someone custom calibrates using the cali scripts and uses a custom focus value...but that is probably a very small set of people. woman_shrugging

Yes. But as of now the script in the main cannot be used for OAK-D-Lite Calibration.

Got it. I've implemented the probing workaround.

closing as my local probing continues to work.
Also, newest depthai-core using a series of camera name (e.g. "color") to camera board enum can be use to query dai::CameraFeatures::hasAutofocus


Grab can't determine filename with an URL where this looks pretty easy

URL in question: https://dl.google.com/go/go1.11beta1.src.tar.gz
Fails with both cmd/grab and using grab as a library, wget can correctly determine the filename.
grab output:
./grab https://dl.google.com/go/go1.13beta1.src.tar.gz
Downloading 1 files...
Error downloading https://dl.google.com/go/go1.13beta1.src.tar.gz: no filename could be determined
Finished 0 successful, 1 failed, 0 incomplete.

@onodera-punpun This is because dl.google.com is returning Content-Disposition header without any filename directive!


addOutput notifications throws clientConfig.notifications.channels is not iterable

Environment information
System:
  OS: macOS 14.3.1
  CPU: (8) arm64 Apple M1
  Memory: 161.30 MB / 16.00 GB
  Shell: /opt/homebrew/bin/fish
Binaries:
  Node: 20.11.1 - ~/.local/share/nvm/v20.11.1/bin/node
  Yarn: 3.6.4 - ~/.local/share/nvm/v20.11.1/bin/yarn
  npm: 10.2.4 - ~/.local/share/nvm/v20.11.1/bin/npm
  pnpm: 8.15.4 - ~/Library/pnpm/pnpm
NPM Packages:
  @aws-amplify/backend: 0.13.0-beta.15
  @aws-amplify/backend-cli: 0.12.0-beta.17
  aws-amplify: 6.0.27
  aws-cdk: 2.136.0
  aws-cdk-lib: 2.136.0
  typescript: 5.4.4
AWS environment variables:
  AWS_STS_REGIONAL_ENDPOINTS = regional
  AWS_NODEJS_CONNECTION_REUSE_ENABLED = 1
  AWS_SDK_LOAD_CONFIG = 1
No CDK environment variables

Description
using the following
backend.addOutput({
  notifications: {
    amazon_pinpoint_app_id: "test",
    aws_region: "test",
  },
});

throws
Amplify configuration could not be generated.
clientConfig.notifications.channels is not iterable

marking as a bug to improve the type for notifications outputs, error message


Trained model

Hi, could you provide some checkpoints of already trained model?

Would you please check out our new release: https://github.com/memray/OpenNMT-kpg-release
Both datasets and checkpoints are provided.


Sofia-SIP from unimrcp-deps-1.5.0 fails to build on debian 9.1 with openssl 1.1.0f (25 May 2017)

Hi,
I didn't see this issue mentioned anywhere else, but here on my debian 9.1 box with openssl 1.1.0f installed, The build of unimrcp-deps 1.5.0 fails with this error message:
tport_tls.c: In function ‘tls_post_connection_check’:
tport_tls.c:596:33: error: dereferencing pointer to incomplete type ‘X509 {aka struct x509_st}’
tls_parse_extensions(tls, cert->cert_info->extensions);
^~
Makefile:1080: recipe for target 'tport_tls.lo' failed
After some digging, it seems that yes, X509 aka struct x509_st is not defined anywhere in the headers provided with the debian package of openssl 1.1.0f
Testing the same on debian 8.9 with openssl 1.0.1t works flawlessly.
Edit:
On debian 9.1 openssl 1.1.0f, the way to get this working is to replace cert->cert_info->extensions with X509_get0_extensions(cert).
Edit 2:
If anyone would like to incorporate that, the full fix is to replace the line
tls_parse_extensions(tls, cert->cert_info->extensions);

with
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
  tls_parse_extensions(tls, X509_get0_extensions(cert));
#else
  tls_parse_extensions(tls, cert->cert_info->extensions);
#endif

Thanks for not only submitting the problem but also providing a fix.
I personally have not tried to build against newer openssl 1.1.0f, but will apply your change when have got some spare time to verify it.
Another temporary option to consider would be not to use openssl by passing --without-openssl to ./configure.

How can I pass  --without-openssl to  build-dep-libs.sh?
ubuntu 18.04 no longer compile due to this issue.

Not to build-dep-libs.sh itself, but to ./configure of Sofia-SIP. See build_sofia() inside the script.

Would be nice to see a patch now that debian 9 is getting more common 👍


add blocklist

Description
(Brief description on what this PR is about)
Checklist
Essentials
Please feel free to remove inapplicable items for your PR.

[ ] The PR title starts with [MXNET-$JIRA_ID], where $JIRA_ID refers to the relevant JIRA issue created (except PRs with tiny changes)
[ ] Changes are complete (i.e. I finished coding on this PR)
[ ] All changes have test coverage:
Unit tests are added for small changes to verify correctness (e.g. adding a new operator)
Nightly tests are added for complicated/long-running ones (e.g. changing distributed kvstore)
Build tests will be added for build configuration changes (e.g. adding a new build option with NCCL)
[ ] Code is well-documented:
For user-facing API changes, API doc string has been updated.
For new C++ functions in header files, their functionalities and arguments are documented.
For new examples, README.md is added to explain the what the example does, the source of the dataset, expected performance on test set and reference to the original paper if applicable
Check the API doc at http://mxnet-ci-doc.s3-accelerate.dualstack.amazonaws.com/PR-$PR_ID/$BUILD_ID/index.html
[ ] To the my best knowledge, examples are either not affected by this change, or have been fixed to be compatible with this change

Changes

[ ] Feature1, tests, (and when applicable, API doc)
[ ] Feature2, tests, (and when applicable, API doc)

Comments

If this change is a backward incompatible change, why must this change be made.
Interesting edge cases to note here

Should solve https://github.com/apache/incubator-mxnet/issues/10101, https://github.com/apache/incubator-mxnet/issues/9264

BlockList is necessary.

Hi!
BlockList is useful. Why not merge this PR?

Because Sequential contains BlockList.

@chinakook Thanks.
I don't know it.
mxnet.gluon.nn.Sequential is a serial structure.
python/mxnet/gluon/nn/basic_layers.py#L51
class Sequential(Block):
    [...]
    def forward(self, x):
        for block in self._children.values():
            x = block(x)
        return x

How to use Sequential to implement a parallel structure like multi-column CNN?
Single-Image Crowd Counting via Multi-Column Convolutional Neural Network [Page:4]
I think BlockList is useful.
e.g.
class MCCNN(nn.HybridBlock):
    def __init__(self, num_filter, columns, aggregator, **kwargs):
        super(MCCNN, self).__init__(**kwargs)
        with self.name_scope():
            self.column_blocks = BlockList(self, [get_column(num_filter, kernel_size, dilations) for kernel_size, dilations in columns])
            self.aggregator = get_aggregator(num_filter, aggregator[0], aggregator[1])
            self.conv1x1 = nn.Conv2D(channels = 1, kernel_size = (1, 1), activation = 'relu')
    def hybrid_forward(self, F, x):
        column_outputs = [c(x) for c in self.column_blocks]
        x = F.concat(*column_outputs, dim = 1)
        x = self.aggregator(x)
        x = self.conv1x1(x)
        x = F.squeeze(x, axis = 1)
        return x

And here is my BlockList implementation.
def BlockList(self, block_list):
    block_names = []
    for block in block_list:
        assert not hasattr(self, block.name)
        setattr(self, block.name, block)
        block_names.append(block.name)
    class _BlockList:
        def __init__(self, block_names, parent):
            self.block_names = block_names
            self.parent = parent
        def __getitem__(self, i):
            return getattr(self.parent, self.block_names[i])
    return _BlockList(block_names, self)

@chinakook
Thank you! It works.

Should we add BlockList back because most users do not understand the usage of Sequential/HybridSequential as the container? @szha @leezu

OK. I'm not sure if we'd use the same implementation though. Let's track this as a feature request.

It need  two lines of code to implement blocklist:
block = nn.Sequential()
block.add(*lst)


sed: can't read /etc/openvpn/server/tc.key: No such file or directory

sudo bash openvpn.sh --auto

OpenVPN Script
https://github.com/hwdsl2/openvpn-install

Starting OpenVPN setup using default options.

Server IP: .....
Port: UDP/1194
Client name: client
Client DNS: Google Public DNS

Installing OpenVPN, please wait...
+ yum -y -q install epel-release
+ yum -y -q install openvpn openssl ca-certificates tar
+ ./easyrsa --batch init-pki
+ ./easyrsa --batch build-ca nopass
+ ./easyrsa --batch --days=3650 build-server-full server nopass
+ ./easyrsa --batch --days=3650 build-client-full client nopass
+ ./easyrsa --batch --days=3650 gen-crl
+ openvpn --genkey --secret /etc/openvpn/server/tc.key
openvpn.sh: line 675: openvpn: command not found
+ systemctl enable --now<EMAIL_ADDRESS>sed: can't read /etc/openvpn/server/tc.key: No such file or directory

Finished!

The client configuration is available in: /root/client.ovpn
New clients can be added by running this script again.

[root@dns3 ~]# ls -at /etc/openvpn/server/
.  client-common.txt  dh.pem  server.conf  ca.crt  ca.key  crl.pem  server.crt  server.key  easy-rsa  ..
[root@dns3 ~]#

@sec13b Hello! This may be a temporary issue with your server's package repositories, resulting in the openvpn package failing to install on your system. You can check if if it can be installed using:
yum install openvpn

Running the script again can usually fix the problem. If it says OpenVPN is already installed, remove it and try again.


No circular dependencies between Spring beans

Fixing issue #5 will lead to situations where the Spring ApplicationContext cannot initialize because there are circular dependencies.  Switching to constructor injection reveals the underlying problem.
Field injection works around that with placeholders, but we don't want to keep field injection.

One approach is to move methods to other (possibly new) Java classes.  If that helps reduce the number of injected dependencies, even better.
Another approach is to "cheat" and use constructor injection for most of the dependencies.  Then use setter injection for the problematic dependencies.  These setters are @Deprecated with warning comments explaining the problem.

This seems possible.
4.2. Class Dependency Checks
4.7. Cycle Checks
slices()/* (something) */.should().beFreeOfCycles();

7.2. Composing Member Rules
8.4.2. DependencyRules
example-junit4/.../CyclicDependencyRulesTest.no_cycles_by_member_dependencies_between_slices

class ClassOne {

    // This is a simple cycle: 1-2
    @Inject
    private ClassTwo classTwo;

}

class ClassTwo {

    // This is a simple cycle: 1-2
    @Inject
    private ClassOne classOne;

    // This is a longer cycle: 1-2-3
    @Inject
    private ClassThree classThree;

}

class ClassThree {

    // This is a longer cycle: 1-2-3
    @Inject
    private ClassOne classOne;

}

interface InterfaceFour { }

class ClassFour implements InterfaceFour {

    // This is effectively a cycle: 4-5
    private InterfaceFive interfaceFive;

}

interface InterfaceFive { }

class ClassFive implements InterfaceFive {

    // This is effectively a cycle: 4-5
    private InterfaceFour interfaceFour;

}


ObjectIdleTime accepts one key.

Updates https://github.com/go-redis/redis/pull/436

This is of course relevant for all Object* commands:
ObjectRefCount and ObjectEncoding should be fixed too..


Fix "assignment to entry in nil map" Error in GetFriendshipStatusCall.Do Method

In the GetFriendshipStatusCall.Do method, there is a bug that causes a runtime panic with the error message "assignment to entry in nil map". This error occurs when trying to set a value in the urlQuery map, which has been declared but not initialized.
Here is the problematic code:
func (call *GetFriendshipStatusCall) Do() (*GetFriendshipStatusResponse, error) {
	var urlQuery url.Values
	urlQuery.Set("access_token", call.accessToken)
	...
}

It is fixed by #9


[Bug] inconsistency look field Color

Bug report
What I did
Create multiple color picker in the same page.
            [
                'name'    => 'color',
                'label'   => trans('backpack.color'),
                'type'    => 'color',
                'default' => '#df5f52',
            ],
            [
                'name'    => 'color1',
                'label'   => trans('backpack.color'),
                'type'    => 'color',
                'default' => '#df5f52',
            ],
            [
                'name'    => 'text_color',
                'label'   => trans('backpack.color'),
                'type'    => 'color',
                'default' => '#df5f52',
            ],
            [
                'name'    => 'background_color',
                'label'   => trans('backpack.color'),
                'type'    => 'color',
                'default' => '#df5f52',
            ],

What I expected to happen
That all color picker work and display the same
What happened

What I've already tried to fix it
I don't know the reason but if the input is has the name "color" is applying extra styles.
The extra styles are on the resources/views/crud/fields/color.blade.php
https://github.com/Laravel-Backpack/CRUD/blob/79449aec5a2affd2bf6b08c0842459045cbab0f4/src/resources/views/crud/fields/color.blade.php#L40C4-L50C13
Is it a bug in the latest version of Backpack? Yes
After I run composer update backpack/crud the bug... is it still there?
Backpack, Laravel, PHP, DB version
When I run php artisan backpack:version the output is:

hi @adriallongarriu thanks for reporting this issue we will check and fix as is needed.
Cheers.

@jorgetwgroup i creted a pull request with a fix.


SPI/SD Errors ArduCAM_Mini_2MP_TimeElapse2SD

I'm using the example referenced in the issue title. My SD card module is connected to the same MOSI, MISO, and SCK as the Arducam 2MP Plus. The SD_CS is pin 9, the Cam_CS is 7.
The Serial prints for my code is below:
ArduCAM Start!
SPI interface Error!
SPI interface Error!
SPI interface Error!
SPI interface Error! -----At this point I disconnected the 5V line from the SD module. I've found out this triggers the SPI interface for the camera to be detected
SPI interface OK.
ACK CMD OV2640 detected.
SD Card detected. ------ I put the 5V line back into the SD module so it could be read.
start capture.
CAM Capture Done.
capture total_time used (in miliseconds):1
The fifo length is :8388607 -----From my research on the forums, this value for a fifo length is an invalid value
Over size.
save capture total_time used (in miliseconds):4
----Code crashes before trying to open or save the file
start capture.
----Code pauses here until I disconnect the 5V line from the SD module again
CAM Capture Done.
capture total_time used (in miliseconds):-16018
The fifo length is :271368
----While the SD is disconnected the Camera gives a valid fifo length reading. However, since there is no supply to the SD module the file saving will not work
File open failed
It seems to me there is an issue with having multiple slaves on the same loop for this code.
Do I have to write the SD_CS low for it to activate while the camera is trying to save?
Why does the Camera not respond when the SD module has power?
The SD module I am using is a HiLetGo SD Module. I've tested both independently and they work.

Hi，
Due to the poor design of some SD card slots, the SPI bus is not released, which cause the bus can't connect multi device. So I advise you change another SD card slot.

Thanks for the reply!
Is there an SD module that you can recommend for use with Arducam?
Do you think it would be possible for me to use a switch or transistor to release the SPI bus of the poor SD module that I have?

Hi,
I advise you use the Arducam Arduino UNO board, we don’t have a single SD module.
I think it is possible that use a switch or transistor to release the SPI bus of the poor SD module.

Hi,
I am facing exact same problem. I need to use Arduino Nano BLE sense with ArducCam and SD card because of in-built microphone. I am using HiLetGo SD card module. Any suggestion to resolve the issue? I read above about a switch but not sure how to use it.


Label Node Inspector: Resetting Visible Characters control sets wrong default on Visible Ratio control

Godot version
4.2.beta
System information
Windows 11
Issue description
Label has two controls, Visible Ratio (normalized 0..1 to show the given portion of the label's characters) and Visible Characters (integer count of characters shown, -1 means all)
The two controls are linked. (changing one changes the other)
When resetting the Visible Ratio to its default (1.0) by clicking the icon, Visible Characters is also reset to its default (-1).
When resetting Visible Characters to its default (-1), Visible Ratio is erroneously set to 0, which results in the inspector (and possibly the control) to be in an invalid state.
Steps to reproduce

Create a Label, add some text.

Slide the Visible Ratio control to about 0.5

Observe: Visible Characters changes to a rounded fraction of the visible chars.

Click the "Reset" cirular arrow next to the Visible Ratio control.

Observe: Visible Characters is reset to -1 ✅

Repeat Step 2.

Click the "Reset" circular arrow next to the Visible Characters control.

Observe: The text fully shows again

Observe: Visible Ratio slider is erroneously set to 0 (should be set to its default, 1.0) ❌

Save project, close godot, reopen project
Observe: The Label is now invisible ❌, because what was serialized was the wrong ratio override. The dependent Visible Characters control was changed (even though user intent was the exact opposite - to have it reset to -1, and thus Visible Ratio to 1.0, not 0.0)

Minimal reproduction project
Please note that since this project is "saved" and godot was closed, it will already be in state step 11 with the 3rd label being fully invisible. The screenshot above shows the label before saving & closing.
label-bug-repro.zip

There's a related issue from the same code for 0 length strings (or lengths smaller than Visible Characters), which then sets Ratio to 1.0.

Create a label with no text (empty string)
Set the number of visible characters to 4
Observe: Ratio is set to 1.0 ✅ but it is also shown as dirty/resettable to "default" ❌
Change string to something longer than 4 characters
Observe: only the expected number of characters will be shown ✅
Observe: even as the string grows, the ratio slider will stay at 1.0❌, even if the string is longer than 4.
save project, close godot, reopen project
Observe that now the full string is erroneously shown. ❌

Seems like the "1.0" value in Ratio has been serialized, and thus upon loading, the full string is rendered (opposite behaviour of original bug, same root cause)

I'm working on fixes to these issues. I have most of them resolved.
However, Editing the text changes the character count based on the ratio.
This is possibly against intuitive intent and is technically a minor compatibility break.
Thus I will put it into a separate PR.
There are a few rough edges with the default value detection.


Failed to create a new project

I just installed the dependencies, and then runned npm run dev in a tab and npm start in another. The window appeared with a dark background but with no content. When I clicked in the menu Test and then in New project, this error alert popped:

I'm running with Node 7.7.3 and NPM 4.1.2.
I installed the dependencies with yarn in version 0.21.3.
Then I tried to run the same commands through yarn and this way I managed to see it working, but still I couldn't create a new project.

hi there, we're currently addressing this issue and should have a solution up today.
For a temporary workaround, create an empty directory named temp in the lib folder. Cheers!

@JiniHendrix
you mean /library/temp folder? It still does not work. I downloaded the project today.

@JiniHendrix
you mean /library/temp folder? It still does not work. I downloaded the project today.


Optimizer formatting fixes

Fixed some typos and formatting
@madjam @piiswrong @mli Please review and merge.

please fix lint. Please make sure you input method is set to standard english. Non ascii character in code can break a lot of things.


[Bug]: No stream available in Apple TV (Neither in the doorbell ring notification)

What happened?
The doorbell stream works fine on my iPhone, Apple Watch and Macbook, but on Apple TV no matter what I do I can't stream there.
I get the "someone ring the bell" notification but it comes without a screenshot/live feed.
I already tried to restart several times the Apple TV and home bridge, but nothing made it work.
I also have other cameras in my house (with official HomeKit support), those I can stream normally.
Device Type
Doorbell (Supported)
Plugin Version
v2.0.x (Supported)
HomeBridge Version
v1.4.x (Supported)
NodeJS Version
v16 (Supported)
Operating System
Mac OS X 11+ (Supported)
Relevant log output
Nothing gets printed out in the logs when Apple TV tries to show the camera, for some reason it feels like the Apple TV is not even trying, no matter what I do.

Feel free to close this issue if you are 100% sure the problem is on my Apple TV

Hi!
Can you check if you still have issues on the latest beta?
For me at least Apple TV streaming works fine.
Thx!

Hi!
Can you check if you still have issues on the latest beta?
For me at least Apple TV streaming works fine.
Thx!

Ok I'll update to beta 8 and report back in a day or so to see if this issue is resolved.

@cpvbruno then we're back to: please enable debug and send me log-lib.log ;-)

Unknown 2.zip

Sorry the delay 🍻

Most recently when I moved my server from MacBook to raspberry pi the camera begin working again, but now it’s already not working anymore, also, the snapshot when someone rings the bell never works

Sorry the delay 🍻

No problem. I have deleted your zip file, since it could contain some sensitive information. Sorry should have mentioned that earlier. Anyhow I saw that you have not enabled debug mode for the plugin. Could you do that and send me the logs with a new try?
You could send them via discord or we use something like google drive...

I have the file with me, how do you prefer that I share?

Sent in discord

I've updated to latest beta and it seems to work for me now.

I've updated to latest beta and it seems to work for me now.

Further update, the stream has stopped working again however I think I know why. It seems to happen when switching wifi networks. I have two wifi networks 1 with the Pi and all my IoT stuff on and the other is a VPN network which I switch my Apple TV too when required. I switched to my vpn network for for a while after switching back I get no stream from the doorbell (my native HomeKit cameras work though). I have to go into HomeKit settings and remove the doorbell, restart the Apple TV, then add it back, then restart the Apple TV again.

Today out of nowhere it started working again in Apple TV, the only thing that happened was that I was a few days traveling so the Apple TV was off those days. (Maybe this info helps)

And now it stopped working again.

As discussed on discord I don't think this is an issue with the plugin itself. It seems to be more likely a network/HomeKit issue. If you think otherwise let me know. But will close this, since I can't see what else can be done here.


implement testcases for sbi spec section 3.2, 3.3

Deadline 12th Apr 2022

https://github.com/mmoizhussain/riscv-sbi-basic/issues/34

https://github.com/mmoizhussain/riscv-sbi-basic/pull/55


Files copied in unbuffered mode are no closed

Related issue: https://github.com/gulpjs/gulp/issues/910
I'm trying to copy several thousands of images with streaming (to save memory) using vinyl-fs. The code is relatively simple:
var vfs = require('vinyl-fs');
vfs
  .src('source/data/images/*.jpg', { buffer: false })
  .pipe(vfs.dest('dist/vfs'));

The process stops after copying 1985 files (on Windows, less on Fedora 21) of 3000 files. Using Process Explorer (Windows, ~lsof) and  NODE_DEBUG=GFS I found that node never closes the files written to vfs.dest.
How can I enforce the file descriptors to be freed after my last pipe()?

Hmm really interesting. I will take a look at this

Any update on this? Also experiencing an issue where the process stops at round 70MB of usage, it seems to be running out of FD's (windows).

I believe this is fixed by #121 - I think we were trying to open too many file descriptors up front and that killed the process because node seems to handle closing of the stream just fine.


ruby gems packaging: the howto seems not to work

I wanted to package a gem, so I followed the nixpkgs manual on that, but the resulting executable fails with:
/nix/store/p1smzl194057x5ixk5aymkal6cwmjq3j-ruby-2.3.0-p0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- bundler/setup (LoadError)
        from /nix/store/p1smzl194057x5ixk5aymkal6cwmjq3j-ruby-2.3.0-p0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from ./result/bin/fpm:16:in `<main>'

I did this on recent master; details are in the commits: https://github.com/NixOS/nixpkgs/compare/master...vcunat:p/fpm.
I know very little about ruby stuff; perhaps someone else knows what's wrong: @cstrahan, @zimbatm.

I was able to reproduce the issue and am working on a fix. I had bundler installed in my user GEM_HOME so didn't notice the problem until now. There are deeper issues that needs fixing so I'm not sure how fast I can produce a proper fix yet. Keep you posted.

In the mean time I recommend that you look at the cide package as an example. Right now bundlerEnv bleeds some common bin files into the environment which creates some conflicts. I'm working on making a rubyPackage that will automates all of this.

@vcunat try rebasing on top of this ^

Yes, that commit certainly improves the situation, as fpm --help works. (I haven't tested more so far.)

I think @aespinosa's #13975 is the way to go. I think a similar change to the bundler packaging should fix this.

Thanks, the package now does what I need it to, so I pushed it as f9cae4f.
Would you skim the example changes e5c319baa88d4 before I push them?


Add new API to return plaintext local CID

This commit adds a new API quicly_get_local_plaintext_cid which
returns the plaintext local CID associated with a connection, so
that an application can examine it (e.g. log it).

I think the proposed function is a duplicate of quicly_get_master_cid?

I think the proposed function is a duplicate of quicly_get_master_cid?

Ouch... I was searching by cid, that's why I missed it (the function name is quicly_get_master_id right?). Closing this.

Ouch... I was searching by cid, that's why I missed it (the function name is quicly_get_master_id right?). Closing this.


Private repositories under organization

I have an organization under my account which is created by me and subscribed by two other users. When I create a new repository under that organization as "private" other users able to see that repository under repository browser in Organization but when they click to repository none of them able to see content of repository. They're getting 404 error. IS that missing feature or kinda bug ?
Using latest gogs installed from binary. Using sqlite as database.

Adding those users to team under organization solves to issue. Somehow we expected to default behavior of joining an Organization should give those users to read permission.

:sweat_smile:


Enable integTest for 2.0.0 GA builds now

Signed-off-by: Peter Zhu<EMAIL_ADDRESS>Description
Enable integTest for 2.0.0 GA builds now
Issues Resolved
Part of #2086
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Codecov Report

Merging #2130 (579928d) into main (aa2f3d4) will increase coverage by 5.78%.
The diff coverage is n/a.

@@              Coverage Diff              @@
##               main     #2130      +/-   ##
=============================================
+ Coverage     94.21%   100.00%   +5.78%
=============================================
  Files           204         6     -198
  Lines          3943       105    -3838
  Branches         29        19      -10
=============================================
- Hits           3715       105    -3610
+ Misses          222         0     -222
+ Partials          6         0       -6

Impacted Files
Coverage Δ

src/build_workflow/build_args.py

src/ci_workflow/ci_target.py

...teg_test/integ_test_start_properties_opensearch.py

src/assemble_workflow/bundle_locations.py

.../ci_workflow/ci_check_gradle_properties_version.py

src/checkout_workflow/checkout_args.py

src/build_workflow/build_target.py

src/assemble_workflow/bundle_rpm.py

src/manifests/bundle_manifest.py

src/manifests/build_manifest.py

... and 188 more

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 aa2f3d4...579928d. Read the comment docs.


Can't clear a breakpoint

Toggling breakpoint will set one, but toggling it again does not clear it.

Same here, tried with both keybindings and drop down menu.  Clearing all breakpoints does work, but that's everything.

The same problem here. When I try to toggle a break point, it adds a new line in the "breakpoints"  tab.
So, I can add but can't remove breakpoint

Clearing individual breakpoints should now be working as of the latest version (v0.1.0)

It seems to be working for me. Thanks!

It is working for me too, thanks


How to handle submission of forms from outside the decorated form component

Hello
I'm having difficulties understanding how to handle submission of multiple forms. In my app I have many separate forms and at the bottom of the page I have a reset, preview, submit action bar which is not a redux-form component. When I press the submit button I want all of the forms to validate (touch all fields) and only if they are all valid the data should be sent to the server.
I've followed the Responding to Other Actions topic from the ReadMe and this allows me to listen to the submit event and access the fields for each form in the pluged in reducers, but this only allows me to work with one of the forms at a time.
export default combineReducers({
  router: routerStateReducer,
  auth,
  form: form.plugin(invoicing()),
});

export default function invoicing() {
  return {
    invoiceForm: (state, action) => {
      switch (action.type) {
        case 'actionBar/SAVE':
          return {
            ...state,
            // Here I can access the fields from one of the forms at least....
            lastName: {}
          };
        default:
          return state;
      }
    }
  };
}

Basically what I (think I) want to do is access the methods touchAll(), valid() and resetForm() from outside the decorated form component. There are of course the exposed action creators which would help me trigger validation of each form but they won't provide me with the valid()-status.
I'm probably missing something here and need some guidance.
Thanks in advance

Hmm... and you're certain that it makes sense for them to be separate form components?
I suppose that you could connect() your submit button component to the redux-form reducer and manually read all the values, and then you could import your sync validation functions from wherever they are and run them manually to calculate an isValid state for all your forms, but that's pretty gross and convoluted. However, nothing is occurring to me for a better way to do it. I would really question your requirement to have them be separate.
...
Oh! How about this? (I'm assuming v2.x)
@connectReduxForm({
  form: 'invoicing',
  fields: ['firstName', 'lastName'],
  validate: validateContactForm
})
class ContactForm extends Component {
  // render contact fields
}

@connectReduxForm({
  form: 'invoicing', // <------ same name
  fields: ['shippingStreet', 'shippingCity'], // <---- different fields
  validate: validateShippingForm
})
class ShippingForm extends Component {
  // render shipping fields
}

@connectReduxForm({
  form: 'invoicing', // <------ same name
  fields: ['billingStreet', 'billingCity'], // <---- different fields
  validate: validateBillingForm
})
class BillingForm extends Component {
  // render billing fields
}

@connectReduxForm({
  form: 'invoicing', // <------ same name
  fields: ['firstName', 'lastName',
    'shippingStreet', 'shippingCity',
    'billingStreet', 'billingCity'], // <---- ALL fields
  validate: somehowCompose(validateContactForm, validateShippingForm, validateBillingForm)
})
class InvoiceSubmitForm extends Component {
  // render submit button
}

This way, your submit button component is reading the same data from the Redux state, so the second that the last invalid field is made valid, the submit button could be enabled, because it's listening to those same values, and it can use the regular handleSubmit method, which will do the "touch all" for you.
Still kind of gross, but it's the cleanest thing I can come up with if you really can't house all the fields in a single form component.
What do you think?

Thanks! I implemented this and it worked out fine. Yes I could probably have used a single form in this case but the important bit was being able to separate the submit button from the form component itself as it should be positioned at another place in the DOM/Page, a case which I wouldn't think is so uncommon.

Come and get it, folks! v4.2.0

would be great if you could just reduxForm.submit('myFormName') from an action creator!

Just in case someone reads this, the submit('myFormName') action creator has been out there for some time now, as explained in the docs.

The same behavior can be achieved by setting the id to the form element as the form attribute on the submit button:
<form id='myFormId'>
  ...
</form>

<!-- somewhere else -->

<input type='submit' form='myFormId' />
<!-- OR -->
<button type='submit' form='myFormId' />

The solution with the form attribute on the submit button don't work in IE. The form attribut is not supported in Internet Explorer.
There are polyfills, but this seemingly don't work with react (?).
Any ideas, that i can this make work in react? Or any other solutions if i can have the submit button outside the form and have one form (like the wizard example) but the behavior of a remote submit?
Many Thanks!

@acontreras89 is there any way to get a callback after submit('myFormName') ?
dispatch(submit('myFormName')).then((res) =>{ console.log('res',res) }) is not working. I'm returning something after form submit.


Grid layout for IGListSectionController with multiple cells

New issue checklist

[v] I have reviewed the README and documentation
[v] I have searched existing issues and this is not a duplicate

General information

IGListKit version: 2.0.0
iOS version(s): 10.2.1
Xcode version: 8.2.1
Devices/Simulators affected: all
Reproducible in the demo project? (Yes/No): Yes
Related issues:

I would like to create a collection view with IGListKit to be displayed in a grid layout. In the example file, in the MixedDataViewController, the GridSectionController displays the items in a grid layout. This IGListSectionController only contains one single cell.

I would like to know if a IGListSectionController with multiple cells (instead of a single cell) can be displayed in a grid layout as well. I have experimented with a collection flow layout for IGListSectionController with multiple cells but the cells do not stay grouped together. See screenshot.

Is there a way to have the cells grouped the same way they are in a full width layout (see screenshot below), but in a grid layout?

Thank you

Hey @sleepyUdon! This should totally be doable. If you return the container width for each cell, then everything should stack on top of each other. Take a look at how I do this in my weather app. Also our working range demo does this as well.
If that answers your question feel free to close this issue! 😄

Thanks Ryan,
I changed the width of the item in WorkingRangeSectionController to see if I can have 3 items per row instead of stacked together:
func sizeForItem(at index: Int) -> CGSize {
     let width: CGFloat = (collectionContext?.containerSize.width)!/3 ?? 0
     let height: CGFloat = CGFloat(index == 0 ? 55 : (self.height ?? 0))
     return CGSize(width: width, height: height)
 }

I am having the same problem as the items do not stay grouped:

@sleepyUdon oh maybe I'm misunderstanding the problem. Can you explain what you mean a little more about how they should "stay grouped"? Some questions:

Which collection view layout are you using?
Do you have a quick mockup of what you're trying to achieve?
Which part of the example in GridSectionController doesn't work as desired?

The grid items are all individual cells, they aren't contained in a parent cell. Not sure if I'm understanding that correctly.

Hi @rnystrom,
Thanks for the quick response. What I am trying to achieve is a collection view like this:

In this instance, I would like to structure each "card" as a section controller made of a collectionviewCell for the picture and another collectionviewCell containing the profile pic, name and likes.

@sleepyUdon  I managed to create a grid finally. Perhaps my issue #632 can help you out?

Thanks @sleepyUdon -- looks like #632 might help. If not, let us know 😄

@sleepyUdon I edited their layout to stack cells in a section instead of placing them horizontally next to each other. Here's my gist: https://gist.github.com/ryancstack/10dce72fb5671b6301859a374d7597e3
I haven't tested it in all situations (headers and such), but it's been working well for me so far.


w64devkit: Add 32 bit and alternate versions

Adds the -fortran and -mini variants of w64devkit, and the 32-bit builds of all three variants.

Closes #11239

[x] I have read the Contributing Guide.

/verify

Move -fortran and -mini variants to Versions bucket.


use config.settings attributes instead of os.getenv

APISettings() will load all values from .env file as
APISettings's attributes. These can be imported in all
other modules, instead of using load_dotenv in every module.
ref: https://fastapi.tiangolo.com/advanced/settings/#reading-a-env-file
This also fixes the issue of missing value of PADDLES_URL in services/helpers.py

@zmc using env_file: in docker-compose worked! thank you! :)
i have explained the problem that this issue solves in #38


Fix lint for aiobotocore_tests.py

What does this pull request do?
Don't know how these slipped through, as the lint passed for the PR in question. We'll have to see if that happens again.
Ref #1520
Closes #1522

:green_heart: Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS

Expand to view the summary

Build stats

Start Time: 2022-04-07T21:13:49.769+0000

Duration: 22 min 19 sec

Test stats :test_tube:

Test
Results

Failed
0

Passed
4829

Skipped
3293

Total
8122

:green_heart: Flaky test report
Tests succeeded.
:robot: GitHub comments
To re-run your PR in the CI, just comment with:

/test : Re-trigger the build.

/test linters : Run the Python linters only.

/test full : Run the full matrix of tests.

/test benchmark : Run the APM Agent Python benchmarks tests.

run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

Closing in favor of #1526