Add "Branching" workflow to git workflow guide

This PR modifies the existing git workflow guide to add a 'branching' workflow in addition to the 'forking' workflow.  It does not explicitly state which workflow is preferred, but rather offers various pros/cons of using each.
See #32 for more context.
Closes #32.

@dpnemergut might want to have a look since he uses the branching workflow, I think.

@arfon @eteq @pllim @mperrin @dpnemergut  As people who have been vocal on #32, could one or more of you offer a review here?  I tried to compile a lot of what was said there into the pros/cons list.  Please let me know if I am missing anything or if anything should be re-worded.  Thanks!

Just want to note that the fact that this PR about branching workflow is made from a fork did not escape me... 😉

Thank you for all of the comments @pllim and @mperrin!  I will digest these, make some edits, and get back to you.

@pllim @mperrin @dpnemergut I pushed some updates that hopefully address most or all of your suggestions.  Please let me know if you have any further suggestions/comments in the next week, if you can.  I am taking next week off, but would like to get this merged shortly after I return, if possible.  Thanks!

Misc comments attached.
I'm honestly kind of ambivalent about this all. But perhaps I just don't understand the specific problem this is trying to solve. I am glad there is no attempt to dictate the use of one or the other workflow; different things work for different projects and different teams. And there are variants of these as well. So I'm fine with this as a descriptive style guide; but I am more hesitant about the idea of making anything more proscriptive "you must do exactly either A or B".

@mperrin I just wanted to chime in here and say that I definitely agree with this sentiment.  I hope that the recent change to remove the explicit pros/cons list and instead just list a 'few things to consider' makes it clear that this style guide has no preference to a particular workflow.

Alrighty, thanks again for the feedback. I'm considering this good to go!


Create NOTEBOOKS.md

issue #3519

I don't know where to start, but I'd try

Please don't open such PRs, they spam our inboxes


Update jena-shacl, jena-shex to 4.6.0

Updates

org.apache.jena:jena-shacl
org.apache.jena:jena-shex

from 4.4.0 to 4.6.0.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.apache.jena" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "@monthly" },
  dependency = { groupId = "org.apache.jena" }
}]

labels: library-update, early-semver-minor, semver-spec-minor, commit-count:1

Superseded by #535.


Add AnsibleResourceField for reverse lookups to the Resource model

resolves to sql: "resource_model"."pk" :: text = "dab_resource_registry_resource"."object_id"

What the high-level concern here is, will this operate on all entries in the resource model's table, and can that have a major penalty on queries in the future?
My other concern is - what querysets will this affect? We would add it to the User model, but would it affect AWX queries that do .select_related("created_by"), where we have no need to for the user ansible_id?

resolves to sql: "resource_model"."pk" :: text = "dab_resource_registry_resource"."object_id"

What the high-level concern here is, will this operate on all entries in the resource model's table, and can that have a major penalty on queries in the future? (although I know this is fixable in the future, I just don't want to make it hard for ourselves to fix it)

I have no idea. We can do some more testing.

My other concern is - what querysets will this affect? We would add it to the User model, but would it affect AWX queries that do .select_related("created_by"), where we have no need to for the user ansible_id?

It should function just like ForeignKey. The Resource queryset should only get resolved if you call user.resource.<property>.
I decided to not automatically add this to models in the registry. We'll start off by just adding it manually where it is needed.

For references here is the sql that select_related spits out:
 SELECT "aap_gateway_api_organization"."id",
       "aap_gateway_api_organization"."created_on",
       "aap_gateway_api_organization"."created_by_id",
       "aap_gateway_api_organization"."modified_on",
       "aap_gateway_api_organization"."modified_by_id",
       "aap_gateway_api_organization"."name",
       "aap_gateway_api_organization"."description",
       "aap_gateway_api_organization"."environment_id",
       "dab_resource_registry_resource"."id",
       "dab_resource_registry_resource"."content_type_id",
       "dab_resource_registry_resource"."object_id",
       "dab_resource_registry_resource"."service_id",
       "dab_resource_registry_resource"."resource_id",
       "dab_resource_registry_resource"."name"
FROM   "aap_gateway_api_organization"
       left outer join "dab_resource_registry_resource"
                    ON ((( ( "aap_gateway_api_organization"."id" ) :: text =
       (
       "dab_resource_registry_resource"."object_id" )
       AND "dab_resource_registry_resource"."content_type_id" = 10
       )))
       left outer join "aap_gateway_api_environment"
                    ON ( "aap_gateway_api_organization"."environment_id" =
                                         "aap_gateway_api_environment"."id" )
ORDER  BY "aap_gateway_api_environment"."name" ASC,
          "aap_gateway_api_organization"."name" ASC

Borrowing django-extensions dependency from https://github.com/ansible/django-ansible-base/pull/176 by @fosterseth and applying:
diff --git a/test_app/settings.py b/test_app/settings.py
index 64578f2..da765b2 100644
--- a/test_app/settings.py
+++ b/test_app/settings.py
@@ -39,6 +39,7 @@ INSTALLED_APPS = [
     'django.contrib.staticfiles',
     'rest_framework',
     'social_django',
+    'django_extensions',
     'ansible_base.api_documentation',
     'ansible_base.authentication',
     'ansible_base.rest_filters',

I'm able to get some really useful feedback via python manage.py shell_plus --print-sql. Let's map out the ORM actions of interest:
orgs = list(Organization.objects.prefetch_related('resource'))
orgs[0]
orgs[0].resource
orgs[0].resource.ansible_id
orgs[1].resource
orgs[1].resource.ansible_id

This gives really good feedback, and this shows a lot of progress. However, when I get to orgs[1].resource I seem to find an outright bug that it's None. Contrast this to Organization.objects.all()[0].resource, which finds the correct item.

@AlanCoding that's interesting. I never bothered testing prefetch_related because select_related is almost always better.

@AlanCoding I got pretech_related working.

I loaded ~10,000 users and orgs into the DB and ran the queries:
Joined query:
gateway=> EXPLAIN ANALYZE
SELECT "aap_gateway_api_organization"."id",
       "aap_gateway_api_organization"."created_on",
       "aap_gateway_api_organization"."created_by_id",
       "aap_gateway_api_organization"."modified_on",
       "aap_gateway_api_organization"."modified_by_id",
       "aap_gateway_api_organization"."name",
       "aap_gateway_api_organization"."description",
       "aap_gateway_api_organization"."environment_id",
       "dab_resource_registry_resource"."id",
       "dab_resource_registry_resource"."content_type_id",
       "dab_resource_registry_resource"."object_id",
       "dab_resource_registry_resource"."service_id",
       "dab_resource_registry_resource"."ansible_id",
       "dab_resource_registry_resource"."name"
FROM   "aap_gateway_api_organization"
       LEFT OUTER JOIN "dab_resource_registry_resource"
                    ON ((( ( "aap_gateway_api_organization"."id" ) :: text =
       (
       "dab_resource_registry_resource"."object_id" )
       AND "dab_resource_registry_resource"."content_type_id" = 10
       )))
LIMIT  100;
                                                                                QUERY PLAN

--------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------
 Limit  (cost=0.29..50.38 rows=100 width=169) (actual time=0.242..13.857 rows=100 loops=1)
   ->  Nested Loop Left Join  (cost=0.29..5078.64 rows=10139 width=169) (actual time=0.166..9.943 rows=100 loops=1)
         ->  Seq Scan on aap_gateway_api_organization  (cost=0.00..246.39 rows=10139 width=85) (actual time=0.048..1.881 r
ows=100 loops=1)
         ->  Index Scan using dab_resourc_content_6d9d9c_idx on dab_resource_registry_resource  (cost=0.29..0.48 rows=1 wi
dth=84) (actual time=0.024..0.024 rows=1 loops=100)
               Index Cond: ((content_type_id = 10) AND (object_id = (aap_gateway_api_organization.id)::text))
 Planning Time: 1.209 ms
 Execution Time: 15.942 ms
(7 rows)

Normal Query
gateway=> EXPLAIN ANALYZE
SELECT "aap_gateway_api_organization"."id",
       "aap_gateway_api_organization"."created_on",
       "aap_gateway_api_organization"."created_by_id",
       "aap_gateway_api_organization"."modified_on",
       "aap_gateway_api_organization"."modified_by_id",
       "aap_gateway_api_organization"."name",
       "aap_gateway_api_organization"."description",
       "aap_gateway_api_organization"."environment_id"
FROM   "aap_gateway_api_organization"
LIMIT  100;
                                                             QUERY PLAN

--------------------------------------------------------------------------------------------------------------------------
-----------
 Limit  (cost=0.00..2.43 rows=100 width=85) (actual time=0.066..5.858 rows=100 loops=1)
   ->  Seq Scan on aap_gateway_api_organization  (cost=0.00..246.39 rows=10139 width=85) (actual time=0.018..1.896 rows=10
0 loops=1)
 Planning Time: 0.090 ms
 Execution Time: 7.614 ms
(4 rows)

I made https://github.com/ansible/django-ansible-base/pull/190 to get the explain output from the debug toolbar, which is heavily duplicated with what you just did.
Tests are looking good and explain probably isn't raising any red flags.

Update - I do think this is in good shape. I just want to rebase it on top of the django-toolbar PR and have a quick look for myself. That means I also need to have the optimizations applied in the test_app views, and I think that really seals the deal for this patch. But don't bother until we can merge with the DDT branch, because it introduces other optimizations.

Can you rebase this? I'll check it out and test but further changes will need a rebase.

I rebased and applied
diff --git a/test_app/models.py b/test_app/models.py
index e2ad925..93ddaab 100644
--- a/test_app/models.py
+++ b/test_app/models.py
@@ -10,18 +10,30 @@ from ansible_base.resource_registry.fields import AnsibleResourceField
 class Organization(AbstractOrganization):
     resource = AnsibleResourceField(primary_key_field="id")

+    def get_summary_fields(self):
+        response = super().get_summary_fields()
+        response["resource"] = self.resource.summary_fields()
+        return response
+

 class User(AbstractUser, CommonModel):
     resource = AnsibleResourceField(primary_key_field="id")

     def summary_fields(self):
-        return user_summary_fields(self)
+        response = user_summary_fields(self)
+        response["resource"] = self.resource.summary_fields()
+        return response

 class Team(AbstractTeam):
     resource = AnsibleResourceField(primary_key_field="id")
     encryptioner = models.ForeignKey('test_app.EncryptionModel', on_delete=models.SET_NULL, null=True)

+    def get_summary_fields(self):
+        response = super().get_summary_fields()
+        response["resource"] = self.resource.summary_fields()
+        return response
+

 class ResourceMigrationTestModel(models.Model):
     name = models.CharField(max_length=255)
diff --git a/test_app/views.py b/test_app/views.py
index 42a07aa..a45e81a 100644
--- a/test_app/views.py
+++ b/test_app/views.py
@@ -25,17 +25,19 @@ class TestAppViewSet(ModelViewSet, AnsibleBaseView):

 class OrganizationViewSet(TestAppViewSet):
     serializer_class = serializers.OrganizationSerializer
-    prefetch_related = ('created_by', 'modified_by')
+    prefetch_related = ('created_by', 'modified_by', 'resource')

 class TeamViewSet(TestAppViewSet):
     serializer_class = serializers.TeamSerializer
     prefetch_related = ('created_by', 'modified_by', 'organization')
+    # done as select_related here for demonstration purposes
+    select_related = ('resource',)

 class UserViewSet(TestAppViewSet):
     serializer_class = serializers.UserSerializer
-    prefetch_related = ('created_by', 'modified_by')
+    prefetch_related = ('created_by', 'modified_by', 'resource')

 class EncryptionModelViewSet(TestAppViewSet):

I visited http://<IP_ADDRESS>:8000/api/v1/organizations/?page_size=25, and there are 153 organizations in total.
It loaded with 66 queries in 36.27ms
devel will load with 6 queries in 6.37ms
The difference is due to an unoptimized content_type reference

I was also surprised by the prefetch query, which seemed to load 50 objects for some reason even though the page size was 25. This was a real surprise, and I don't have a good explanation for it.
But whatever the method is intended to be here, I'd like to get it in test_app. It is way better to look at performance data of test_app than any other legacy app, because the ambient noise level is an order of magnitude lower.

^ disregard above comments about page_size. That is not hooked up in DAB, and it returns 50 items, so 50 is expected.

I forgot to mention in my prior comments - the org/user/team serializer is showing a field like "resource": "42", in their serializer. This is confusing on multilple levels (it's the resource id, not ansible_id, why is it a string anyway?). I say, just get rid of it. Unfortunately, I believe this means excluding the field from each and every serializer. You could try to hack something in the base serializer, either way let's just have an answer, and file followup issues to apply changes in the respective app serializers.

Rounding out the comments:

From my diff above, add get_summary_fields to test_app models to establish how to fully implement this. Or do it in the base serialzier.
Remove the resource field for the test_app models as well
(optional) maybe try to re-use the ContentType cache, I think it might be a simple drop-in replacement and if not I don't want to spend more time on it here

With those I'm :+1: ready to ship this.

You don't know if the project using your library is going to build its field list up or start with all and then remove.
https://www.django-rest-framework.org/api-guide/serializers/#specifying-which-fields-to-include
class AccountSerializer(serializers.ModelSerializer):
    class Meta:
        model = Account
        exclude = ['users']

That is a standard documented pattern, and the logical next-step when an __all__ comes up with a single field that needs to not be there.

You don't know if the project using your library is going to build its field list up or start with all and then remove.
https://www.django-rest-framework.org/api-guide/serializers/#specifying-which-fields-to-include
class AccountSerializer(serializers.ModelSerializer):
    class Meta:
        model = Account
        exclude = ['users']

That is a standard documented pattern, and the logical next-step when an __all__ comes up with a single field that needs to not be there.

Then the author should exclude resource 🤷
I'm going to try to figure out if I can get the serializer to at least show the ansible_id by default, but this really seems like a side quest.

@AlanCoding I made the following changes:

The AnsibleResourceField will be excluded from serializers by default.
The Resource summary fields will be added to serializers by default.

I left the cached function as it was, because it looked like the content type model wasn't caching the resource field

Going over my prior comments :heavy_check_mark: the serializers look to be finished.
{
    "id": 2,
    "url": "/api/v1/organizations/2/",
    "related": {
        "created_by": "/api/v1/users/1/",
        "modified_by": "/api/v1/users/1/",
        "teams": "/api/v1/organizations/2/teams/"
    },
    "summary_fields": {
        "created_by": {
            "id": 1,
            "username": "_system",
            "first_name": "",
            "last_name": ""
        },
        "modified_by": {
            "id": 1,
            "username": "_system",
            "first_name": "",
            "last_name": ""
        },
        "resource": {
            "ansible_id": "98087df3-29d4-4581-8f6f-ab789713aa62",
            "resource_type": "shared.organization"
        }
    },
    "created_on": "2024-03-05T16:49:19.902671Z",
    "modified_on": "2024-03-05T16:49:19.902671Z",
    "name": "Galaxy_community",
    "description": "",
    "created_by": 1,
    "modified_by": 1
}

This expresses this PR is delivering with the ansible_id. Ping @vidyanambiar

I put up https://github.com/newswangerd/django-ansible-base/pull/1 because this puts in things to allow optimizing, but I want to see it actually optimized with test_app. The prefetch/select related really needs the extra __content_type or else it will incur additional queries. I want to raise this to your awareness, in case this is showing that it's not functioning as you intend.
For my own purposes, I'm find with these optimizations being applied to AWX, as they are here (in my patch) in test_app.


Refs #12679 -- Added test for using property as ModelAdmin.inlines.

ticket-12679

Thanks for fixing the test (I'm not sure what I did there, probably some careless copy/pasting). :sparkles:


Nginx proxy not loading the correct certificates until manual reload + excluding host from https

I'm using this docker image along with a seperate nginx and docker-gen container.
Everything works fine most of the time, however sometimes the nginx proxy uses the default certificate instead of the generated ones, even if the nginx configuration is correct. Manually reloading the nginx container using docker container exec container_id sh -c 'exec nginx -s reload' solves the problem.
Here are the relevant parts of my docker-compose file (using Docker Swarm):
version: "3"

services:
nginx-proxy:
    image: nginx:mainline-alpine
    deploy:
      mode: replicated
      replicas: 1
      restart_policy:
        condition: any
    labels:
      com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy: ""
    ports:
      - "80:80"
      - "443:443"
    volumes:
      - /home/ips/nginx-proxy/conf.d:/etc/nginx/conf.d
      - /home/ips/nginx-proxy/vhost.d:/etc/nginx/vhost.d
      - /home/ips/nginx-proxy/html:/usr/share/nginx/html
      - /home/ips/nginx-proxy/certs:/etc/nginx/certs:ro
      - /home/ips/nginx-proxy/nginx.conf:/etc/nginx/nginx.conf
    networks:
      - proxy
  nginx-gen:
    image: jwilder/docker-gen
    command: -notify-sighup nginx-proxy -watch -wait 5s:30s /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
    deploy:
      mode: replicated
      replicas: 1
      restart_policy:
        condition: any
    labels:
      com.github.jrcs.letsencrypt_nginx_proxy_companion.docker_gen: ""
    volumes:
      - /home/ips/nginx-proxy/conf.d:/etc/nginx/conf.d
      - /home/ips/nginx-proxy/vhost.d:/etc/nginx/vhost.d
      - /home/ips/nginx-proxy/html:/usr/share/nginx/html
      - /home/ips/nginx-proxy/certs:/etc/nginx/certs:ro
      - /var/run/docker.sock:/tmp/docker.sock:ro
      - /home/ips/nginx-proxy/nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl:ro
    networks:
      - proxy
  nginx-letsencrypt:
    image: jrcs/letsencrypt-nginx-proxy-companion
    deploy:
      mode: replicated
      replicas: 1
      restart_policy:
        condition: any
    volumes:
      - /home/ips/nginx-proxy/conf.d:/etc/nginx/conf.d
      - /home/ips/nginx-proxy/vhost.d:/etc/nginx/vhost.d
      - /home/ips/nginx-proxy/html:/usr/share/nginx/html
      - /home/ips/nginx-proxy/certs:/etc/nginx/certs
      - /var/run/docker.sock:/var/run/docker.sock:ro
egm-web:
    image: nginx:mainline-alpine
    deploy:
      mode: replicated
      replicas: 1
      restart_policy:
        condition: any
    environment:
      VIRTUAL_HOST: mydomain.de,www.mydomain.de,myotherdomain.com,de.myotherdomain.com,en.myotherdomain.com,loading.mydomain.de
      LETSENCRYPT_HOST: mydomain.de,www.mydomain.de,myotherdomain.com,de.myotherdomain.com,en.myotherdomain.com
      LETSENCRYPT_EMAIL<EMAIL_ADDRESS>    volumes:
      - /home/ips/egm-web/files:/files
      - /home/ips/egm-web/conf.d:/etc/nginx/conf.d
      - /home/ips/egm-web/snippets:/etc/nginx/snippets
      - /home/ips/egm-web/nginx.conf:/etc/nginx/nginx.conf
      - /home/ips/egm-web/fastcgi_params:/etc/nginx/fastcgi_params
    networks:
      - proxy
      - egm-web

Also, is it possible to exclude a host in VIRTUAL_HOST, that is not listed in LETSENCRYPT_HOST (loading.mydomain.de in this case) from https? I would like to have this virtual host only served via http.

Which version of the container are you using ? If using latest, could you pull it again ?

I'm using no tag, so it should default to the latest tag. The image got downloaded one day ago.

Running docker-stack deploy on a running docker stack (so just updating services) does not cause the issue. The issue only arises when removing the stack (docker-stack rm) before deploying.

Could you try removing -wait 5s:30s from the docker-gen command ?

Here is the log of the nginx_letsencrypt container, from startup until manually reloading nginx:
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Info: Custom Diffie-Hellman group found, generation skipped.
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx docker-gen (using separate container 2b17028149624a567a49de7ecbae26f71bb4484579ae795c311a771d94c93eb4)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx (using separate container 768431a7f345e4dc66b1a94ffaf5434b5a598851271bae5a0490b5c2d3fd120d)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Sleep for 3600s
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:51 Generated '/app/letsencrypt_service_data' from 4 containers
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:51 Running '/app/signal_le_service'
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:51 Watching docker events
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:51 Contents of /app/letsencrypt_service_data did not change. Skipping notification '/app/signal_le_service'
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx docker-gen (using separate container 2b17028149624a567a49de7ecbae26f71bb4484579ae795c311a771d94c93eb4)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx (using separate container 768431a7f345e4dc66b1a94ffaf5434b5a598851271bae5a0490b5c2d3fd120d)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Sleep for 3600s
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:52 Received event start for container 12bb621e3d5e
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:27:53 Received event start for container f27dcc2b66fb
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:28:08 Debounce minTimer fired
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:28:09 Generated '/app/letsencrypt_service_data' from 6 containers
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018/08/23 21:28:09 Running '/app/signal_le_service'
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | /etc/nginx/certs/mydomain.de /app
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx docker-gen (using separate container 2b17028149624a567a49de7ecbae26f71bb4484579ae795c311a771d94c93eb4)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx (using separate container 768431a7f345e4dc66b1a94ffaf5434b5a598851271bae5a0490b5c2d3fd120d)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Creating/renewal mydomain.de certificates... (mydomain.de www.mydomain.de myotherdomain.com de. myotherdomain.com.com en.myotherdomain.com.com)
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | 2018-08-23 21:28:09,837:INFO:simp_le:1564: Certificates already exist and renewal is not necessary, exiting with status code 1.
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | /app
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx docker-gen (using separate container 2b17028149624a567a49de7ecbae26f71bb4484579ae795c311a771d94c93eb4)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Reloading nginx (using separate container 768431a7f345e4dc66b1a94ffaf5434b5a598851271bae5a0490b5c2d3fd120d)...
ips_nginx-letsencrypt.1.ve9d773wcj51@ips-vps-1    | Sleep for 3600s

Could you try removing -wait 5s:30s from the docker-gen command ?

Doesn't help.

Okay, seems like we're missing a reload condition somewhere.

Could you run the letsencrypt container with the DEBUG=true env var ?

Yep, here is the output:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Debug: a default certificate with subject= /CN=letsencrypt-nginx-proxy-companion is present.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Debug: the self generated default certificate is still valid for more than three months. Skipping default certificate creation.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Info: Custom Diffie-Hellman group found, generation skipped.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx docker-gen (using separate container 9b4b080fd0121d9d194f9f3045554fff17b3a5473e47181098501b79c58d7a77)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx (using separate container 6d9deed5533e7b43511d3cc5bc9fe04315092b536f59f768e8760afa290ce7f0)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:26 Generated '/app/letsencrypt_service_data' from 3 containers
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:26 Running '/app/signal_le_service'
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:26 Watching docker events
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:26 Contents of /app/letsencrypt_service_data did not change. Skipping notification '/app/signal_le_service'
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Symlinked domains: de.myotherdomain.com myotherdomain.com mydomain.de en.myotherdomain.com www.mydomain.de
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Enabled domains:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Disabled domains: de.myotherdomain.com myotherdomain.com mydomain.de en.myotherdomain.com www.mydomain.de
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Some domains are disabled. Check them to remove unused symlinks.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    |
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking domain de.myotherdomain.com:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking de.myotherdomain.com.crt - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking de.myotherdomain.com.key - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking de.myotherdomain.com.dhparam.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking de.myotherdomain.com.chain.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking domain myotherdomain.com:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking myotherdomain.com.crt - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking myotherdomain.com.key - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking myotherdomain.com.dhparam.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking myotherdomain.com.chain.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking domain mydomain.de:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking mydomain.de.crt - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking mydomain.de.key - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking mydomain.de.dhparam.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking mydomain.de.chain.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking domain en.myotherdomain.com:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking en.myotherdomain.com.crt - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking en.myotherdomain.com.key - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking en.myotherdomain.com.dhparam.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking en.myotherdomain.com.chain.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking domain www.mydomain.de:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking www.mydomain.de.crt - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking www.mydomain.de.key - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking www.mydomain.de.dhparam.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Checking www.mydomain.de.chain.pem - removing.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Unused domains checking is finished.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx docker-gen (using separate container 9b4b080fd0121d9d194f9f3045554fff17b3a5473e47181098501b79c58d7a77)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx (using separate container 6d9deed5533e7b43511d3cc5bc9fe04315092b536f59f768e8760afa290ce7f0)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Sleep for 3600s
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:28 Received event start for container 12c177b6f775
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:30 Received event start for container 943210c2644c
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:33 Received event start for container b39b74a4ab59
``

Could you post what comes after, up to the point where you have to manually reload nginx ?

ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:48 Debounce minTimer fired
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:48 Generated '/app/letsencrypt_service_data' from 6 containers
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018/08/23 21:41:48 Running '/app/signal_le_service'
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | /etc/nginx/certs/mydomain.de /app
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx docker-gen (using separate container 9b4b080fd0121d9d194f9f3045554fff17b3a5473e47181098501b79c58d7a77)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx (using separate container 6d9deed5533e7b43511d3cc5bc9fe04315092b536f59f768e8760afa290ce7f0)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Creating/renewal mydomain.de certificates... (mydomain.de www.mydomain.de myotherdomain.com de.myotherdomain.com en.myotherdomain.com)
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,847:DEBUG:simp_le:1546: ('-f', 'account_key.json', '-f', 'key.pem', '-f', 'chain.pem', '-f', 'fullchain.pem', '-f', 'cert.pem', '--email'<EMAIL_ADDRESS>'-v', '-d', 'mydomain.de', '-d', 'www.mydomain.de', '-d', 'myotherdomain.com', '-d', 'de.myotherdomain.com', '-d', 'en.myotherdomain.com', '--cert_key_size=4096', '--server=https://acme-v01.api.letsencrypt.org/directory', '--default_root', '/usr/share/nginx/html/') parsed as Namespace(account_key_public_exponent=65537, account_key_size=4096, cert_key_size=4096, default_root='/usr/share/nginx/html/'<EMAIL_ADDRESS>help=False, integration_test=False, ioplugins=['account_key.json', 'key.pem', 'chain.pem', 'fullchain.pem', 'cert.pem'], reuse_key=False, revoke=False, server='https://acme-v01.api.letsencrypt.org/directory', test=False, user_agent='simp_le/0.10.0', valid_min=2592000, verbose=True, version=False, vhosts=[Vhost(name='mydomain.de', root=None), Vhost(name='www.mydomain.de', root=None), Vhost(name='myotherdomain.com', root=None), Vhost(name='de.myotherdomain.com', root=None), Vhost(name='en.myotherdomain.com', root=None)])
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,848:DEBUG:simp_le:336: Loading account_key.json
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,852:DEBUG:simp_le:336: Loading key.pem
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,853:DEBUG:simp_le:336: Loading chain.pem
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,853:DEBUG:simp_le:336: Loading fullchain.pem
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,854:DEBUG:simp_le:336: Loading cert.pem
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,855:DEBUG:simp_le:1374: Existing SANs: [u'de.myotherdomain.com', u'myotherdomain.com', u'mydomain.de', u'en.myotherdomain.com', u'www.mydomain.de'], new: ['mydomain.de', 'www.mydomain.de', 'myotherdomain.com', 'de.myotherdomain.com', 'en.myotherdomain.com']
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,859:DEBUG:simp_le:1238: Certificate expires in 88 days, 17:18:17.144397 on 2018-11-20 15:00:06+00:00 (relative to 2018-08-23 21:41:48.855603+00:00)
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | 2018-08-23 21:41:48,859:INFO:simp_le:1564: Certificates already exist and renewal is not necessary, exiting with status code 1.
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | /app
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Symlinked domains: de.myotherdomain.com myotherdomain.com mydomain.de en.myotherdomain.com www.mydomain.de
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Enabled domains: mydomain.de www.mydomain.de myotherdomain.com de.myotherdomain.com en.myotherdomain.com
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Disabled domains:
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx docker-gen (using separate container 9b4b080fd0121d9d194f9f3045554fff17b3a5473e47181098501b79c58d7a77)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Reloading nginx (using separate container 6d9deed5533e7b43511d3cc5bc9fe04315092b536f59f768e8760afa290ce7f0)...
ips_nginx-letsencrypt.1.6jqqtc04rk5z@ips-vps-1    | Sleep for 3600s

That last reload is the manual one ?

Jep.

Okay, that's weird, testing with a docker-compose setup emulating yours I don't encounter this issue, nginx is correctly reloaded right after the web container comes up.

Maybe it only occurs when using docker stack deploy?

Do you have the logs of the docker-gen container too ?

ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Generated '/etc/nginx/conf.d/default.conf' from 5 containers
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Sending container 'nginx-proxy' signal '1'
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Error sending signal to container: No such container: nginx-proxy
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Watching docker events
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Generated '/etc/nginx/conf.d/default.conf' from 5 containers
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Sending container 'nginx-proxy' signal '1'
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:48 Error sending signal to container: No such container: nginx-proxy
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:50 Received event start for container 49a1737b1ce1
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:50 Received signal: hangup
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:50 Received signal: hangup
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:50 Contents of /etc/nginx/conf.d/default.conf did not change. Skipping notification ''
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:51 Received signal: hangup
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:51 Received signal: hangup
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:51 Contents of /etc/nginx/conf.d/default.conf did not change. Skipping notification ''
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:55 Debounce minTimer fired
ips_nginx-gen.1.i05tz3gweqs2@ips-vps-1    | 2018/08/23 22:32:55 Contents of /etc/nginx/conf.d/default.conf did not change. Skipping notification ''

Okay I must be tired if I failed to see this right away.
The docker-gen container doesn't work in swarm mode because container names are dynamic and unlike in letsencrypt-nginx-proxy-companion there is no support for this built into the docker-gen container.
Maybe this fork from @helderco can help : https://github.com/helderco/docker-gen

Okay, that makes sense. I thought setting the label is used for dynamic container name reference.
I will try out the image you send, thank you!
Also, could you help me with that?

Also, is it possible to exclude a host in VIRTUAL_HOST, that is not listed in LETSENCRYPT_HOST (loading.mydomain.de in this case) from https? I would like to have this virtual host only served via http.

If you remove a domain from the LETSENCRYPT_HOST env var, the corresponding symlinks will be removed and nginx will serve the virtual host over http BUT as HSTS with long duration is enabled by default in nginx.tmpl, any browser that visited this domain when it was served over https won't accept to connect over http.
see v1.8 release notes for more details.

Using the new docker-gen image does solve the issue, thank you very much!
Maybe we should add a hint in the Readme file.

Even if not having loading.mydomain.de in the LETSENCRYPT_HOST env var, it is still generated with hsts / https. The certificate does not exist for this domain, however one exists for mydomain.de, does this matter?

Have you tried again with helderco's docker-gen fork ? That might be tied to docker-gen not working properly previously.

Yes, loading.mydomain.de thinks it should use the mydomain.de certificate.

Sounds like an issue with nginx.tmpl, you should report it to jwilder/nginx-proxy.
Most probably this line https://github.com/jwilder/nginx-proxy/blob/e80fc0b304bcbcf703d86392394c1a5adb823e3c/nginx.tmpl#L180


Updated documentation for messages.

Updated the documentation for sending messages and provided an additional example to send a message from a subreddit.
Also added documentation for getting moderator mail as well as replies to moderator mail messages.

This is awesome! Thanks.
Can you resolve the issues with the tests failing due to the lint checks? Then I am happy to merge this in.
./praw/models/reddit/mixins/messageable.py:26:80: E501 line too long (81 > 79 characters)
./praw/models/reddit/mixins/messageable.py:30:80: E501 line too long (90 > 79 characters)

Thanks!


Introduce the Columns shortcode from developer.chrome.com to web.dev.

The -w prefixed for the inline class is an artefact from the old system that needs to be cleaned up. There are many existing posts using the w-column class name.
Since all the w-column need to be removed, so It will be worth introducing the Columns shortcode we have on d.c.c to web.dev.
https://developer.chrome.com/docs/handbook/components/#columns

When working on this, please evaluate wether it makes sense to have a shared shortcode here in webdev-infra, which can be used by both d.c.c and web.dev, like the BrowserCompat shortcode for example.


Allow collection of customer phone number

Feature request

Extension name: firestore-stripe-payments

Is your feature request related to a problem? Please describe.
I would like to collect the phone number of the customer on the checkout page in order to be able to contact them in case of an emergency. Adding
phone_number_collection: {enabled: true}, to the checkout_sessions document as shown in the docs does not work.
Describe the solution you'd like
Pass the phone_number_collection value on to stripe.
Describe alternatives you've considered
The phone number could be collected before the checkout, but this would add an unnecessary step for the customer (since the billing adress is collected in checkout) and needs an additional auth system.
Additional context
In issue #26 , @thorsten-stripe wrote 2020 that the phone number is not collected. However, this seems to have changed, since the payment objects have a "phone" value and the docs mention a way to collect the phone number.

@LeQuadratico Are you expecting the phone value to be set on the billing_details.phone field? If so, that's not the case. As outlined here, the value is set on both the Checkout Session object and the Customer object.

@LeQuadratico Oops, yes. We'll need to add support for that parameter! My bad.


Option "getPointerColor" not in CDN.js version of code

Steps to reproduce

Search CDN.js version of code for "getPointerColor" and the option will not be found
Caused some confusion while I was working on this

Expected behaviour
Maybe CDN.js needs to be updated, or maybe I just misunderstood something?
https://cdnjs.cloudflare.com/ajax/libs/angularjs-slider/2.5.0/rzslider.js
https://cdnjs.cloudflare.com/ajax/libs/angularjs-slider/2.5.0/rzslider.min.js

You need to use the latest version which currently is 2.8.0:

https://cdnjs.cloudflare.com/ajax/libs/angularjs-slider/2.8.0/rzslider.js

The problem is that there is no 'latest' version for CDNJS so I need to remember to update the doc at each new version...


Running npm start shows an empty html

How do I make the server template html show my app?

That's the same as npm start, for some reason I'm getting this: Entrypoint undefined = index.html

Super weird, can you try cloning another project and run npm install and then start.
Which OS are you using ?

Also, root node modules are front-end web modules.
and, root of session-src is a separate modules for native node.js modules,
so keep that in mind

I've had to update a lot of deps, and eventually got it to work. I also replaced webpack with vite for faster builds. Thanks for opensourcing this! I learned a lot from it


In params.go ConsensusParams.ABCI should be ConsensusParams.Abci according to CamelCase rules

          Side note: why do we use all-caps in the human-written field name (that's not what you should do to acronyms per CamelCase), when protobuf has it differently?

Originally posted by @mzabaluev in https://github.com/cometbft/cometbft/pull/2060#discussion_r1457198353

Think of this... maybe the time is now to change this, as part of v.1.x, since we're doing plenty of similar changes. @adizere thoughts ?

Good idea!


Use xdg config home convention

Implementation for https://github.com/tekezo/Karabiner-Elements/issues/112 where the config files live under ~/.config/karabiner-elements instead of ~/.karabiner.d/configuration.

It's a good idea to change the configuration directory to ~/.config/karabiner!
However, this change makes a confusion since everyone change the karabiner.json manually.
I'll merge this change after Preferences UI is provided and it allows that the most user does not touch karabiner.json directly.

I'll merge this change after Preferences UI is provided and it allows that the most user does not touch karabiner.json directly.

Seems the Preferences UI is in place, and the basic functionality works!
Is now a good time to move the default config folder yet? :-P

please support xdg standard

karabiner.json is located in ~/.config/karabiner since v0.90.70.


@semaphore-protocol/data uses utility functions that can be replaced by @zk-kit/utils

Description
@semaphore-protocol/data uses checkParameters to check if the parameter types are the correct ones. Since there's already a @zk-kit/utils dependency, it could use the zk-kit utility error-handlers functions directly, and avoid duplicating code.

Can you assign this to me please?

Hey @jancris100 sure. I just assigned you this issue. Please, let us know if you have questions.

Hey! I'm Hannah, a developer studying with the PSE Core program :) If this isn't in progress already I would be happy to take it on.

Hey @hannahredler, there's already a PR for this issue. Let's try to ping the author and ask them first.
@jancris100 there are some issues to solve in your PR: https://github.com/semaphore-protocol/semaphore/pull/782. Let us know if you've time to work on it. Otherwise no problem, just a double-check before re-assigning the issue.

This issue i already finish it a long time ago

@jancris100 great! Could you reply to my comments there? Some conflicts also need to be resolved

@jancris100 then why this pr is not closed

Hi a will review this issue later to see what happened here

Hey @cedoor , would like to work on this task - can you assign me that. Any additional context would be appreciated. Thanks!


Change User agent from PicoTorrent/x.y.z to PicoTorrent x.y.z

Why are you using a slash between the name of the application and its version in the User agent? It seems to me that it is worth using a space in this case.

Do you have any evidence to support your claim that it is worth switching? Quoting the libtorrent documentation,

The recommended format of this string is: "client-name/client-version libtorrent/libtorrent-version"

So if anything we should add libtorrent/libtorrent-version to our user agent as well.
A quick look at the qBittorrent sources (which also uses libtorrent) will also reaffirm that we are currently using the correct format for our user agent.
https://github.com/qbittorrent/qBittorrent/blob/1e4c837d6c70a1ca0a738ed884357425bae9dcb1/src/base/bittorrent/session.cpp#L102

@vktr You are correct. User-agents always have a slash in it.
But it's definitely worth adding libtorrent to the string. Because certain trackers blacklist unknown torrent clients, or whitelist things like libtorrent-based clients. So it's very iimportants.

I'm open for suggestions but my current opinion is that we should keep the user agent as-is since it is conforming to some standard at least. Regarding white/blacklists the only real solution is to contact the trackers that blocks PicoTorrent, have a discussion to see why it's blacklisted and then work from there to have our standards conforming user agent whitelisted.

@vktr For sure, but there are so many trackers that just use old, lazy lists of black/white-listed clients. So setting it to PicoTorrent/0.18.0 libtorrent/x.y.z would help compatibility. Can't expect old platforms to change.
It's correct to add libtorrent to the agent. That's the standard way to create new applications. Just look at what your own browser is sending: https://ipecho.net/extra (in my case Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.88 Safari/537.36). That's because user agents should contain both the GUI (like Chrome or PicoTorrent) and the engine (like libtorrent or Safari).
Adding libtorrent should help compatibility. Otherwise we can expect PicoTorrent to be usable in maybe 5-10 years, which is how long it should take people to add its specific user-agent to all trackers. xD

For example, look at the Chrome user agent, which even has a (KHTML, like Gecko) section. Why the "like Gecko"? Precisely because of the issue that PicoTorrent is now facing: Inertia in the outside world, forcing Chrome to emulate other packages in their user agent to get compatibility.
This would be an improvement in compatibility and correctness:
PicoTorrent/0.18.0 libtorrent/x.y.z
This would be a silly (but massive) compatibility boost:
PicoTorrent/0.18.0 libtorrent/x.y.z (like qBitTorrent/x.y.z blabla) (but don't do that; just an example, that's nasty, and I'd rather people whitelist you than piggybacking off others).
Right now I might consider trying to build PicoTorrent myself and setting a different user agent. But just adding libtorrent to the string should already be enough to work in a lot more trackers.

Are you currently running into an issue with PicoTorrent being blacklisted? Would you mind sending me the tracker name at<EMAIL_ADDRESS>I'll be happy to open a discussion with the tracker people in order to have it whitelisted.
I know we had some blacklisting issues in the beginning (like 2015-16 when PicoTorrent was new) but I haven't had any issues reported about that in a long time now, and this issue is not talking about that either.
I'm somewhat open to adding some sort of compatibility option which would set the user agent to PicoTorrent/x.y.z libtorrent/x.y.z but I'd like some evidence on the user agent being an issue first, and also on adding the libtorrent/x.y.z solving that issue.

@vktr, @VideoPlayerCode

Do you have any evidence to support your claim that it is worth switching?
Use Space instead of a slash, such clients as uTorrent, Transmission, Tixati, MediaGet.

Screenshots

And usually developers write the name of the application, then a space, then a version. For example, in the Releases section of your application this is exactly what is written.

@Rakleed I think you're confusing things. That list seems to be taken from the Client column of some peer list, and that column usually comes from the Peer ID, not the User Agent.

@vktr I do not fully understand some of the terms, so maybe I initially made the request incorrectly. But PicoTorrent in the Client list appears as PicoTorrent/x.y.z, and I would like it to appear as PicoTorrent x.y.z, like most other clients.

@Rakleed you got it wrong. Peer ID and User-agent isn't the same thing. Also Peer ID is identifier is clientside.
https://github.com/picotorrent/picotorrent/blob/master/src/picotorrent/bittorrent/session.cpp#L182
As you can see, it already is as you want.
Peer ID is used for client identification. Most of the time, this identification is handled by the client-side.

User-agent is also an identifier. But it is used in HTTP(S) requests. In our case, it is used for BitTorrent tracker requests. (HTTP(S))
Check "http://bittorrent.org/beps/bep_0000.html" specifications for more info.


The sequence of operations in the Linformer Attention module is probably wrong.

🐛 Bug

Hi guys!
In Linformer's example source code, I found that operation order may not match the official paper mathematics.
Here, in the code, the linear attention is done in the following sequence of the two operations:

a Linear projection from n token's representations to k.
a Linear projection over the embedding dimension (d_m to d_k).
as here (#208 and #213 respectively)

On the contrary, this image from the Linformer paper states that it should be performed in the order of:

a Linear projection over the embedding dimension (d_m to d_k).
a Linear projection from n token's representations to k.
As seen in the picture below:

Am I missing something important here? If anything gets confirmed, I am up for fixing it.
Environment
Current fairseq version.

@madian9

Any update on this?

I would also be happy to know more about this!


Move protocol layer options and methods to details namespace.

Are we confident that all these other types and methods need to be public as well and can't move to ::Details?
Do we have existing public client or options API that expose all of them already?
For example:
https://github.com/Azure/azure-sdk-for-cpp/blob/2fe5120fd4af9d884d78f7ff4fa0c7c80b720446/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/protocol/datalake_rest_client.hpp#L116-L181

ToString and FromString should be in Details namespace

Functions like from/to json/xml should be public to customers?

/check-enforcer override

/check-enforcer override

wow, wow, wow
what are you doing here?


S16FRANCIS-32: Basic end to end framework (Angular UI, Spring MVC Pro…

This is a basic integrated framework that uses angular ui, spring mvc rest, junit and bootstrap.

Remove all the .settings/** files and add them to .gitignore (in addition to the .classpath and .project files).

The Code Climate for this branch is pretty abysmal: https://codeclimate.com/github/p632-sp-2016/continuous-delivery/compare/feature/S16FRANCIS-32

S16FRANCIS33 has been raised to address the issues raised in this merge request. Code climate gpa is low due to external package dependencies. This can be addressed by using npm, bower in S16FRANCIS33. Merging the pull request.


Session handler allows for multiple concurrent sessions for one person

Ideally it wouldn't, and each person would have only one valid session open at a time.
The solution is to ensure that any existing active session is cleared when starting a new one.

Resolved. The LOGIN verb will now ensure that there is only one active session per user at a time.


Run a scan from the web UI

Original ticket: https://sourceforge.net/apps/trac/seccubus/ticket/68
Sourceforge user dystrophy wrote:
It would be nice to be able to run a scan directly from the web UI after creating it instead of using the CLI.
Frank wrote:
This feature is also part of the same sotory as #73 (https://www.pivotaltracker.com/story/show/23100339)
Changed 7 months ago by frank_breedijk
On the scrum board as "Support scheduling/running scans from GUI (#68)"
https://www.pivotaltracker.com/projects/324809#

bump 2020 still not implemented?

Still working on new GUI :(


Redisson 3.17.7 in Sentinel Mode Locks hang forever

Hi,
We recently upgraded our Redisson version from 3.13.3. to 3.17.7 and facing a weird Locking behavior in Redis Sentinel mode only, Standalone and Cluster Mode are working just fine.
We are running a background thread which processing records from database and acquires distributed lock using lock.tryLock method. The application works fine for sometime but after 1-2 hours this background thread gets stuck on acquiring the lock and its hanged forever and its not even respecting the waitTime or leaseTime.
This issue is only observed is 3.17.7 version and Redis running in Sentinel mode.
In 3.13.3 this was working as expected as expected for all Redis modes.
We have not noticed any failover activity on server side when this issue happens. I think there's some regression that got introduced.
Is there a solution to this problem?
Will upgrading to 3.18.1 solve this problem @mrniko ?
P.S: We cannot upgrade beyond 3.18.1 because later version have introduced Kryo 5 as compile time dependency and we are running on Kryo 4.
Thanks.
Locking Code:

RLock lock = client.getLock(name);
boolean locked = lock.tryLock(0, timeout.toMillis(), TimeUnit.MILLISECONDS);
if (locked) {
log.debug("Lock acquired on {} for timeout {}", name, timeout);
return RedisAcquiredLock.builder().lock(lock).build();
}

Unlocking Code:

if (lock != null && lock.isHeldByCurrentThread()) {
lock.unlock();
}

Thread Dump:

outbox-poll-service-thread-NextGenManagerawaiting notification on [ 0x0000000709c24688 ]
at<EMAIL_ADDRESS>Method)
at java.util.concurrent.locks.LockSupport.park(java.base@11.0.15/LockSupport.java:194)
at java.util.concurrent.CompletableFuture$Signaller.block(java.base@11.0.15/CompletableFuture.java:1796)
at java.util.concurrent.ForkJoinPool.managedBlock(java.base@11.0.15/ForkJoinPool.java:3128)
at java.util.concurrent.CompletableFuture.waitingGet(java.base@11.0.15/CompletableFuture.java:1823)
at java.util.concurrent.CompletableFuture.get(java.base@11.0.15/CompletableFuture.java:1998)
at org.redisson.command.CommandAsyncService.get(CommandAsyncService.java:109)
at org.redisson.RedissonObject.get(RedissonObject.java:82)
at org.redisson.RedissonLock.tryAcquire(RedissonLock.java:144)
at org.redisson.RedissonLock.tryLock(RedissonLock.java:218)
at io.harness.lock.redis.RedisPersistentLocker.acquireLock(RedisPersistentLocker.java:65)
at io.harness.lock.redis.RedisPersistentLocker.tryToAcquireLock(RedisPersistentLocker.java:103)
at io.harness.outbox.OutboxEventPollJob.pollAndHandleOutboxEvents(OutboxEventPollJob.java:74)
at io.harness.outbox.OutboxEventPollJob.run(OutboxEventPollJob.java:65)
at java.util.concurrent.Executors$RunnableAdapter.call(java.base@11.0.15/Executors.java:515)
at java.lang.Thread.run(java.base@11.0.15/Thread.java:829)

We cannot upgrade beyond 3.18.1 because later version have introduced Kryo 5 as compile time dependency and we are running on Kryo 4.

You can use org.redisson.codec.KryoCodec which is Kryo 4 compatible.

Thanks @mrniko Does below fix applies to sentinel mode as well?

"Fixed - RLock can only be obtained by single redisson node if None of slaves were synced error occurred"

@mrniko @piyush-harness is there any update on the above ?

Can you share the reproducer?

Unable to reproduce with the latest version.


marathon runner

Thanks for your contribution! This is a template that can make it easier when submitting your contribution:
Your Project:  MarathonLabs
Project URL:  https://github.com/MarathonLabs/marathon
Category: UI Testing
Description:  Fase, Scalable and reliable runner of tests
Inclusion requirements:

[x] Has 50 GitHub stargazers or more
[x] Only one project/change is in this pull request
[x] Isn't an archived project
[x] Has more than one contributor
[x] Has unit tests, integration tests or UI tests
[x] Addition in alphabetical order (bottom of category)
[x] Supports iOS 12 / tvOS 10 or later
[x] Supports Swift 4 or later
[x] Has a commit from less than 2 years ago
[x] Has a clear README in English

:heart: Awesome iOS Contributors

@matzuk Thanks for contributing!


Access to RateLimit before there's an error?

Or maybe a better question would be: is there a novel way to access the response headers for a given request? It would be nice to peek at the x-rate-limit headers when posting a tweet, for example. Some of the other x-* headers could be of interest, too.
-> "x-rate-limit-limit: 200\r\n"
-> "x-rate-limit-reset:<PHONE_NUMBER>\r\n"
-> "x-rate-limit-remaining: 197\r\n"

You could do this by implementing a custom response handler for your request. There aren't currently parameters or accessor methods to do this, but it is possible with some Ruby hackery. I could add such parameters/methods in future version of the gem but before I start writing code, I'm interested  to understand your use case better.
Are you aware that the API has a GET application/rate_limit_status resource?
This question has come up before in a previous implementation of this library, but it was ultimately deemed unnecessary. If you have a new and different use case, I’d like to understand it better.

@sferik Thanks for the response – yeah, I think the application/rate_limit_status should serve any such purposes just fine. Thanks!


Methods that return function pointers generate invalid code

Given the following C++ code:
typedef int(*SomeFunctionPtr)(int p1);

class TESTDLL_API CallbackFunctions
{
  SomeFunctionPtr callback = nullptr;

public:
  virtual SomeFunctionPtr getCallback() const = 0;
};

The generator will produce code such as the following:
private static global::SampleLibrary.SomeFunctionPtr _GetCallbackDelegateHook(global::System.IntPtr __instance)
{
    if (!NativeToManagedMap.ContainsKey(__instance))
        throw new global::System.Exception("No managed instance was found");

    var __target = (global::SampleLibrary.CallbackFunctions) NativeToManagedMap[__instance];
    if (__target.__ownsNativeInstance)
        __target.SetupVTables();
    var __ret = __target.Callback;
    return __ret == null ? global::System.IntPtr.Zero : Marshal.GetFunctionPointerForDelegate(__ret);
}

The last line is invalid, due to it trying to cast from IntPtr to the delegate type.  In this case it seems '__ret' can be returned directly.
In the generated CallbackFunctionsInternal class there is a similar issue:
public override global::SampleLibrary.SomeFunctionPtr Callback
{
    get
    {
        var __slot = *(void**) ((IntPtr) __OriginalVTables[0] + 0 * 4);
        var ___GetCallbackDelegate = (global::SampleLibrary.Delegates.Func_SampleLibrary_SomeFunctionPtr_IntPtr) Marshal.GetDelegateForFunctionPointer(new IntPtr(__slot), typeof(global::SampleLibrary.Delegates.Func_SampleLibrary_SomeFunctionPtr_IntPtr));
        var __ret = ___GetCallbackDelegate((__Instance + __PointerAdjustment));
        var __ptr0 = __ret;
        return __ptr0 == IntPtr.Zero? null : (global::SampleLibrary.SomeFunctionPtr) Marshal.GetDelegateForFunctionPointer(__ptr0, typeof(global::SampleLibrary.SomeFunctionPtr));
    }
}

The last line fails to compile due to invalid cast (__ptr0 and IntPtr).  Again, it seems that '__ret' could simply be returned.
I've made the changes manually to test these assertions and it appears to work correctly, both deriving from the generated class in C# and calling from C++ and deriving in C++ and calling from the C#.
OS: Windows 10
Built on VS2019 from recent source (< 1 week).

@NickApps thank you for your simple test and detailed explanation. Unfortunately, we've been too busy to fix this in our spare time. So your options are to either fix it yourself or contact our support.


Error when calling in batch file

I've created a batch file named vs.cmd with the following content:
@echo off

for /f "usebackq tokens=*" %%i in (`"C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -prerelease -latest -products * -requires Microsoft.Component.MSBuild -property installationPath`) do (
  set InstallDir=%%i
)

if exist "%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe" (
  echo MSBuild installed in: %InstallDir%\MSBuild\15.0\Bin\MSBuild.exe
)

(Needed to fix the vswhere.exe path because it's not in the %PATH%.)
Here's the output:

"\Microsoft" kann syntaktisch an dieser Stelle nicht verarbeitet werden.

So that didn't work. Not sure how this is supposed to work at all because the backtick operator doesn't seem to be supported in Windows CMD. Is this a Bash script actually?

If you remove @echo off, you'll see the problem is in the set expression. Regardless, this would be a problem with batch parsing of the for command, which https://stackoverflow.com/questions/6474738/batch-file-for-f-doesnt-work-if-path-has-spaces has recommendations for (though apparently not necessary in newer versions of Windows, as this works as-is on Windows 10 for me using even a full path in the script examples at
https://github.com/Microsoft/vswhere/wiki/Find-MSBuild#batch).
Given your output is in German, could this be code page issue copying and pasting? If I take my following example and put a full path in there, it works:
@echo off

for /f "usebackq tokens=*" %%i in (`call "%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe" -latest -products * -requires Microsoft.Component.MSBuild -property installationPath`) do (
  set InstallDir=%%i
)

if exist "%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe" (
  "%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe" %*
)

I retyped the script you pasted above into a batch file (UTF-8 encoded, latin keyboard) and it worked fine when I put call before the quoted path.

That thing still fails as before. I guess CMD was never and will never be a predictable scripting language. Also, that thing still uses the magic number "15" to find the actual MSBuild path. That's probably as useless as before. vswhere could be useful if it provided the actual MSBuild path and could provide that path directly into an environment variable. But it doesn't provide the first, and the second can only be done with PowerShell or Bash, not CMD.

vswhere is not specific to MSBuild nor even VS. You can use it to find whatever programs you need. If those programs have additional requirements to support side-by-side installs, you'll need to account for those requirements. You're welcome to leave feedback on https://developercommunity.visualstudio.com for respective teams to consider.
The script works on several OS versions I've tried. It likely is an issue with your code page. You can use chcp to see what the current value is, and there is a page on the wiki that explains how to work with different code pages. Beyond that, Stack Overflow may provide better help dealing with code page issues. If you're copying and pasting, make sure that your editor is not transcoding quotes as smart quotes or any other extended characters. As typed, there should be no expected characters beyond the ASCII plane.

It's certainly not a codepage issue, this script only uses ASCII characters. My codepage is 850 (Western DOS). OS is Windows 7.

...to find the actual MSBuild path. ... But it doesn't provide the first, and the second can only be done with PowerShell or Bash, not CMD.

@ygoe you should use additional processing/tool for work with msbuild because the vswhere does not directly related for this tool.
We already discussed about this here - #41, so you can also try to use hMSBuild because it's the only 1 batch file that's needed.
@heaths I think, could be useful to add some note about this for everyone who just need a msbuild tools.

Wow, it looks like rocket science to actually find that MSBuild.exe, even more with each new version of Visual Studio. Maybe it's just simpler to use dotnet msbuild from the .NET CLI?

@ygoe it does not require anything else for user environment (you don't need powershell, or dotnet-cli), just 1 batch script that can be embedded inside other batch scripts etc. Thus, this is the most easy way to provide guaranteed access to any available msbuild tools that's needed (from .NET or VS including latest VS2017) with your source code and any cases like from #41 etc. Or what do you mean ?

@3F I added an example long ago to find MSBuild. I don't know why it doesn't work for @ygoe because if I copy and paste from my example or type it manually (with full path) it works fine on my machines (even Windows 7), but if I copy and paste from his example it doesn't. I have not checked the hex representation of the code points, but it does not indicate a problem with vswhere so there may be better options for dealing with code page issues regarding batch scripts.
As noted elsewhere, vswhere is and will remain generic. With the exception of "15.0" being in the path - and I have mentioned to the MSBuild team this seems unnecessary and is causing issues with callers - it's a fairly fixed path. You can wrap vswhere with scripts to find any tool you want. That's the point.

@heaths

if I copy and paste from his example it doesn't.

if you about script from first post

Here's the output:
"\Microsoft" kann syntaktisch an dieser Stelle nicht verarbeitet werden.

chcp 437
\Microsoft was unexpected at this time.

seems trivial problem with whitespace symbols here:
echo MSBuild installed in: %InstallDir%\MSBuild\15.0\Bin\MSBuild.exe

that is, works for me after this changes:
echo MSBuild installed in: "%InstallDir%\MSBuild\15.0\Bin\MSBuild.exe"


Flutter doctor error

Steps to Reproduce

flutter doctor

Logs

Logs

Doctor summary (to see all details, run flutter doctor -v):
[☠] Flutter (the doctor check crashed)
    ✗ Due to an error, the doctor check did not complete.
      If the error message below is not helpful, please let
      us know about this issue at
      https://github.com/flutter/flutter/issues.
    ✗ UnimplementedError: Host OS not supported.
[!] Flutter IDE Support (No supported IDEs installed)
[☠] Connected device (the doctor check crashed)
    ✗ Due to an error, the doctor check did not complete.
      If the error message below is not helpful, please let
      us know about this issue at
      https://github.com/flutter/flutter/issues.
    ✗ Exception: Platform android is not supported.
[✓] HTTP Host Availability

! Doctor found issues in 3 `categories`

I'm trying to use and modify flutter to work on my devices but It look's weird when I try to run flutter doctor, but when I use `flutter pub get` it working fine. Am i missing something?

what's your os ?

I run flutter inside vm

@couriousdev01 Could you confirm that flutter doctor crashes while flutter doctor -v doesn't? Looks like the case is that flutter doctor is unable to complete the version check

Looking into this issue, looks like Flutter doesn't officially support VMs. This may be an issue with a mis-configured VM or an edge case in the doctor command that doesn't handle. See support platforms.
But since VMs are not supported by Flutter and Flutter recommends development on bare metal, I am closing this issue. If you can reproduce this issue in a non-VM environment, please post the error logs here and I can reopen it.

flutter doctor -v                                       [☠] Flutter (the doctor check crashed)
    ✗ Due to an error, the doctor check did not complete.        If the error message below is not helpful, please let
      us know about this issue at                                https://github.com/flutter/flutter/issues.
    ✗ UnimplementedError: Host OS not supported.               • #0      _currentHostPlatform
      (package:flutter_tools/src/artifacts.dart:691:3)           #1      CachedArtifacts.getArtifactPath
      (package:flutter_tools/src/artifacts.dart:446:59)          #2      FlutterValidator.validate
      (package:flutter_tools/src/doctor.dart:515:47)             #3      Doctor.startValidatorTasks.<anonymous
      closure>                                                   (package:flutter_tools/src/doctor.dart:224:72)
      #4      asyncGuard.<anonymous closure>                     (package:flutter_tools/src/base/async_guard.dart:111:
      32)                                                        #5      _rootRun (dart:async/zone.dart:1391:13)
      #6      _CustomZone.run                                    (dart:async/zone.dart:1293:19)
      #7      _runZoned (dart:async/zone.dart:1829:10)           #8      runZonedGuarded
      (dart:async/zone.dart:1817:12)                             #9      runZoned (dart:async/zone.dart:1748:12)
      #10     asyncGuard                                         (package:flutter_tools/src/base/async_guard.dart:109:
      3)                                                         #11     Doctor.startValidatorTasks
      (package:flutter_tools/src/doctor.dart:216:9)              #12     Doctor.diagnose
      (package:flutter_tools/src/doctor.dart:347:72)             #13     DoctorCommand.runCommand
      (package:flutter_tools/src/commands/doctor.dart:50:48      )
      #14     FlutterCommand.verifyThenRunCommand                (package:flutter_tools/src/runner/flutter_command.dar
      t:1374:12)                                                 <asynchronous suspension>
      #15     FlutterCommand.run.<anonymous closure>             (package:flutter_tools/src/runner/flutter_command.dar
      t:1209:27)                                                 <asynchronous suspension>
      #16     AppContext.run.<anonymous closure>                 (package:flutter_tools/src/base/context.dart:150:19)
      <asynchronous suspension>                                  #17     CommandRunner.runCommand
      (package:args/command_runner.dart:209:13)                  <asynchronous suspension>
      #18     FlutterCommandRunner.runCommand.<anonymous         closure>
      (package:flutter_tools/src/runner/flutter_command_run      ner.dart:281:9)
      <asynchronous suspension>                                  #19     AppContext.run.<anonymous closure>
      (package:flutter_tools/src/base/context.dart:150:19)       <asynchronous suspension>
      #20     FlutterCommandRunner.runCommand                    (package:flutter_tools/src/runner/flutter_command_run
      ner.dart:229:5)                                            <asynchronous suspension>
      #21     run.<anonymous closure>.<anonymous closure>        (package:flutter_tools/runner.dart:62:9)
      <asynchronous suspension>                                  #22     AppContext.run.<anonymous closure>
      (package:flutter_tools/src/base/context.dart:150:19)       <asynchronous suspension>
      #23     main                                               (package:flutter_tools/executable.dart:91:3)
      <asynchronous suspension>
                                                           [!] Flutter IDE Support (No supported IDEs installed)
    • IntelliJ - https://www.jetbrains.com/idea/               • Android Studio -
      https://developer.android.com/studio/                    • VS Code - https://code.visualstudio.com/
                                                           [☠] Connected device (the doctor check crashed)
    ✗ Due to an error, the doctor check did not complete.        If the error message below is not helpful, please let
      us know about this issue at                                https://github.com/flutter/flutter/issues.
    ✗ Exception: Platform android is not supported.            • #0      throwToolExit
      (package:flutter_tools/src/base/common.dart:10:3)          #1      findChromeExecutable
      (package:flutter_tools/src/web/chrome.dart:84:3)           #2      ChromiumLauncher.canFindExecutable
      (package:flutter_tools/src/web/chrome.dart:147:41)         #3      ChromiumDevice.isSupported
      (package:flutter_tools/src/web/web_device.dart:114:41      )
      #4      WebDevices.pollingGetDevices                       (package:flutter_tools/src/web/web_device.dart:362:25
      )                                                          #5      PollingDeviceDiscovery._populateDevices
      (package:flutter_tools/src/device.dart:435:60)             #6      PollingDeviceDiscovery.devices
      (package:flutter_tools/src/device.dart:425:12)             #7      DeviceManager.getAllConnectedDevices
      (package:flutter_tools/src/device.dart:193:20)             #8      DeviceValidator.validate
      (package:flutter_tools/src/doctor.dart:602:55)             #9      Doctor.startValidatorTasks.<anonymous
      closure>                                                   (package:flutter_tools/src/doctor.dart:224:72)
      #10     asyncGuard.<anonymous closure>                     (package:flutter_tools/src/base/async_guard.dart:111:
      32)                                                        #11     _rootRun (dart:async/zone.dart:1391:13)
      #12     _CustomZone.run                                    (dart:async/zone.dart:1293:19)
      #13     _runZoned (dart:async/zone.dart:1829:10)           #14     runZonedGuarded
      (dart:async/zone.dart:1817:12)                             #15     runZoned (dart:async/zone.dart:1748:12)
      #16     asyncGuard                                         (package:flutter_tools/src/base/async_guard.dart:109:
      3)                                                         #17     Doctor.startValidatorTasks
      (package:flutter_tools/src/doctor.dart:216:9)              #18     Doctor.diagnose
      (package:flutter_tools/src/doctor.dart:347:72)             #19     DoctorCommand.runCommand
      (package:flutter_tools/src/commands/doctor.dart:50:48      )
      #20     FlutterCommand.verifyThenRunCommand                (package:flutter_tools/src/runner/flutter_command.dar
      t:1374:12)                                                 <asynchronous suspension>
      #21     FlutterCommand.run.<anonymous closure>             (package:flutter_tools/src/runner/flutter_command.dar
      t:1209:27)                                                 <asynchronous suspension>
      #22     AppContext.run.<anonymous closure>                 (package:flutter_tools/src/base/context.dart:150:19)
      <asynchronous suspension>                                  #23     CommandRunner.runCommand
      (package:args/command_runner.dart:209:13)                  <asynchronous suspension>
      #24     FlutterCommandRunner.runCommand.<anonymous         closure>
      (package:flutter_tools/src/runner/flutter_command_run      ner.dart:281:9)
      <asynchronous suspension>                                  #25     AppContext.run.<anonymous closure>
      (package:flutter_tools/src/base/context.dart:150:19)       <asynchronous suspension>
      #26     FlutterCommandRunner.runCommand                    (package:flutter_tools/src/runner/flutter_command_run
      ner.dart:229:5)                                            <asynchronous suspension>
      #27     run.<anonymous closure>.<anonymous closure>        (package:flutter_tools/runner.dart:62:9)
      <asynchronous suspension>                                  #28     AppContext.run.<anonymous closure>
      (package:flutter_tools/src/base/context.dart:150:19)       <asynchronous suspension>
      #29     main                                               (package:flutter_tools/executable.dart:91:3)
      <asynchronous suspension>
                                                           [✓] HTTP Host Availability
    • All required HTTP hosts are available
! Doctor found issues in 3 categories.


Cannot Sum Double?

Hi,
with the new ef core 2.1 I get errors when I try to sum a nullable doube (double?). E.g.:
        var allArrivedTransports = await _context.Transport.Select(t => new
        {
            TotalChargeableWeightPerTransport =
                   t.TransportItems.Sum(ti => ti.ChargeableWeight))
        })
            .ToListAsync();

ChargeableWeight is a nullable doube. One Transport has one to many TransportItems. I get:
System.InvalidOperationException: No coercion operator is defined between types 'System.Threading.Tasks.Task`1[System.Double]' and 'System.Nullable`1[System.Double]'.
   at System.Linq.Expressions.Expression.GetUserDefinedCoercionOrThrow(ExpressionType coercionType, Expression expression, Type convertToType)
   at System.Linq.Expressions.Expression.Convert(Expression expression, Type type, MethodInfo method)
   at System.Linq.Expressions.Expression.Convert(Expression expression, Type type)
   at Microsoft.EntityFrameworkCore.Query.Internal.RelationalResultOperatorHandler.HandleSum(HandlerContext handlerContext)

All worked well with 2.0.
kind regards, thanks for the greate work you are doing
Further technical details
EF Core version: 2.1
Database Provider: Postgres
Operating system: Windows 10
IDE: Visual Studio 2017 15.Newest

Duplicate of #12314

@maumar - Can you add regression test for this scenario and close the issue?


ACI Burst Scaling Question

Hiya,
What happens when ACI burst scaling AND node auto-scaling are active?
Will the node auto-scaler get triggered and the ACI's fire up to take the load while the nodes are creating and then stop once the nodes are online?
Thanks,
Rob.

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 9d8185fe-e724-7a2d-7579-8e94ef873b36
Version Independent ID: 66dc644d-6edd-b5ad-d043-3ad4659e27b1
Content: Concepts - Scale applications in Azure Kubernetes Services (AKS) - Azure Kubernetes Service
Content Source: articles/aks/concepts-scale.md
Service: container-service
GitHub Login: @mlearned
Microsoft Alias: mlearned

@robs
What happens when ACI burst scaling AND node auto-scaling are active?
By default there is a 10 sec scan interval for a auto-scaler to reevaluate the cluster and then deploy nodes based on need. In this whole time, if the virtual kubelet is enabled and HPA is creating more pods which are in pending state, then ACI bursting will be the only option available to the scheduler for scheduling the pending pods.
Will the node auto-scaler get triggered and the ACI's fire up to take the load while the nodes are creating and then stop once the nodes are online?
Yes, if the node pool has sufficient resources available then nodes takes precedence over virtual kubelet when the scheduler is ranking which infrastructure to schedule the pod on. As the nodes have more resources to offer, the node will be ranked higher than containers which will have specific resource amounts allocated per pod.

@VikasPullagura-MSFT
If the pending pods get scheduled on ACI won't that mean that the node auto-scaler doesn't create a new node because there are no longer any pending pods?
If that's not the case and a node is getting created, will the pods already on ACI get moved back to the new node or will they just stay on ACI until HPA drops them?
If the pods stay on ACI won't the node auto-scaler remove the node once it realises it's not getting used?
Sorry for all of the questions, I just want to make sure I know how it works before deploying it.
Thanks,
Rob.

@robs
Apologies for delayed response. Below are the responses for your questions:
If the total number of pods which are scaled up are all scheduled through ACI bursting by the time cluster autoscaler reevaluates the cluster (after scan-interval), then new nodes will not be provisioned but if there are pods still in pending state due to resource crunch on VMSS node pools then cluster autoscaler will initiate scale up of the VMSS nodepool.
Pods scheduled on the virtual node will not be rescheduled to VMSS node pool nodes as the virtual node is not being scaled down in any case and hence no node drain action is initiated.
The virtual node is considered to be part of a different node pool than the VMSS node pools and cluster autoscaler does not extend to virtual nodes because cluster auto scaling happens through VMSS scale APIs which are not supported in an ACI. Hence cluster autoscaler will perform scale operations only on VMSS nodepools.
Hope this helps.

Hiya,
Thanks for getting back to me.
So the VMSS pool would only scale after all of the permitted ACI instances are in use.
Except in the case that the VMSS auto-scaler happens to re-evaluate before the nodes are scheduled on ACI in which case they get scheduled on the VMSS pool.
To be honest, it sounds like it would be much better to forget the VMSS altogether and just use ACI.
Our usage pattern is 90-95% office hours so I was thinking that the ACI bursting would alleviate the delay waiting for nodes to spin up when everyone comes online, but if they hold on to the pods all day then I don't see the reason for having the VMSS nodes at all.
Am I missing anything in that thinking?
Is there an advantage to a VMSS node pool vs an ACI one?

@robs
There has to be a primary VMSS/AVSet node pool which will have system critical pods scheduled on it. As these pods do not have the toleration for the virtual kubelet and if manually added will be reconciled to original settings by the controller manager they need to be scheduled on VMSS/AVSet node. However for customer hosted applications, virtual kubelet was introduced essentially keeping in mind a rapid and serverless pod scheduling infrastructure. However, just so that you do not reach the limit of ACI cores on a subscription, the taints are deliberately put in place so that you can judicially control how much of the workload is being scheduled on the virtual nodes.
Doc reference.

The other limitations with virtual nodes are:
Virtual Nodes functionality is heavily dependent on ACI's feature set. In addition to the quotas and limits for Azure Container Instances, the following scenarios are not yet supported with Virtual nodes:

Using service principal to pull ACR images. Workaround is to use Kubernetes secrets
Virtual Network Limitations including VNet peering, Kubernetes network policies, and outbound traffic to the internet with network security groups.
Init containers
Host aliases
Arguments for exec in ACI
DaemonSets will not deploy pods to the virtual nodes
Virtual nodes support scheduling Linux pods. You can manually install the open source Virtual Kubelet ACI provider to schedule Windows Server containers to ACI.
Virtual nodes require AKS clusters with Azure CNI networking.
Using api server authorized ip ranges for AKS.
Volume mounting Azure Files share support General-purpose V1. Follow the instructions for mounting a volume with Azure Files share
Using IPv6 is not supported.

Reference document.

Thank you for the info, very much appreciated.
We need windows containers :(
I'll raise any queries over on the virtual-kubelet repo if I have issues with the install.


Update SDK to changes in openapi spec

Changes

Tests

[ ] make test passing
[ ] make fmt applied
[ ] relevant integration tests applied

Codecov Report
Patch has no changes to coverable lines.

Files Changed
Coverage

service/billing/model.go
ø

service/catalog/api.go
ø

service/catalog/impl.go
0.00%

service/catalog/model.go
0.00%

service/compute/model.go
ø

service/iam/model.go
ø

service/jobs/model.go
ø

service/ml/model.go
ø

service/provisioning/model.go
ø

service/settings/api.go
0.00%

... and 6 more

:loudspeaker: Thoughts on this report? Let us know!.


Condition on job status - Step 1

Users can use predefined macros to specify the condition on job status. For example, they can write condition: one_success for a job in the flow yaml file. And this job will run as soon as one of its parent jobs has succeeded.
Below is the list of condition macros we will support:

all_success (default)
all_failed
all_done
one_failed: fire as soon as at least one parent has failed.
one_success: fire as soon as at least one parent has succeeded.
one_failed_all_done: fire when at least one parent has failed and all parents have finished.
one_success_all_done: fire when at least one parent has succeeded and all parents have finished.

By default, the condition on job status is all_success.
The execution logic will change under different conditions. For example, the flowFailed flag might not always be set to true when a job fails for a conditional workflow.
Users can define both condition on runtime parameters and job status. E.g., condition: one_success && ${jobA: param1} == 1
Please see the design doc for more details: #1826

Pull Request Test Coverage Report for Build 3838

113 of 120 (94.17%)  changed or added relevant lines in 7 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.2%) to 35.879%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

azkaban-common/src/main/java/azkaban/flow/ConditionOnJobStatus.java
15
16
93.75%

azkaban-exec-server/src/main/java/azkaban/execapp/ConditionalWorkflowUtils.java
38
40
95.0%

azkaban-common/src/main/java/azkaban/executor/ExecutableNode.java
8
10
80.0%

azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
28
30
93.33%

Totals

Change from base Build 3834:
0.2%

Covered Lines:
10206

Relevant Lines:
28446

💛  - Coveralls

I added some Todo notes in the code about the remaining steps:

Cancel all pending jobs before the flow is finalized and execturorService is shutdown. This is mainly to support ONE_SUCCESS and ONE_FAILURE conditions because the flow could potentially finish before all running jobs have finished. This would cause jobs to run forever if not canceled properly.
Support conditions on embedded flows.

Yes, UI part will be added later when all the main logic has been implemented.
Users will be able to click the job and see the condition for that job like the current job properties.
You can see more details in the design doc:
https://docs.google.com/document/d/1op_RPD1G65NpKsunAv04Rww5klU7AhbqnPMA0QunP0g/edit?usp=sharing


Cant play recordings

Checklist:

[x] I updated to the latest version available
[x] I cleared the cache of my browser

Release with the issue:
5.0.0-beta.1
Last working release (if known):
Not known
Browser and Operating System:
Chrome 112.0.5615.121
Windows 10
Description of problem:
Cant play recordings from the lovelace card. I can playback recordings using the media section in hass. The frigate integration card is on version 4.0.0. There does not seem to be any errors in the web inspector. I have added a screenshot of the player with a blank screen which is all i get when i try and play recordings. Snapshots however do still work.

Thanks for the report @TelepathicWalrus , this is a rather glaring issue with the current beta. It's already fixed in code, and will be in the next beta (that I hope to do shortly).


ionic2 - bug(toast, tabs) - Toast displayed on a tabs page displays on top of the tabs

Ionic version:  (check one with "x")
[ ] 1.x
[ x] 2.x
I'm submitting a ...  (check one with "x")
[ x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://forum.ionicframework.com/ or http://ionicworldwide.herokuapp.com/
Current behavior:
Toasts are displayed on top of the tabs
Expected behavior:
On android apps, the native behavior is to show the toast above the tabs.

Steps to reproduce:

Create a tabs page
Display a toast
Observe that it is displayed on top of the tabs

Other information:
Yo can take a look to the official photos app from Google. https://play.google.com/store/apps/details?id=com.google.android.apps.photos&hl=es

Hello e! Thanks for opening an issue with us. I am going to make this a feature request and move this issue over to our internal list of feature requests for evaluation. We are continually prioritizing all requests that we receive with outstanding issues. We are extremely grateful for your feedback, but it may not always be our next priority. I'll copy the issue back to this repository when we have begun implementation. Thanks!

Any information regarding whether we could expect this in the next couple of weeks or whether we should build it ourselves?

So far, what you can easily do is to add the following styles in your global.scss file:
.md {
  .toast-tabs {
    height: calc(100% - #{$tabs-md-tab-min-height});
  }
}

And then add the toast-tabs class when you are creating your toast.
Note: this example only works in Android and Web, you have to add the corresponding styles fo each platform you are developing for.


Logical NOT before contains does not include NULL check

I have a piece of code that looks like the following:
public List<string> ResolveDomicileIdsByForeignGeoId(IEnumerable<int?> geoIds)
        {
            var domIds = myContext.DomicileMappings
                .Where(x => !geoIds.Contains(x.GeoId))
                .Select(x => x.DomicileId).Distinct().ToList();
            return domIds;
        }

The GeoId column in the DomicileMappings table is nullable.
The generated sql for this query is as follows:
SELECT DISTINCT [x].[DomicileId]
FROM [DomicileMappings] AS [x]
WHERE [x].[GeoId] NOT IN (77)

However I would expect it to check for nulls as well, as follows:
SELECT DISTINCT [x].[DomicileId]
FROM [DomicileMappings] AS [x]
WHERE [x].[GeoId] NOT IN (77) OR [x].[GeoId] IS NULL

since the column is nullable. Am I wrong to expect this?
Further technical details
EF Core version: v2.2.0
Database Provider: Sql Server (Azure)

Furthermore, I would expect this to work in Linq To Sql as it works with in memory objects:
            List<int?> hi = new List<int?>();
            List<int?> yo = new List<int?>();

            yo.Add(1);
            hi.Add(1);
            hi.Add(2);
            hi.Add(null);

            var r = hi.Where(x => !yo.Contains(x)).ToList();
//r = 2, null

This issue is lacking enough information for us to effectively reproduce. Please post a runnable project/solution or complete code listing that demonstrates the behavior you are seeing.

Following code
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.Logging;

namespace EFSampleApp
{
    public class Program
    {
        public static void Main(string[] args)
        {
            using (var db = new MyContext())
            {
                // Recreate database
                db.Database.EnsureDeleted();
                db.Database.EnsureCreated();

                // Seed database

                db.AddRange(
                    new Blog { Value = null },
                    new Blog { Value = 2 }
                    );

                db.SaveChanges();
            }

            using (var db = new MyContext())
            {
                // Run queries
                var ids = new List<int?>
                {
                    1,
                    2,
                    null
                };
                var query = db.Blogs
                    .Where(b => !ids.Contains(b.Value))
                    .ToList();
                Console.WriteLine(query.Count);
            }

            Console.WriteLine("Program finished.");
        }
    }

    public class MyContext : DbContext
    {
        private static ILoggerFactory LoggerFactory => new LoggerFactory().AddConsole(LogLevel.Trace);

        // Declare DBSets
        public DbSet<Blog> Blogs { get; set; }

        protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
        {
            // Select 1 provider
            optionsBuilder
                .UseSqlServer(@"Server=(localdb)\mssqllocaldb;Database=_ModelApp;Trusted_Connection=True;Connect Timeout=5;ConnectRetryCount=0")
                //.UseSqlite("filename=_modelApp.db")
                //.UseInMemoryDatabase(databaseName: "_modelApp")
                .EnableSensitiveDataLogging()
                .UseLoggerFactory(LoggerFactory);
        }

        protected override void OnModelCreating(ModelBuilder modelBuilder)
        {
            // Configure model
        }
    }

    public class Blog
    {
        public int Id { get; set; }
        public int? Value { get; set; }
    }
}

Generated SQL
      SELECT [b].[Id], [b].[Value]
      FROM [Blogs] AS [b]
      WHERE [b].[Value] NOT IN (1, 2) AND [b].[Value] IS NOT NULL

EF Core version 2.2.0-rtm-35687

@smitpatel thanks for looking at this. I will work on submitting a project to reproduce the issue tonight. Looking at the example code briefly, I wonder if you instantiate the list with just: var ids = new List<int?>                 {                     1                 };
it will replicate the issue... The generated query you posted is different from what I am after.
Regardless, Ill get a reproducable project up soon. Thanks.

dupe of #11464


daos: dcp: enhanced error checking

My branch deviated a bit from my previous PR, I had many small commits, and git wasn't cooperating, so I'm just creating a new PR entirely.
common/mfu_errors.h

New file
Defines some generic error codes, codes for dcp, and codes for DAOS

Ranges are in the 1000s, 1100s, and 4000s

Defines MFU_ERRF and MFU_ERRP for printing the error codes.

Formatted as: MFU_ERR(#)
Could be improved in the future to print the"string" error code instead of just MFU_ERR

DAOS has something similar to this

common/mfu_io

Defined daos_access

common/mfu_param_path.c

mfu_param_path_check_copy - Return on DAOS error

common/mfu_util

daos_connect

Added flag for whether or not to connect to pool
Added flag for whether or not to auto-create the destination container

No longer creates the source container automatically

These flags allow a centralized way to capture errors. I.e. only one bcast is needed for pool connection, cont connection, cont creation
Rank 0 now tracks and broadcasts any errors before trying to share the handles
Function returns an error

dcp/dcp.c

Use the new error codes from mfu_error.h
DAOS errors are generally handled more precisely

Each process tracks local errors, and stops making DAOS calls once it has run into an error
Allreduce on local DAOS errors, so all processes will know to exit
Check DAOS arguments before trying to make DAOS calls
Refactored daos_connect calls to better capture errors and exit if found
More gracefully handle a failed daos_init call
Exit if DAOS source is DAOS destination

closes #363
closes #361
closes #370

Thanks for all the input @adammoody !
I should have these things all resolved tomorrow.

I made some style updates, corrected the "hole" with the way local_daos_error and daos_connect were being handled, and also corrected another hole with local_daos_error and same_pool.

@daltonbohning , thanks for checking those other return code cases.  I made one more style request, but otherwise it looks good to me.
The DAOS code that leads into the tool is getting long enough that we can think about abstracting that into a function (starting at line 632 in dcp.c).  That can be done later, though.

@adammoody You're welcome, but really, thank you for catching this! Another set of eyes definitely helps.
I've had a similar thought about abstracting the daos-specific code. I'll go ahead and make an issue to keep track of this, and I'll make those changes when I get a chance, especially since we will be making more daos changes and additions in the future.
I pushed a couple more things in the last few minutes. If you don't find anything else, I don't have anything more to add to this PR.

No problem.  Those MPI corner cases can be tricky.
Thanks, @daltonbohning .  Looks good to me.  Would you mind squashing those commits into one and force pushing back?

Oh, you can leave the mfu_alltrue commit separate in the squash since that's a different fix.

Sorry, I'm working on this. My repo seemed to have a breakdown and it's taking a lot of time to squash these commits.
(It explains the strange out-of-sync issue I ran into earlier)