Compilation failed: internal error: previously-checked referenced subpattern not found

While using swiftmailer with apache 2, php 5.4.7 (XAMPP 1.8.1) I get the following warning and fails to deliver the message:
preg_match(): Compilation failed: internal error: previously-checked referenced subpattern not found at offset 4246

at swiftmailer/library/classes/Swift/Mime/Headers/MailboxHeader.php on line 306

The regexp in question is the following:
/^(?:(?:(?:(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?(?:[a-zA-Z0-9!#\$%&'\*\+\-\/=\?\^_`\{\}\|~]+(\.[a-zA-Z0-9!#\$%&'\*\+\-\/=\?\^_`\{\}\|~]+)*)+(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?)|(?:(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?"((?:(?:[ \t]*(?:\r\n))?[ \t])?(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21\x23-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])))*(?:(?:[ \t]*(?:\r\n))?[ \t])?"(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?))@(?:(?:(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?(?:[a-zA-Z0-9!#\$%&'\*\+\-\/=\?\^_`\{\}\|~]+(\.[a-zA-Z0-9!#\$%&'\*\+\-\/=\?\^_`\{\}\|~]+)*)+(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?)|(?:(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?\[((?:(?:[ \t]*(?:\r\n))?[ \t])?(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x5A\x5E-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])))*?(?:(?:[ \t]*(?:\r\n))?[ \t])?\](?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))*(?:(?:(?:(?:[ \t]*(?:\r\n))?[ \t])?(\((?:(?:(?:[ \t]*(?:\r\n))?[ \t])|(?:(?:[\x01-\x08\x0B\x0C\x0E-\x19\x7F]|[\x21-\x27\x2A-\x5B\x5D-\x7E])|(?:\\[\x00-\x08\x0B\x0C\x0E-\x7F])|(?1)))*(?:(?:[ \t]*(?:\r\n))?[ \t])?\)))|(?:(?:[ \t]*(?:\r\n))?[ \t])))?))))$/D

The problem only occurs when the page is served through apache. When I run a copy the regexp to a test file and validate against that, it does not issue the warning.
I have temporarily "solved" the problem by removing the validation altogether. However, I hope there is a better solution.
Thank you!

Is there now any news on this? I'm currently experiencing this error with my Laravel application and am desperately searching for the cause. It seems to appear only with certain configurations involving an Apache. My setup runs recent versions of PHP, Apache and PRCE but the error still persists.

Is there any update on this? We are currently experiencing this issue with the current 5.6.9 dotdeb packages. In 5.6.9 the PCRE Version was updated to 8.37 (http://php.net/ChangeLog-5.php#5.6.9) and this does not seem to play well with the swiftmailer regex.

Anyone solved the problem ? I have this erreur after a recent apt-get update on my server.

up

I just downloaded and compiled libpcre 8.37 and the swiftmailer regex works just fine using pcregrep. So I think the issue is more likely to be with php or apache2 itself? Some weird libpcre mismatch or something... not sure :(

Just a hint from the TYPO3 world: https://forge.typo3.org/issues/67048
We face the same issue. Affected PHP versions seem to be 5.6.9, 5.5.25 and 5.4.41
This bug crashes the whole template engine Fluid in our case!

Nice job altough hard to fix from here :(
But swift 6 will work with emailchecker
Le 26 mai 2015 12:04 AM, "Markus Klein"<EMAIL_ADDRESS>a écrit :

Just a hint from the TYPO3 world: https://forge.typo3.org/issues/67048
We face the same issue. Affected PHP versions seem to be 5.6.9, 5.5.25 and
5.4.41
This bug crashes the whole template engine Fluid in our case!
—
Reply to this email directly or view it on GitHub
https://github.com/swiftmailer/swiftmailer/issues/259#issuecomment-105325149
.

To check if you have mismatching versions of PCRE between the system library and PHP you can run pcretest -C and php -i | grep PCRE. If the versions don't match, this is likely the cause of the error.
I'll ask the support of my hoster what exactly they did to make the versions match and report back later.

As noted in https://bugs.php.net/bug.php?id=69689 obviously they messed up the version number as well and PHP reports a wrong version number.

My hoster solved the version mismatch by rebuilding PHP using the configure script with --with-pcre-regex=/usr. A PHP upgrade might fix this issue as well.

My hoster solves the situation downgrading the php version to 5.5.24. Good work!

Seems to have been fixed in source: https://github.com/php/php-src/commit/f38ca75a3cc5737bdb922dc5e2a7505cd20cd7ea

Can anyone confirm this has been resolved with the latest snapshot?

I just hit the same bug today using PHP 5.5.25-1~dotdeb+7.1. Hope it's resolved as well. :(

I updated my PHP version to PHP 5.6.9-1~dotdeb+7.2 and I still get this bug.

Thanks to this threads I fixed a similar problem in my WP installation.

Same with 5.5.25 and 5.6.10 from dotdeb

And 5.6.9 ?  Or a self build ?  It was an error in packaging basically the
bundled pcrelib is only partially updated
Le ven. 12 juin 2015 14:14, Xavier HAUSHERR<EMAIL_ADDRESS>a
écrit :

Same with 5.5.25 and 5.6.10 from dotdeb
—
Reply to this email directly or view it on GitHub
https://github.com/swiftmailer/swiftmailer/issues/259#issuecomment-111473346
.

Seems to be a packaging bug indeed:
root@jfg-stage-internal-1:~# php -v
PHP 5.6.10-1~dotdeb+7.1 (cli) (built: Jun 11 2015 20:38:39)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies
with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
root@jfg-stage-internal-1:~# php -i | grep PCRE
PCRE (Perl Compatible Regular Expressions) Support => enabled
PCRE Library Version => 8.36 2014-09-26
PHP changelog show 8.37...

It's not the first time unfortunately and we got the bug reports everytime
Le ven. 12 juin 2015 14:20, Xavier HAUSHERR<EMAIL_ADDRESS>a
écrit :

Seems to be a packaging bug indeed:
root@jfg-stage-internal-1:~# php -v
PHP 5.6.10-1~dotdeb+7.1 (cli) (built: Jun 11 2015 20:38:39)
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies
with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2015, by Zend Technologies
root@jfg-stage-internal-1:~# php -i | grep PCRE
PCRE (Perl Compatible Regular Expressions) Support => enabled
PCRE Library Version => 8.36 2014-09-26
PHP changelog show 8.37...
—
Reply to this email directly or view it on GitHub
https://github.com/swiftmailer/swiftmailer/issues/259#issuecomment-111475015
.

It's not a packaging issue, PCRE_MINOR hasn't been changed correctly in PHP upstream. I'm currently building packages of PHP 5.6, 5.5 and 5.4 with this cosmetic change. Stay tuned.
https://github.com/gplessis/dotdeb-php5/commit/f3749b75f65e4ff20a3419b706d0a077892b990d
BTW, that's just a cosmetic change, not sure if it solves your original issue. Please keep me posted.

Guys, I just uploaded new PHP 5.6 packages (versions 5.6.10-1~dotdeb+7.2 and 5.6.10-1~dotdeb+zts+7.2). Could you please confirm that PCRE 8.37 is displayed? If so, does it fixes your original issue?

Thx for the update. Now the version looks correct:
php -v
PHP 5.6.10-1~dotdeb+7.2 (cli) (built: Jun 13 2015 20:08:39)

php -i | grep PCRE
PCRE Library Version => 8.37 2015-04-28

Unfortunately the original problem with the swiftmailer regex using apache2 mod php stays the same :(

I just uploaded new PHP 5.6 packages (versions 5.6.10-1~dotdeb+7.3 and 5.6.10-1~dotdeb+zts+7.3) that fix your issue.

@gplessis thanks, this fixed it for me.

Thanks @gplessis. Works wonder here.


CHW/ANC - Family Registration

[ ] User can register a family. A
As part of family registration, a location is collection in order to add that family to the map? (Need confirm if this is the way forward or if we want to register actual structures)
[ ] User can view a family profile #284
[ ] User can assign a head of household #285

The user can register a new family by clicking the option menu in the top right corner. There there will be an "register family" option.

Once that is selected, the user will be dropped directly into the family registration form. Once they fill this in and hit "next" the will be sent to the second page to register the head of household. The user can then choose to continue registering additional family members by hitting "next" or "save" and exit.

The exact fields collected in these forms is being confirmed and I will update the story with that information.

For now, the only plan definition we will have in place is ANC, so the registration of family members won't trigger the addition of any plan definitions to their care plans. But, in the future, we would want it to be possible to automatically do so. A good example here would be family planning. All women within a certain age range are eligible for family planning services, so we would want that to be included their care plan automatically.

@f-odhiambo I don't think we ever decided on how to represent families in FHIR.
From the UI it seems clear this needs to be a separate resource in itself, i.e. a family isn't a group of people, it's its own object.
B/c of that, using Group w/a GPS extension to register family seems like the best thing, thoughts?
CC @dubdabasoduba @fredhersch @jingtang10

I agree. I think this use case could be  represented as

Family - Group to type Patient for person
Family name - Group.name
Family members  - Group.member
Numbers - Group.quantity

CC @dubdabasoduba @fredhersch @jingtang10 @isabelcshaw @pld

I thought Group here was being used to assign a population of Patients to a CareTeam i.e. a set of patients within a village to the CHW that was responsible.
I came across this yesterday - https://fhirblog.com/2020/02/10/family-fhir-with-sushi/ - which suggested using the Patient => RelatedPerson(Patient) relationship and setting the RelationshipType. I wonder if you could use this to almost infer the Head of Household .. i.e the root of the relationship tree ..  and enforced by some protocols e.g:
When registering a household, the Head of the Household has to be registered first .. then any members are added after all with RelatedPerson(Patient) to the first Patient
If it's not a Household, then there would be no relationships and it could be identified as an individual Patient

We're considering using Group for both of those purposes.
If we use only Patient and RelatedPerson we either (1) can't represent a family separate from the people in the family, or (2) use a Patient resource that represents a family instead of a person
@isabelcshaw do we need to represent a family as separate from the people in it? If not, I agree that Patient and RelatePerson will be enough

I thought Group here was being used to assign a population of Patients to a CareTeam i.e. a set of patients within a village to the CHW that was responsible.
I came across this yesterday - https://fhirblog.com/2020/02/10/family-fhir-with-sushi/ - which suggested:using the Patient => RelatedPerson(Patient) relationship and setting the RelationshipType.
I wonder if you could use this to almost infer the Head of Household .. i.e the root of the relationship tree .. and enforced by some protocols e.g:

When registering a household, the Head of the Household has to be registered first ..
Then any members are added after all with RelatedPerson(Patient) to the first Patient
If it's not a Household, then there would be no relationships and it could be identified as an individual Patient

The group resource allows other groups to be group members. That way we can have a group of family (groups) then assign a care team to the larger group.
We can then use the Relateperson(patient) relationship in the family (group) to infer who is the family head.

This also brings me to this discussion. It has the potential to require a UI rethink on OpenSRP web.

@pld a few thoughts on the need to represent a family as separate from the people in it:

The family is the core component of the CHW app and is definitely the core grouping for the user and represented in the UI (register view, family profile view, etc). That being said, it sounds like the UI could pull from another resource.

We can already anticipate tasks/activities in the CHW workflow that will need to be associated with a resource on a "household" level. These are things like a sanitation assessment or stock management form that would not be a part of an individual patient's care plan. Even more simply, we'll need a way for a household/family to be due for a visit once a month. Given our current use cases, we could probably get away with associating these tasks with a structure or a head of household, but it might be a good idea to discuss what that task generation looks like, what constraints that could introduce in the long term, and how this could affect reporting.

The Reveal/campaign use cases currently use the concepts of structures, families, and patients. For example, in the MDA workflow, the structure is identified as residential, the family is registered, eligible children are registered, and then drugs are dispensed. That being said, I could see a way that MDA and IRS could work with just structures or related persons. Would need @samkanga input on FI workflows.

K thanks, do we have any situations where we register a family that is not associated with a structure?

@pld not in the CHW workflows. We do in campaign workflows.
Two other notes here: 1. It is possible for families to move. I think the most common example would usually be changing catchments, but if we wanted to maintain any separation of a family's medical history and a structure, that could be challenging. And relatedly 2. LMH hasn't mentioned this yet, but, from experience, it is possible for there to be multiple families per structure. I believe we avoid this at the moment bc OpenSRP doesn't deal with the structure concept.

@isabelcshaw ok thanks, sounds like keeping families separate may not be strictly necessary but if we don't do it we'd have a bunch of pretty ugly workarounds, b/c we'd be overloading the Patient that represents the head-of-household to also represent the family, so if we can support the CarePlan, etc. generation we need off of a resource that's only representing a family (like a Group), we'd be in better shape.
I duplicated some of the above in this comment thread in the sdk workflow planning doc, also putting inline below for posterity.

There are 2 use-cases here. We're investigating if we could avoid the separate Group representing a family in (2) but it sounds like conceptually it would be much cleaner to have it.

generate and attach tasks to structures. We're planning on representing structures as Location resources of physicalType Building that are partOf a Location resource of physicalType Jurisdiction. When a structure is created (or modified, and maybe on some set time interval) in a Jurisdiction, we'd call $apply on the Location resource representing the structure and the Plan Definition resource that has as its subject.subjectReference the Location jurisdiction this structure is partOf. The output of $apply, e.g. a Task to spray the structure with insecticide, would be linked to the structure and queryable to know the status of the Task(s) assigned to the struture.

User story is, as a malaria sprayer guided by a digital health app, when I register a new structure I want to know whether I should spray it based upon the plan defined for the jurisdiction my newly registered structure is in.

generate and attach Task(s) to a family. A family is a unit separate from any members of the family and represented by the Group resource. We would call $apply on the family Group and the PlanDefinition assigned to the CareTeam that Group is a member of (TBD on this relationship). and generate Task(s) attached specifically to the family (not the individuals in it).

User story is, as a CHW I need to complete tasks assigned to families independent of any members in them, such as assessing the sanitation status of the family, this task has its own status and due date and is not connected to any specific family member.

@isabelcshaw on this issue it's not related to a family.  Anytime a women of reproductive age is registered in the system we would need to check to see if they are eligible for family planning and generate a care plan if so.

For now, the only plan definition we will have in place is ANC, so the registration of family members won't trigger the addition of any plan definitions to their care plans. But, in the future, we would want it to be possible to automatically do so. A good example here would be family planning. All women within a certain age range are eligible for family planning services, so we would want that to be included their care plan automatically.

Couple of thought on the above.  I am inclined right now to go with @fredhersch suggestion of having a household be based on creating a head of household and then assigning relationships. We will need to support the scenario of a family living in a compound in multiple structure. In such a scenario, would we want all family members assigned to a single HH? or would we want to register the people living in each structure (usually a wife and her kids) as seperate households?  In this case we can still create a relationship by making each women the head of household but then indicating they are married to a head of household in a different family.  I think keeping the app flexible and allowing people to implement this how they want is probably what we want to do.
In terms of structure, I want to make sure that is decoupled.  For non reveal use cases, you should be able to register a head of household and then assign them to a location.  The location could be a gps point or a structure on a map. The location could have other meta data like an address, photo, etc.  For multi structure families, we could map each mother and her sub-household to a different structure or we can just use the main household depending on the use case.  The later approach will work fine if we aren't using the structures as a basis for coverage like we do for reveal.
For the reveal use case, we need to figure out how to assign tasks to structures.  Once a head of HH is assigned to that structure, certain subsequent tasks can be assigned to that person.
For task assignment and capturing encounter data on structures we should probably give a bit of thought on the intervention.  Eg. if you visit a structure and give a bednet or give medicine the service is done to the people living at the structure because they can take that bednet with them and leave.  If you are doing something physical to the structure like spraying, the benefits of the spray is carried over to the new family that moves into that structure.  So we will need to ultimately be able to assign tasks and associate events to non patients I think at the end of the day.
For liberia though, I think linking everything to the head of household could probably work.

Cool, how would that handle the sanitation assessment use case? Would that be a task generated for and assigned to the head of household?
We couldn't tie these to Location since as you mentioned we can have multiple HHs per structure.
To gen for the HH we'd need logic that says only generate these PlanDefinition activities for the head of household, and these would be tied to a Patient (the HH)

On Jul 13, 2021, at 16:37, Matt Berg @.***> wrote:

@isabelcshaw on this issue it's not related to a family. Anytime a women of reproductive age is registered in the system we would need to check to see if they are eligible for family planning and generate a care plan if so.
For now, the only plan definition we will have in place is ANC, so the registration of family members won't trigger the addition of any plan definitions to their care plans. But, in the future, we would want it to be possible to automatically do so. A good example here would be family planning. All women within a certain age range are eligible for family planning services, so we would want that to be included their care plan automatically.
Couple of thought on the above. I am inclined right now to go with @fredhersch suggestion of having a household be based on creating a head of household and then assigning relationships. We will need to support the scenario of a family living in a compound in multiple structure. In such a scenario, would we want all family members assigned to a single HH? or would we want to register the people living in each structure (usually a wife and her kids) as seperate households? In this case we can still create a relationship by making each women the head of household but then indicating they are married to a head of household in a different family. I think keeping the app flexible and allowing people to implement this how they want is probably what we want to do.
In terms of structure, I want to make sure that is decoupled. For non reveal use cases, you should be able to register a head of household and then assign them to a location. The location could be a gps point or a structure on a map. The location could have other meta data like an address, photo, etc. For multi structure families, we could map each mother and her sub-household to a different structure or we can just use the main household depending on the use case. The later approach will work fine if we aren't using the structures as a basis for coverage like we do for reveal.
For the reveal use case, we need to figure out how to assign tasks to structures. Once a head of HH is assigned to that structure, certain subsequent tasks can be assigned to that person.
For task assignment and capturing encounter data on structures we should probably give a bit of thought on the intervention. Eg. if you visit a structure and give a bednet or give medicine the service is done to the people living at the structure because they can take that bednet with them and leave. If you are doing something physical to the structure like spraying, the benefits of the spray is carried over to the new family that moves into that structure. So we will need to ultimately be able to assign tasks and associate events to non patients I think at the end of the day.
For liberia though, I think linking everything to the head of household could probably work.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.

Francis also brought up whether we should use Person and not Patient here, need to figure that out. Good next step is write out a resource-diagram of a family and how we'd get household and person activities from the people resources.

On Jul 13, 2021, at 16:54, Peter Lubell-Doughtie @.***> wrote:

Cool, how would that handle the sanitation assessment use case? Would that be a task generated for and assigned to the head of household?
We couldn't tie these to Location since as you mentioned we can have multiple HHs per structure.
To gen for the HH we'd need logic that says only generate these PlanDefinition activities for the head of household, and these would be tied to a Patient (the HH)

On Jul 13, 2021, at 16:37, Matt Berg @.***> wrote:

@isabelcshaw on this issue it's not related to a family. Anytime a women of reproductive age is registered in the system we would need to check to see if they are eligible for family planning and generate a care plan if so.
For now, the only plan definition we will have in place is ANC, so the registration of family members won't trigger the addition of any plan definitions to their care plans. But, in the future, we would want it to be possible to automatically do so. A good example here would be family planning. All women within a certain age range are eligible for family planning services, so we would want that to be included their care plan automatically.
Couple of thought on the above. I am inclined right now to go with @fredhersch suggestion of having a household be based on creating a head of household and then assigning relationships. We will need to support the scenario of a family living in a compound in multiple structure. In such a scenario, would we want all family members assigned to a single HH? or would we want to register the people living in each structure (usually a wife and her kids) as seperate households? In this case we can still create a relationship by making each women the head of household but then indicating they are married to a head of household in a different family. I think keeping the app flexible and allowing people to implement this how they want is probably what we want to do.
In terms of structure, I want to make sure that is decoupled. For non reveal use cases, you should be able to register a head of household and then assign them to a location. The location could be a gps point or a structure on a map. The location could have other meta data like an address, photo, etc. For multi structure families, we could map each mother and her sub-household to a different structure or we can just use the main household depending on the use case. The later approach will work fine if we aren't using the structures as a basis for coverage like we do for reveal.
For the reveal use case, we need to figure out how to assign tasks to structures. Once a head of HH is assigned to that structure, certain subsequent tasks can be assigned to that person.
For task assignment and capturing encounter data on structures we should probably give a bit of thought on the intervention. Eg. if you visit a structure and give a bednet or give medicine the service is done to the people living at the structure because they can take that bednet with them and leave. If you are doing something physical to the structure like spraying, the benefits of the spray is carried over to the new family that moves into that structure. So we will need to ultimately be able to assign tasks and associate events to non patients I think at the end of the day.
For liberia though, I think linking everything to the head of household could probably work.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.

The other important implication of no separate family is no family registration, but we could still build a household list from the people registered as head of household

On Jul 13, 2021, at 16:58, Peter Lubell-Doughtie @.***> wrote:

Francis also brought up whether we should use Person and not Patient here, need to figure that out. Good next step is write out a resource-diagram of a family and how we'd get household and person activities from the people resources.

On Jul 13, 2021, at 16:54, Peter Lubell-Doughtie @.***> wrote:

Cool, how would that handle the sanitation assessment use case? Would that be a task generated for and assigned to the head of household?
We couldn't tie these to Location since as you mentioned we can have multiple HHs per structure.
To gen for the HH we'd need logic that says only generate these PlanDefinition activities for the head of household, and these would be tied to a Patient (the HH)

On Jul 13, 2021, at 16:37, Matt Berg @.***> wrote:

@isabelcshaw on this issue it's not related to a family. Anytime a women of reproductive age is registered in the system we would need to check to see if they are eligible for family planning and generate a care plan if so.
For now, the only plan definition we will have in place is ANC, so the registration of family members won't trigger the addition of any plan definitions to their care plans. But, in the future, we would want it to be possible to automatically do so. A good example here would be family planning. All women within a certain age range are eligible for family planning services, so we would want that to be included their care plan automatically.
Couple of thought on the above. I am inclined right now to go with @fredhersch suggestion of having a household be based on creating a head of household and then assigning relationships. We will need to support the scenario of a family living in a compound in multiple structure. In such a scenario, would we want all family members assigned to a single HH? or would we want to register the people living in each structure (usually a wife and her kids) as seperate households? In this case we can still create a relationship by making each women the head of household but then indicating they are married to a head of household in a different family. I think keeping the app flexible and allowing people to implement this how they want is probably what we want to do.
In terms of structure, I want to make sure that is decoupled. For non reveal use cases, you should be able to register a head of household and then assign them to a location. The location could be a gps point or a structure on a map. The location could have other meta data like an address, photo, etc. For multi structure families, we could map each mother and her sub-household to a different structure or we can just use the main household depending on the use case. The later approach will work fine if we aren't using the structures as a basis for coverage like we do for reveal.
For the reveal use case, we need to figure out how to assign tasks to structures. Once a head of HH is assigned to that structure, certain subsequent tasks can be assigned to that person.
For task assignment and capturing encounter data on structures we should probably give a bit of thought on the intervention. Eg. if you visit a structure and give a bednet or give medicine the service is done to the people living at the structure because they can take that bednet with them and leave. If you are doing something physical to the structure like spraying, the benefits of the spray is carried over to the new family that moves into that structure. So we will need to ultimately be able to assign tasks and associate events to non patients I think at the end of the day.
For liberia though, I think linking everything to the head of household could probably work.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.

Couple of follow up thoughts
For the sanitation use case, we would assign the task to the head of household who then would be assigned to a location.  You are probably doing a sanitation assessment at the compound level and not individual structure level anyways. If you want to do per structure you would assign to the sanitation task to the moms (other heads of households).
I don't know about the person or patient. Person may makes sense but I need to understand the difference. @f-odhiambo can you provide some more context to your idea here?
For family registration I don't understand the point Peter. We can either put them all in a single household linked to one structure or we can do all them as separate hh linked to a common head of hh.  I don't think we need to support at this point the idea if single hh to multiple structures. This is something we have entertained for reveal but I don't think we should try and support right now.

On the family registration, the UI has a screen that's "register a family" we wouldn't have that screen anymore, we'd have "register a head of household" or something like that which is a (slight?) change in UI/UX.
This all sounds pretty good if we can get away with it, I might be missing something, but from a tech perspective the pro is we don't have to worry about generating things for a Group, which is an unknown and definitely outweighs the con of additional business logic to treat HHs like families

You can still have a UI that says register household and we then just
register a head of household. We sort of do this already in the wcaro app I
believe
On Tue, Jul 13, 2021 at 7:45 PM Peter Lubell-Doughtie <
@.***> wrote:

On the family registration, the UI has a screen that's "register a family"
we wouldn't have that screen anymore, we'd have "register a head of
household" or something like that which is a (slight?) change in UI/UX.
This all sounds pretty good if we can get away with it, I might be missing
something, but from a tech perspective the pro is we don't have to worry
about generating things for a Group, which is an unknown and definitely
outweighs the con of additional business logic to treat HHs like families
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/opensrp/fhircore/issues/276#issuecomment-879476234,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAAOEQLTWL37AKYUTOUWVZ3TXTF2JANCNFSM46UCQ24A
.

That'll work if when registering the members of the household you make users specify whether they're registering a head of household, and if they are instead of creating a new entity they're editing the entity you already created when they registered the household
If you don't do that, or if people don't select that when registering the head of household, you have a patient/person that's the household separate from the head of household, which is fine as long as we don't include that resource in counts of household members and people

Couple of follow up thoughts
For the sanitation use case, we would assign the task to the head of household who then would be assigned to a location. You are probably doing a sanitation assessment at the compound level and not individual structure level anyways. If you want to do per structure you would assign to the sanitation task to the moms (other heads of households).
I don't know about the person or patient. Person may makes sense but I need to understand the difference. @f-odhiambo can you provide some more context to your idea here?
For family registration I don't understand the point Peter. We can either put them all in a single household linked to one structure or we can do all them as separate hh linked to a common head of hh. I don't think we need to support at this point the idea if single hh to multiple structures. This is something we have entertained for reveal but I don't think we should try and support right now.

From the FHIR spec, the resource Patient is used when someone is being used/tracked in a clinical setup. In a non-clinical setup, we could use

Person (provides a reference set of common demographics for an individual ) could be used to represent someone who is not receiving clinical care. This resource has 1..1 reference to a (Patient | Practitioner | RelatedPerson | Person)
Related Person  next of kin to patient or person (wife, husband, guardian, relative, friends)  . This resource has 1..1 reference to only a Patient

cc @isabelcshaw @mberg @pld

@f-odhiambo @fredhersch @brynrhodes
We talked through the various options and (although semantically it's arguable a family is better represented some sort of group, or maybe organization) for CarePlan generation purposes, we know $apply works well for Patients, so we want to use that as much as possible. And this example linked from the blog article Fred shared uses Patient and RelatedPerson http://hl7.org/fhir/patient.html#maternity.
A family is represented by the same Patient resource that represents the primary PoC (PPoC), membership in the family is a set of .link.other RelatedPerson resources who's RelatedPerson.patient is the non-PPoC family member.
The steps for registering a family and it's members will look like:

enter a family by entering family name

creates a Patient (A) resource with Patient.name set to the entered name

add a member to family

if only Patient A.name exists for the family, user must select if entering the PPoC or not
if PPoC, changes saved as edits to Patient A
if NOT PPoC, on save

create Patient B
create RelatedPerson resource with RelatedPerson.patient = Patient B
set RelatedPerson.relationship to FAMMEMB for family member
edit Patient A resource to set Patient A.link [append] .other = RelatedPerson

Common operations will look like:

Listing families (equivalent to listing PPoCs)

This is problematic, unless we are guaranteed that all patients are added as members of a family, if that's the case
Fetch all Patients from RelatedPerson.patient where RelatedPerson.relationship = FAMMEMB, remove this subset from all Patients, the remaining Patients are your families

Listing members of a family (assuming we know the PPoC)

Get list of Patient.link.other.patient where other.type = RelatedPerson and other.relationship = FAMMEMB
If we're only storing family relationships with .link we would not need to restrict this query with the above and can get all the Patient.link.other.patient

Listing tasks for a family (assuming we know the PPoC)

Get the CarePlan, where CarePlan.subject = this Patient AND some special TBD field tells you this is a family CarePlan, not a Patient CarePlan

Limitations

The family name of the family must be the same as the family name of the PPoC (resolvable using multiple names and setting .name.use)
The query in (3) looks inefficient and will be incorrect if we have patients that are not part of a family, having a flag for PPoC Patient's would be much easier, there's no where obvious to add this to the existing patient, we could abuse .name or .managingOrganization (maybe .name.use = official means it's a family name/PPoC, pretty ad hoc) but an extension is better
This is only using FAMMEMB in the relationship, this makes queries easier, we could instead use a more specific relationship (eg child, spouse, wife, husband, etc.) and then query where .relationship is in that set, or we could use both FAMMEMB and the more specific (keeping the other queries as is)
Need to figure out the TBD field in (5)

Some value sets that can be used represent family relationships. This is if we stick to Patient-Related person representation

A set of codes that can be used to indicate the relationship between a Patient and a Related Person  - http://hl7.org/fhir/R4/valueset-relatedperson-relationshiptype.html
Sibling  - https://terminology.hl7.org/2.1.0/ValueSet-v3-Sibling.html
There is a query patient by phonetic, which could be tagged to the family ID to return a family, need to figure out that query  https://www.hl7.org/fhir/searchparameter-registry.html#individual-phonetic

Group as family

Pros

Allows multiple hierarchy level where each person is directly related to Group and maintains separate relationship with each member if needed through extension (do not see a field relationships where one person can have multiple relationships)
A member does not care who is the head of household
Changing the head of family does not matter
Records encounters against family directly and changing head does not impact this process
Cons
A family breaking into smaller families would be a problems and need creating another family and removing each Group/Member separately with updates to Group and Patient both.
Family member does not know its family rather a family knows it members

Patient/Person as Family

Pros

Each family member knows it Head and refer the record directly (via relationship)
Family member still can manage separate relation with other members via some relationships extension
A smaller family can be omitted out by making another member head and changing the relationships
Cons
Death of person of change of Head is very expensive where every related person would have to be updated
Old encounters for Head now needs to be copied or linked to new head or how do we manage the old encounters against a family?

An important aspect is the search available into FHIR server.
Can we fetch / search patients based on relationships @dubdabasoduba , Can we fetch members of a group together?

@maimoonak The challenge of using the group is that the Worklofw API does not support it. The workflow API  takes in Patient as a subject to generate a care plan i.e. $apply(paitent_id, plan_deifiton_id) = careplan

Could we explore the workaround if we stick to the Patient-Related Person approach

Thanks everyone for the research and discussion on this.
My gut feeling is that going with patients and relationships probably makes the most sense if that is the idea that is best supported / follows the design patterns most closely in FHIR.
If we go this route, I think the key thing is it's important that the head of household really represents the unit where we want to assign tasks to the family level.
For example, we could have a large family living on a compound.
HH1 - Husband and his first wife and their children
HH2 - Second wife and their children
HH3 - Third wife and their children
In this scenario, it would depend on how we designed the health intervention on how we registered the households.
If a CHW just was registering kids and doing maternal health it would probably work that we register all family members to a single HH under the husband.  If we wanted to do tasks at the structure level. Eg. do a wash check at the hut level or spray their structure, we would need to probably register each HH separately.  In this case, each wife would be a head of household and have a relationship to their husband.   So we'll have a situation where you have a head of household linked to another head of household but as long as their is only one head of household in the family then it's fine.  They would be treated as different (but related) families in the second use case.
If someone dies, do we need to migrate their encounters?  We could retain the relationship still in the system.  We probably just need to figure out the logic that new tasks / events are linked to the new head of household. Not sure we have to reassign data though.
In general though I think we can handle most use cases with the approach of linking certain activities to the head of household and not individual members.

If we wanted to follow FHIR we'd probably use Group but it's not practical b/c of $apply limitations.
Let's scope using a Patient who has something of a primary point of contact (ppoc, head of household) flag, we might be able to get by without a flag and use logic but not sure. Also we're not trying to represent the detail of the family (for now), only that there's a ppoc and family members.
@maimoonak and @mberg that's a good catch on death, we probably will want to migrate anything tied to the previous ppoc when the ppoc changes, like in the case of a death, probably requiring a new ppoc to be set before changing the active field on the existing ppoc to false.
Though, I don't think we'd need to edit the members, we'd look at the existing ppoc make sure the new ppoc points to the same RelatedPersons in its links, that should be sufficient

I think if the main reason we're going with this approach is $apply limitations we should talk with Bryn about this.
The CarePlan resource does allow for the subject to be a Group. But the CQL evaluator APIs assume the subject of the CarePlan is a Patient - I think. So if we go with the Group approach, we need to make sure that the APIs consider Group CarePlans.
If we go with the head patient approach and represent a HH using a head patient, then 1) what does that mean for CQL authoring as now the CQL needs to understand the meaning of a head patient, and 2) how do we distinguish resources that reference the patient from resources that reference the HH (they'll all reference the same thing which is the head patient). @maimoonak mentioned we can use Encounter type or category, but not all other resources necessarily have a field like it.

@jingtang10  we have another issue on encounters here #406

@f-odhiambo my point was kinda the opposite - I think we can get it to work with encounter but how do we get it to work with all types of resources.

So the overall flow for enroll family, family member, and anc entry is implemented and here are few important points and caveats and queries
Patient resource has no field to mark as family head attribute and has no search params to filter except few demographics https://www.hl7.org/fhir/patient.html#search
We discussed to use other entities like Flag/Observation/Encounter to use as a base to query Family Head (Flag->Patient) and then the relevant Members(Patient.link.other), however, if we have to use any other resource as a base then Group should be the one as this is the best fit for a family. The other entities would be problematic in longer run as these has large data plus queries over these would require us to be tied to use a SNOMED code display/code which can lead to data consistency issues and passing on this info to other developers in longer run.
One thing that is missing in SDK but part of FHIR protocol is Common Search Params which are Profile, Tag, etc. These are fields which implementations can use to assign business context to any Resource
So now it means that we should use Patient resource to represent Family independently via Profile/Tag which is embedded into patient.meta. Now issue with SDK is that ResourceIndexer is only indexing last_updated field and not other search params which means we can not query Patient on these.
To make it work for time being without relying on SDK for now I explored the way it saves/updates/query and apply indexes into above mentioned class and added a class PatientExtended into fhircore which overrides the behavior of indexer and adds the tag/profile as searchable attributes and now allow querying patients via tag.
Now what we do is save Patient with Flag+Extension(Family), Add tag based on this flag, (We can use Profile as well).
All members have link.other relationship with head.
Now we have dependency over two items in SDK (@jingtang10 ) to make it work rightway (not blocker for merging though)

SDK allows Common Search Params
SDK fixes the issue Salman reported which does not allow sync back of resources with references

I do not think that the approach of using a tag/profile is a hack itself but @jingtang10 can give a final verdict over this.
We mark ANC in similar way i.e. based on flag add tag to Woman
So the e2e flow works like below.

If Patient is the target, we should define a "headOfHousehold" extension (probably in WHO-Core) and use that to indicate which patient is considered head of household. Using profiles to distinguish resources is an anti-pattern in FHIR.

@brynrhodes Thanks a lot for the feedback. We are not using profile. How about using 'tag' since this is searchable (we want to query patients who are head of households). Below are patients generated by our code rightnow code (Head of household, Pregnant Member, Other Member)
Head Of Household: {"resourceType":"Patient","id":"5ff09958-12c6-4996-948e-d4229a3d4d03","meta":{"profile":["http://hl7.org/fhir/StructureDefinition/Patient"],"tag":[{"system":"https://www.snomed.org","code":"77386006","display":"Pregnant"},{"system":"https://www.snomed.org","code":"35359004","display":"Family"}]},"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/flag-detail","valueString":"Pregnant"},{"url":"http://hl7.org/fhir/StructureDefinition/flag-detail","valueString":"Family"}],"name":[{"family":"ghgh","given":["jhgjh"]}],,"gender":"female","birthDate":"2021-08-12","address":[{"city":"jhjh"}]}
Pregnant Member: {"resourceType":"Patient","id":"a8be747b-5698-4ff1-96cd-383948137af4","meta":{"profile":["http://hl7.org/fhir/StructureDefinition/Patient"],"tag":[{"system":"https://www.snomed.org","code":"77386006","display":"Pregnant"}]},"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/flag-detail","valueString":"Pregnant"}],"name":[{"family":"jhj","given":["jhkj"]}],"gender":"female","birthDate":"2021-08-04","link":[{"other":{"reference":"Patient/5ff09958-12c6-4996-948e-d4229a3d4d03"},"type":"refer"}]}
Other Member: {"resourceType":"Patient","id":"ce515390-a4c5-4c40-91f2-97f4029bb430","meta":{"profile":["http://hl7.org/fhir/StructureDefinition/Patient"]},"name":[{"family":"jhgh","given":["hjhj"]}],"gender":"male","birthDate":"2021-08-04","link":[{"other":{"reference":"Patient/5ff09958-12c6-4996-948e-d4229a3d4d03"},"type":"refer"}]}

Hi @maimoonak , that makes sense, but I would still recommend establishing an extension to explicitly indicate that a patient is a "headOfHousehold". You could provide guidance (and even a profile to enforce) that the Family tag be used in addition to the headOfHousehold extension, but tags should not be used as a stand-in for semantics, because the FHIR spec indicates that applications are not required to process tags to interpret the meaning of a resource: https://hl7.org/fhir/resource-definitions.html#Meta.tag

@brynrhodes Thanks. Would add the "headOfHousehold" extension to our Patient.

So the overall flow for enroll family, family member, and anc entry is implemented and here are few important points and caveats and queries
Patient resource has no field to mark as family head attribute and has no search params to filter except few demographics https://www.hl7.org/fhir/patient.html#search
We discussed to use other entities like Flag/Observation/Encounter to use as a base to query Family Head (Flag->Patient) and then the relevant Members(Patient.link.other), however, if we have to use any other resource as a base then Group should be the one as this is the best fit for a family. The other entities would be problematic in longer run as these has large data plus queries over these would require us to be tied to use a SNOMED code display/code which can lead to data consistency issues and passing on this info to other developers in longer run.
One thing that is missing in SDK but part of FHIR protocol is Common Search Params which are Profile, Tag, etc. These are fields which implementations can use to assign business context to any Resource
So now it means that we should use Patient resource to represent Family independently via Profile/Tag which is embedded into patient.meta. Now issue with SDK is that ResourceIndexer is only indexing last_updated field and not other search params which means we can not query Patient on these.
To make it work for time being without relying on SDK for now I explored the way it saves/updates/query and apply indexes into above mentioned class and added a class PatientExtended into fhircore which overrides the behavior of indexer and adds the tag/profile as searchable attributes and now allow querying patients via tag.
Now what we do is save Patient with Flag+Extension(Family), Add tag based on this flag, (We can use Profile as well).
All members have link.other relationship with head.
Now we have dependency over two items in SDK (@jingtang10 ) to make it work rightway (not blocker for merging though)

SDK allows Common Search Params
SDK fixes the issue Salman reported which does not allow sync back of resources with references
SDK has almost all classes internal and its really hard to extend and modify the application behavior

I do not think that the approach of using a tag/profile is a hack itself but @jingtang10 can give a final verdict over this.
We mark ANC in similar way i.e. based on flag add tag to Woman
So the e2e flow works like below.

@jingtang10 Kindly review subsequent comments here and share your thoughts

@jingtang10 Kindly review subsequent comments here and share your thoughts

One thing that is missing in SDK but part of FHIR protocol is Common Search Params which are Profile, Tag, etc. These are fields which implementations can use to assign business context to any Resource

can you create an issue in android-fhir please? thanks!

If Patient is the target, we should define a "headOfHousehold" extension (probably in WHO-Core) and use that to indicate which patient is considered head of household. Using profiles to distinguish resources is an anti-pattern in FHIR.

do we also need extensions to mark referenced resources as family-oriented resources rather than patient-oriented resources? i.e. if there's a task for family referencing the head of household, then we need to mark that task as a household task to distinguish other tasks related to the head patient themself.

@jingtang10 the profile, tags are part of fhir protocol i.e. searchable resources. I did not find extensions or these properties. If we make this part of sdk it would be great but I am not sure how do we synchronize this feature with FHIR. @pld can comment on this.

https://github.com/opensrp/fhircore/pull/493 The was supposed to close the issue but now it needs to be on new code structure

@brynrhodes Thanks. Would add the "headOfHousehold" extension to our Patient.

can you link an example here please? thanks!

@jingtang10 the profile, tags are part of fhir protocol i.e. searchable resources. I did not find extensions or these properties. If we make this part of sdk it would be great but I am not sure how do we synchronize this feature with FHIR. @pld can comment on this.

my suggestion is similar to bryn's. but not only on the patient but also on the referenced resources to distinguish a household task from a patient task.


[WIP] Use key store from default SSLContext, if SSLSocketFactory is not set

Related: issue #1711.

Is this still a work in progress?

Yes. It'll be finished when OkHttp uses the default KeyStore, or if that
isn't a desirable fix, the test will be changed to use the default
SSLSocketFactory, in which case the test will start passing.
Either way it'll be a test that documents the recommended way to do client
certificates in OkHttp.
There's some tidying to do too. I opened the PR, despite it being
incomplete, for early feedback and in case others found it useful. I can
remove it, if having a broken PR is inconvenient.
On Wed, 9 Mar 2016, 03:12 Jesse Wilson<EMAIL_ADDRESS>wrote:

Is this still a work in progress?
—
Reply to this email directly or view it on GitHub
https://github.com/square/okhttp/pull/2393#issuecomment-194092489.

Could you turn this into a sample? We've got a samples directory where this would fit neatly.
Any way you can change your code to configure the keystore programmatically instead of with system properties? The problem with system properties is that they're global, which is unlikely to work in applications that make multiple kinds of HTTP requests.

Thanks for prompt (modulo time zone) responses.
Yes, I can make it a sample instead of a test case. Why do you prefer it be
a sample, rather than a test, OOC?
With regards to programmatically configuring keystores, do you mean my
application code, or the code in the pull request?
If the former then the code that uses OkHttp is sonar-runner-api (used by
maven-sonar-plugin). Users expect to be able to pass client certificates
using the standard javax.net.ssl.keyStore system property, when executing
mvn.
Or do you mean the latter, and for example to add clientCertificate method
to OkHttp.Builder? I could. My concern with that is that other applications
that use OkHttp will not support client certificates (this tends to not be
considered by tool developers), making it hard for client certificate users.
What do you mean by "multiple kinds of HTTP requests"? I'll have a think
what I expect from a HTTP library API re client certificates, as if I had
multiple client certificates, and I wanted things like connection pooling
to work in some sane way. It's not immediately obvious what a good API for
that is.
On Wed, 9 Mar 2016, 11:58 Jesse Wilson<EMAIL_ADDRESS>wrote:

Could you turn this into a sample? We've got a samples directory where
this would fit neatly.
Any way you can change your code to configure the keystore
programmatically instead of with system properties? The problem with system
properties is that they're global, which is unlikely to work in
applications that make multiple kinds of HTTP requests.
—
Reply to this email directly or view it on GitHub
https://github.com/square/okhttp/pull/2393#issuecomment-194262532.

Why do you prefer it be a sample, rather than a test, OOC?

If the goal is documentation, samples feel less contrived. We expect end users to cut & paste samples into their projects. Samples can also hit webservers on the public Internet.

With regards to programmatically configuring keystores, do you mean my application code, or the code in the pull request?

Yes, application code. I don’t think system properties are a good idea.

Users expect to be able to pass client certificates using the standard javax.net.ssl.keyStore system property, when executing mvn.

If the Maven plugin supports this, then it should have its own configuration mechanism. Even just reading the supported system properties and configuring OkHttp with them should be sufficient.

Closing as stale. Happy to accept again if you’d like to resubmit without system properties!


Add reference to examples in readme.md?

I just stumbled upon the examples in the script... what about adding a reference to those examples in the readme.md so that it is more discoverable?
Happy to submit a PR 😊

Sorry for not responding until now. That's a great idea, feel free to submit a PR to update the readme.md, perhaps with a new section called "More Examples"?

No worries, it happens 😀.  Cool, I’ll give it some & report back


Trade futures

Chore
As a team we want to make it clearer that you can trade futures on Vega (rather than perps, options - yet!) so that potential users know exactly what they can do right now.
Tasks

[x] Update the description of Console on the landing page AND on the use vega page to "Trade cash settled futures on the fully decentralised Vega network"
[ ] Reflect "Alpha mainnet is live with cash settled futures" in trading takeover / equivalent (speaking to Mary, David and Oli)
[ ] Create markets page

[x] update intro para to "Create a futures market"
[ ] add the ability to find out more e.g. an info icon "Vega's alpha mainnet currently supports cash settled futures"

[x] Update trading CTA on website top right to "Trade futures (Testnet)"
[x] Update roadmap description of V1 Mainnet to include spots and perpetuals
[x] Update roadmap description to add that this could include advanced products like options (community generally interested in them)

Pull request
Deploy preview

Adding “futures” to the nav CTA breaks the layout at some viewport widths. This may be exacerbated in languages other than English. Should we:

Remove “(testnet)“?
Wait until trading launches so we can say “Trade futures” without “(testnet)“?

We have a Spanish translation for that CTA. Now we’re changing it, how do we flag that it needs translated again? Do we just overwrite the Spanish translation with English for now?
Spot markets were already mentioned, I've added mentions of perpetuals and options, need someone to check what I've written makes sense
Creating a new component to add more info here seems like overkill, needs some thought to see if we can integrate this in plain text

Mary has added cash settled futures to the trading takeover script, so that go live along with that feature
Calum has updated the copy for the new roadmap, too, so this will also be reflected when the new version goes live
Calum confirmed my suggestion for the other copy changes


How to find the data iterator used for validation

Hi everybody,
I want to validate the training progress using perplexity after some iterations. As it has been mentioned in mainLoop.py, I have to specify "param valid_data: data iterator used for validation". But I don't find the Iterator class for validation. As I used the same like train_data, I get an error considering the queue. It would be appreciated, if someone let me know, how to validate my training which needs validation iterator.
Thanks

Hi,
groundhog isn't supported or development anymore. We use blocks. See the
warning on this page:
https://github.com/lisa-groundhog/GroundHog
On Thu, Dec 10, 2015 at 1:31 PM, papar22<EMAIL_ADDRESS>wrote:

Hi everybody,
I want to validate the training progress using perplexity after some
iterations. As it has been mentioned in mainLoop.py, I have to specify
"param valid_data: data iterator used for validation". But I don't find the
Iterator class for validation. As I used the same like train_data, I get an
error considering the queue. It would be appreciated, if someone let me
know, how to validate my training which needs validation iterator.
Thanks
—
Reply to this email directly or view it on GitHub
https://github.com/lisa-groundhog/GroundHog/issues/42.

To be honest, I knew that. I am using blocks as well. But I need some changes in groundHog as I already have some models and impelementations using it. That' s why I asked this question.

Ok, maybe someone else can answer, I don't know groundhog, so I can't
easily help you.
On Thu, Dec 10, 2015 at 4:07 PM, papar22<EMAIL_ADDRESS>wrote:

To be honest, I knew that. I am using blocks as well. But I need some
changes in groundHog as I already have some models and impelementations
using it. That' s why I asked this question.
—
Reply to this email directly or view it on GitHub
https://github.com/lisa-groundhog/GroundHog/issues/42#issuecomment-163749543
.

@papar22 Hi, did you solve this problem? I am using this lisa-groundhog, and I think it's necessary to use validate data. Could you help? Thanks.

Hi, if any of you guys have an answer to this questions I'd love to know. Right now it seems to me that there is no was to run validation between epochs.
Thanks!
Lotem

Just a note, this repo isn't supported anymore and isn't developed.
Just to let you know.
On Wed, Nov 2, 2016 at 7:56 AM, Lotemp<EMAIL_ADDRESS>wrote:

Hi, if any of you guys have an answer to this questions I'd love to know.
Right now it seems to me that there is no was to run validation between
epochs.
Thanks!
Lotem
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/lisa-groundhog/GroundHog/issues/42#issuecomment-257844398,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AALC-14nI40vQRDtyTFqi4xQMpRbOKpTks5q6HqKgaJpZM4Gy-el
.


Web: Support for translations/language packs

Currently we do not support switching display language in the web.

We currently mainly depend on  VSCode web. And our main language is not English. It would be great helpful to us if VSCode web can support localization on web. Thanks.

Hi there!
I'm one of the maintainers of coder/code-server. We've (@code-asher and myself) modified our vscode fork to support changing the display language. Here is the PR: https://github.com/coder/vscode/pull/34
@TylerLeonhardt I see you're planning to look into this for Jan. 2022. Is this something we can help with?

@jsjoeio If I understand the change correctly, you essentially offload all translation handling to the remote side? Yeah this would be generally good for any "server-full" vscode offerings. If you would like to contribute a similar change, we'd love that!
That solution won't work for serverless environments like vscode.dev so we'll have to approach that differently.

@TylerLeonhardt yes! Awesome. I'll see if I can get started on this next week.

Heads-up. Some other priorities have come up and I haven't been able to get to this yet. I hope to soon, but if not, someone else feel free to tackle.

Emm, this issue title is hard to search, could we mention it in https://code.visualstudio.com/docs/getstarted/locales that it's not supported on the web yet and ask user to track this issue?

@gregvanl what are your thoughts on updating the doc that @Mister-Hope suggested?

@jsjoeio FYI, I may end up tackling the part that you did later this month (translations working when there's compute on the server side) because it's a feature we're looking to light up.
I just wanna let you know because I think it would be awesome to see this contributed by the community especially since you already did the work basically :) but also no pressure whatsoever. If you beat me to it, awesome. If not, totally fine of course!

Oh awesome!
I agree, it would be really cool for us to contribute that back :) Well, if I can squeeze it in this month, I will. Thanks for the heads-up!

Added mention that VS Code for the Web doesn't support Language Packs https://github.com/microsoft/vscode-docs/commit/da8ff664125b301f5b583c76b4cfbe3b49cb7da6

@jsjoeio I wasn't able to get to this and will try to pick it up next month. Feel free to grab it if you can :)

@TylerLeonhardt buying me more time! Haha thanks for mentioning - going to see if I can squeeze it in for March's sprint 👀

One of these days, I promise lol

Lol my feelings exactly. We're moving to a patches approach with https://github.com/coder/code-server/pull/4997 so it should be easier to start working on this next month 🤞🏼

I started working on this but I'm having a hard time getting Code Web to run with Extensions. I don't want to blow up everyone's notifications so what's the best place to ask questions/get help/etc.?

@jsjoeio I think in your case you want to run server-full which is ./scripts/code-server.sh instead of code-web.sh which is serverless.
My understanding of your change is that you defer translations handling to the remote side so in this case, we do need server-full experience.

@TylerLeonhardt ahhh! Didn't realize that. That worked! Thank you.
I'll update this comment to keep track of my notes
Notes
Added VS Code Marketplace to product.json and searched for Spanish extension. I was able to install it successfully, but then it added the "Install in Browser" button even though it's technically installed.

@TylerLeonhardt yes! Same way. I didn't author this patch so still understanding this patch as well but I am guessing that is from the LocalizationService we create here
@code-asher can correct me though

@TylerLeonhardt I have a PR open ready for feedback! I ran into build issues so couldn't get the demo video in but maybe you can help (details in PR).

Sorry for the late response.  The Configure Display Language command is contributed by importing  localizations.contribution.ts
https://github.com/microsoft/vscode/blob/6a6df96d5e276dc9586741d27d289beac0891957/src/vs/workbench/contrib/localizations/browser/localizations.contribution.ts#L31-L32
Here is the import in the diff:
https://github.com/coder/code-server/blob/d796cc20e0cb6fa231173e93d8d2df654f8e7e40/patches/display-language.diff#L260
But using the command in web does not actually work as it writes to browser storage so the server has no access to it (--locale works though).  The way we "fixed" this was to write the argv.json file (and all user settings actually) to the server's disk instead.

@vmasse-gir that command is available in insiders.vscode.dev and will be in the next stable release.

:globe_with_meridians: :warning: :mega:  I have published a new version of vscode-nls and merged in the PRs (one and two) into Core that should enable translations for the web for built-in extensions. I have also updated Azure Repos extension as the guinea pig to make sure this all works properly.
This means that at this point, all “feature bits” are done with translations for the web. We just have some bugs to iron out. Since those bugs are tracked in other issues I will close this now.
Tomorrow, all built-in extensions should be localized and the Azure Repos extension. If all goes smoothly, I'll start updating other extensions to take advantage of these changes.

@TylerLeonhardt that's wonderful to hear! When will this be available in Core/Stable release?
(asking because that will allow us to remove our patch)

Unfortunately, I need to reopen this as we need to take a slightly different approach.

We need this feature for https://github.com/microsoft/vscode-dev/issues/477 as well.

With the new l10n API that has been finalized, this item is "done". https://github.com/microsoft/vscode/issues/164438 will track onboarding built-in extensions to the new API.


#hacktoberfest Make your first pull request (Begineers)

If you are a first-time contributer or you want to participate in hactoberfest and get yourself some cool stickers and t-shirt just add your names to the html with a link to your profile. Look at readme for more details.

When I tried to push to master as well as to new branch created to my local repository, permission denied. Can you look into this.

@sanghisha145 Guessing you have not logged in with github on git. Anyways just fork and update the html as given in readme by going on to your own forked repo on github , would take 2-3 mins

Thanks, actually after forking I had to clone my forked repo, did with original

does the name come immediately or after the merge is approved?


Calendar does not support RedisStorage2

# /app/test.py
from aiogram import Bot, Dispatcher, executor
from aiogram.contrib.fsm_storage.redis import RedisStorage2
from aiogram.dispatcher.filters.state import StatesGroup, State
from aiogram.types import Message

from aiogram_dialog import Window, Dialog, DialogRegistry, DialogManager, StartMode
from aiogram_dialog.widgets.kbd import Button
from aiogram_dialog.widgets.text import Const
from datetime import date

from aiogram.types import CallbackQuery

from aiogram_dialog import DialogManager
from aiogram_dialog.widgets.kbd import Calendar

async def on_date_selected(c: CallbackQuery, widget, manager: DialogManager, selected_date: date):
    await c.answer(str(selected_date))

storage = RedisStorage2('redis')
bot = Bot(token='TOKEN')
dp = Dispatcher(bot, storage=storage)
registry = DialogRegistry(dp)

class MySG(StatesGroup):
    main = State()

main_window = Window(
    Const("Hello, unknown person"),
    Calendar(id='calendar', on_click=on_date_selected),
    state=MySG.main,
)
dialog = Dialog(main_window)
registry.register(dialog)

@dp.message_handler(commands=["start"])
async def start(m: Message, dialog_manager: DialogManager):
    await dialog_manager.start(MySG.main, mode=StartMode.RESET_STACK)

if __name__ == '__main__':
    executor.start_polling(dp, skip_updates=True)

sid@83cfd5fbfc97:/app$ python test.py
Updates were skipped successfully.
Task exception was never retrieved
future: <Task finished name='Task-9' coro=<Dispatcher._process_polling_updates() done, defined at /home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/dispatcher.py:409> exception=TypeError('Object of type date is not JSON serializable')>
Traceback (most recent call last):
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/dispatcher.py", line 417, in _process_polling_updates
    for responses in itertools.chain.from_iterable(await self.process_updates(updates, fast)):
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/dispatcher.py", line 238, in process_updates
    return await asyncio.gather(*tasks)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/handler.py", line 116, in notify
    response = await handler_obj.handler(*args, **partial_data)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/dispatcher.py", line 259, in process_update
    return await self.message_handlers.notify(update.message)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/handler.py", line 129, in notify
    await self.dispatcher.middleware.trigger(f"post_process_{self.middleware_key}",
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/middlewares.py", line 53, in trigger
    await app.trigger(action, args)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/dispatcher/middlewares.py", line 106, in trigger
    await handler(*args)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram_dialog/context/intent_filter.py", line 66, in on_post_process_message
    await proxy.save_context(data.pop(CONTEXT_KEY))
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram_dialog/context/storage.py", line 45, in save_context
    await self.storage.set_data(
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/contrib/fsm_storage/redis.py", line 307, in set_data
    await redis.set(key, json.dumps(data), expire=self._data_ttl)
  File "/home/sid/.local/lib/python3.9/site-packages/aiogram/utils/json.py", line 43, in dumps
    return json.dumps(data, ensure_ascii=False)
  File "/usr/local/lib/python3.9/json/__init__.py", line 234, in dumps
    return cls(
  File "/usr/local/lib/python3.9/json/encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/usr/local/lib/python3.9/json/encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "/usr/local/lib/python3.9/json/encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type date is not JSON serializable

There is no date type in json. It is not RedisStorage2 issue. Probably need convert datetime type into string or timestamp  when serialializing?


Operator update channel, deployment names

The current stable version (early June 2021) of the pipelines operator does not work on learn.openshift.com - it would only work when I set the update channel to ocp-4.6

workshop/content/06trigger-pipeline.adoc start the pipelines with -p deployment-name=vote-api and -p deployment-name=vote-ui. These should be updated to -p deployment-name=pipelines-vote-api and -p deployment-name=pipelines-vote-ui respectively.

Hello, this looks more like a learn.openshift.com scenario issue, this project is only for the RHPDS lab which is working correctly because it points to OCP 4.6.
Can you open an issue here: https://github.com/openshift-labs/learn-katacoda/issues ?


Writer for Linux

For this Firefox issue I started implementing a MD writer for Linux. It can be found here: https://github.com/msirringhaus/minidump_writer_linux
It's still very rough around far too many edges, but the main functionality seems to work ok already. Also, it's not designed yet for other platforms.
I have not used this crates definitions in minidump-common/format.rs for two reasons:

It was said that adding more crates to the Firefox tree was difficult from a review POV. But as it turns out, this crate probably could be added with minor effort. Ideally, its dependencies would need to be aligned with the versions vendored in Firefox (updating them in Firefox involves much testing-work to verify nothing else breaks).
The definitions in minidump-common/ do not work for writing to [u8] yet. For this they would either need to be defined as repr(C, packed), which may lead to undefined behavior (which is what I'm doing at  the moment with my defintions). Or IntoCtx from scroll would need to be implemented for all structs. As far as I can tell, there is no automated possibility yet, so this would have to be done either by hand or via some derive-macro, yet to be invented.

I'd like to discuss, if and how we could integrate those two repos. If you are interested, we might even think about merging them into one.

Ok now that I'm done slapping this crate into shape I can look at this older issue. Especially relevant since I'm hoping to start up on the macos version of this.
Issue 1 isn't a big deal -- rust-minidump is now part of our toolchains so we're already trusting the code. This would make it part of the rust vendor, which should be fine. Although I would probably pull out format.rs into a more dedicated crate (minidump-sys?) -- minidump_common has some random stuff that doesn't really matter.
Issue 2 is trivially solved by deriving Pwrite on every type we currently implement Pread for (I tested the data roundtrips right, at least for SYSTEM_INFO). Yes that's confusing because it's actually implementing IntoCtx, but that's how their derives are named. I had to remove one repr(packed) from a type but since we read with Pread I don't think it was actually doing anything? Maybe making it easier for Rust to compile to a memcopy (doubtful).


Repeated mz values

Hello, I am using msconvert to convert raw files to mzML with centroiding (using cwt filter with SNR=1 and a minimum peak spacing=0.01), but after converting the files I noticed that some of the scans have repeated mz values.
I am using MSConvert 3.019269 1e153dfa2 on Windows 10 Enterprise 2016 LTSB, but I also saw this bug on Windows 7 SP1.
The files I am trying to convert are Waters RAW files, but I also saw repeated values on Thermo Files.

Can you give more details and examples? Is it Waters IMS data?

It's LC-MS data from a Waters Xevo G2-S QTof. I can provide a .RAW file as an example if you want.
Duplicate values only appear when performing peak picking on profile data. If no centroiding is done there aren't any problems...
I noticed the duplicate values when I was processing the converted data using pyopenms, but I don't think it's a problem of pyopenms

Yes I'll need an example file.

Hi, sorry for the delay. Here is a link for one of the RAW files were I detected duplicated values. The filters I used on msconvert were:

Subset with MSLevel = 1
cwt with SNR=1 and minimum peak distance=0.01

in this python script you can see where the repeated values appear:

Fixed in #937 . Only for CWT though. I noticed that the Waters peak picker also returns duplicate peaks. I may fix that in a separate PR, but for now it is returning the peaks exactly as Waters provides them. I also added a centroid option to CWT (defaults to off for now) which will use the centroid (weighted average) of each peak profile as the m/z rather than the apex m/z. I didn't make it the default because I haven't tested it enough. But it should theroetically be good to use on Waters IMS data after --combineIonMobilitySpectra and scan summing, because in that case their native centroiding doesn't work.


Update electron to 1.7.5 [WIP]

Note: do not merge until this is thoroughly tested on all OSes.

[ ] Tested on Win32
[ ] Tested on Win64
[ ] Tested on Mac
[ ] Tested on Linux

This update is not considered required for beta or launch,  but it would be nice to get it in when we can.

Superseded by #946


Sdl update fix

03c2ce46c260852a60731b2311ca1d668760f3a3 appears to have been an incomplete update of SDL 2.0.5 and it broke the build on OS X.

Thanks for this. Thought I had got it tested on mac, but maybe there were merge shenanigans that cause me to mis-test on this end. I'll get this checked out.

I didn't notice right away after I updated because I had it set to only rebuild the application binary for my project in my IDE, instead of on ALL_BUILD, and it kept happily linking to the old version, so I wouldn't be surprised if something similar was going on for you and others.


user tweets pagination question

is there any way to only get the last page of user tweets aka the latest tweets from the user

A "page" isn't defined in Twitter, but they do have default "windows" (or whatever web-devs would call it) of 20-100 entries returned per request. So you'll have to specify a number.
So you would do something like:
scraper.tweets([123456], limit=20, count=20)

Which would more closely mimic the behavior of the requests made in the web interface.


json 3.6 branch (was 3.5)

fixes #876

queued:
https://scala-ci.typesafe.com/view/scala-2.12.x/job/scala-2.12.x-integrate-community-build/4226/

queued:
https://scala-ci.typesafe.com/view/scala-2.12.x/job/scala-2.12.x-integrate-community-build/4235/

https://scala-ci.typesafe.com/view/scala-2.12.x/job/scala-2.12.x-integrate-community-build/4242/


[Enhancement] Enhance validation for create connector API

Description
This PR addresses the first part of this enhancement "Validate if connector payload has all the required fields. If not provided, throw the illegal argument exception". Validation of field credentials is added in this fix. All other validations already exist. Added new test cases corresponding to this validation, fixed all failing test cases because of this new validation and refactored some of the test case code.
Related Issues
Partially Resolves #1382
Check List

[x] New functionality includes testing.
[x] New functionality has been documented.
[x] API changes companion pull request created.
[x] Commits are signed per the DCO using --signoff.
~- [ ] Public documentation issue/PR created.~

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

LGTM, thanks for adding the null or empty checks for credentials!
Just a following up thoughts, if we can check if the credentials is valid in the create API, that would be even better as a further enhancement coming next. Then we can help user ensure the credentials work before calling the model.

LGTM, thanks for adding the null or empty checks for credentials!
Just a following up thoughts, if we can check if the credentials is valid in the create API, that would be even better as a further enhancement coming next. Then we can help user ensure the credentials work before calling the model.

Ok, copied this to bug #2993 to include in the upcoming enhancement.


arrayLink assn

for "Homework: Arrays-Links exercise"
implemented indexOf, add, set methods in /java/dev/codewithfriends/ArrayWrapper.java
tests works before putting in main repo

Thanks for the contributions to ArrayWrapper. Your PR appears to have picked up a few unrelated changes.
The geyser eruption times for Old Faithful got committed as a CSV. This is a great dataset, and there was an livestream talk on using it for k-means clustering in the MLH Career Week hackathon. I think we can move it one directory up here so that it can be shared by multiple projects:
https://github.com/TheEvergreenStateCollege/upper-division-cs/tree/main/dsa-23au/datasets
You've reverted some changes in ArrayWrapperTest, which is following a test factory pattern that lets one test for a List interface be run against both ArrayWrapper and LinkedListWrapper. Please have a look at LinkedListWrapperTest in the same project to see what I mean.
https://github.com/TheEvergreenStateCollege/upper-division-cs/blob/main/dsa-23au/java-dsa/arrays-links/src/test/java/dev/codewithfriends/LinkedListWrapperTest.java
New test methods for both ArrayWrapper and LinkedListWrapper, for the set method you added for example, should be added here:
https://github.com/TheEvergreenStateCollege/upper-division-cs/blob/main/dsa-23au/java-dsa/arrays-links/src/test/java/dev/codewithfriends/ListWrapperFactory.java
If it's easier to separate out the changes, you can start a fresh branch from the latest main and copy over just your relevant changes to ArrayWrapper's .add, .indexOf, and .set methods, and then commit and merge in a new PR.

@Lucretian @JonahEadieEvergreen @Zachsrob @EvergreenTor @DawsonWhi consider submitting your work on canvas and exchanging code reviews with @exoriparian to get full credit for this Assignment 1.
https://canvas.evergreen.edu/courses/5926/assignments/109041
If you do, please fork from the latest main and copy the array-links files into your own personal Maven project, to avoid merge conflicts.


Add dev account support to ecr token refresher

Adding support for dev account to ecr-token-refresher for E2E test

/lgtm
/approve


No module named 'binascii

Bug description
Traceback (most recent call last):
  File "train/train_vqgan.py", line 7, in <module>
    import pytorch_lightning as pl
  File "/home/zhmg/miniconda3/envs/medicaldiffusion/lib/python3.8/site-packages/pytorch_lightning/__init__.py", line 6, in <module>
    from lightning_utilities import module_available
  File "/home/zhmg/miniconda3/envs/medicaldiffusion/lib/python3.8/site-packages/lightning_utilities/__init__.py", line 6, in <module>
    from lightning_utilities.core.apply_func import apply_to_collection
  File "/home/zhmg/miniconda3/envs/medicaldiffusion/lib/python3.8/site-packages/lightning_utilities/core/__init__.py", line 4, in <module>
    from lightning_utilities.core.imports import compare_version, module_available
  File "/home/zhmg/miniconda3/envs/medicaldiffusion/lib/python3.8/site-packages/lightning_utilities/core/imports.py", line 13, in <module>
    import pkg_resources
  File "/home/zhmg/miniconda3/envs/medicaldiffusion/lib/python3.8/site-packages/pkg_resources/__init__.py", line 26, in <module>
    import zipfile
  File "/usr/lib/python3.8/zipfile.py", line 6, in <module>
    import binascii
ModuleNotFoundError: No module named 'binascii

What version are you seeing the problem on?
v2.0
How to reproduce the bug
No response
Error messages and logs
# Error messages and logs here please

Environment

Current environment
#- Lightning Component (e.g. Trainer, LightningModule, LightningApp, LightningWork, LightningFlow):
#- PyTorch Lightning Version (e.g., 1.5.0):
#- Lightning App Version (e.g., 0.5.2):
#- PyTorch Version (e.g., 2.0):
#- Python version (e.g., 3.9):
#- OS (e.g., Linux):
#- CUDA/cuDNN version:
#- GPU models and configuration:
#- How you installed Lightning(`conda`, `pip`, source):
#- Running environment of LightningApp (e.g. local, cloud):

More info
No response

@kanydao Could you please share the environment as instructed by the bug report instructions?
wget https://raw.githubusercontent.com/Lightning-AI/lightning/master/requirements/collect_env_details.py
python collect_env_details.py

For this problem it is essential, otherwise we won't be able to help you.

I think one thing you can try is to update the setuptools package.
https://bugs.python.org/issue46579

I think one thing you can try is to update the setuptools package. https://bugs.python.org/issue46579

Thank you very much, after I deleted the environment and reinstalled python, the problem was solved.


feat(DEV-11277): add new Montie Iframe App

This PR introduces a new Monite Iframe App and enhances existing functionality:
Key Features

Iframe App Elements: Implement core components for the Iframe application.
SDKDemoAPIProvider: Introduce a new provider component and integrate Qraft in SDKDemo for improved state management.
Drop-In Components:

Add support for the disabled property, allowing deferred component loading. This enables programmatic changes to attributes like basename or entity-id before the component renders.
Optimize bundle size for improved performance.

Additional Improvements

Update documentation to reflect new features and integration processes.
Refactor and optimize existing code.

Make note that "Sync PR with GitLab" is failing because the GitLab branch contains specific changes and the sync tool will not overwrite them.


an Issue from exporting Blockchain Testing into webgl

Hello,
I am using my unity editor version  2020.3.24
I imported latest version 0.6.2 and 0.6.0 into my unity package at a different time to export Blockchain Testing into webgl.
I did "check Allow 'unsafe' code" and  "turn on Lock Input to Game View in Options"
errors from 0.6.0

errors from 0.6.2

Please help me..

Resolved on Discord. Looks like the issue was trying to make a WebGL build, which isn't supported


Render Problems, Need some Help

I tried rendering a green screen of a car for a project, I made sure I only selected the car I wanted to mask out on the right framerate. But, then it ended up looking like this after I rendered it:
https://github.com/user-attachments/assets/44bd8818-cefe-4cf6-94ed-c089bb16b423
Is there any way to fix this?

Would you be able to provide the source clip that you used?

Sure
https://github.com/user-attachments/assets/d8fa7d7d-a434-4034-bfdc-abdc05891625

So, I believe the only way this should be able to happen is if you did not propagate the mask across some of the frames at the beginning (even if the car you want to mask does not appear). If the mask was not propagated to every frame, it SHOULD display a warning when you open the export dialog, but maybe it didn't give you a warning for some reason.
But anyways, just try propagating backward from your first visible mask and see if that fixes it. If you open up the workspace, the 'images' and 'masks' folders should both contain the same number of images.


KAFKA-9960: implement KIP-606 to add metadata context to MetricsReporter

Implement KIP-606, add metadata context to MetricsReporter:

Added a new api to MetricsReporter to allow client to expose additional metadata fields to reporter plugin. Added an interface MetricsContext to encapsulate metadata.
Deprecated JmexReporter(String prefix) constructor. The prefix will be passed to the reporter via MetricsContext.
Replaced existing usage of JmxReporter with the default ImxReporter and pass JMX prefix to MetricsContext using _namespace as key.
From Kafka broker, populate MetricsContext with: kafka.cluster.id and kafka.nroker.id
From Connect, populate MetricsContext with: connect.kafka.cluster.id, connect.group.id

Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

@xvrl  @rhauch @ijuma  Could you review this PR for KIP-606. Thanks,

ok to test

Since MetricsReporter instances are the ultimate consumers of the MetadataContext instance I would like to propose moving construction MetricsContext there. This would allow each reporter to manage its own set of labels increasing encapsulation and extensibility.

ok to test

@xiaodongdu please address the conflicts.

ok to test

retest this please

ok to test

ok to test

retest this please

ok to test

retest this please

retest this please

ok to test

retest this please

ok to test

retest this please

retest this please

retest this please

ok to test

retest this please

One seemingly unrelated failure on JDK11 with a known flaky test:
kafka.api.PlaintextProducerSendTest.testNonBlockingProducer
    java.util.concurrent.TimeoutException: Timeout after waiting for 10000 ms.


ot scraper is broken

lsdviztools version:docker container
Python version: 3.8
Operating System: macos

Description
using the ot scraper to download SRTM data from open topography is broken, I have included my API key but it still throws a 401 error.
What I Did
SB_DEM = bmt.ot_scraper(source = "SRTM30",longitude_W = -123.225226, longitude_E = -122.954536, latitude_S = 38.941020, latitude_N = 39.272342,prefix = "maacama", api_key=' ') #I removed my key here and down below too.
SB_DEM.print_parameters()
SB_DEM.download_pythonic()

---------------------------------------------------------------------------
HTTPError                                 Traceback (most recent call last)
/tmp/ipykernel_70/2381537486.py in <module>
      3 SB_DEM = bmt.ot_scraper(source = "SRTM30",longitude_W = -123.225226, longitude_E = -122.954536, latitude_S = 38.941020, latitude_N = 39.272342,prefix = "maacama", api_key=' ')
      4 SB_DEM.print_parameters()
----> 5 SB_DEM.download_pythonic()

/usr/local/lib/python3.8/site-packages/lsdviztools/lsdbasemaptools/lsdmap_otgrabber.py in download_pythonic(self)
    155
    156         # Download the file from `url` and save it locally under `file_name`:
--> 157         with urllib.request.urlopen(url_string) as response, open(filename, 'wb') as out_file:
    158             shutil.copyfileobj(response, out_file)
    159

/usr/local/lib/python3.8/urllib/request.py in urlopen(url, data, timeout, cafile, capath, cadefault, context)
    220     else:
    221         opener = _opener
--> 222     return opener.open(url, data, timeout)
    223
    224 def install_opener(opener):

/usr/local/lib/python3.8/urllib/request.py in open(self, fullurl, data, timeout)
    529         for processor in self.process_response.get(protocol, []):
    530             meth = getattr(processor, meth_name)
--> 531             response = meth(req, response)
    532
    533         return response

/usr/local/lib/python3.8/urllib/request.py in http_response(self, request, response)
    638         # request was successfully received, understood, and accepted.
    639         if not (200 <= code < 300):
--> 640             response = self.parent.error(
    641                 'http', request, response, code, msg, hdrs)
    642

/usr/local/lib/python3.8/urllib/request.py in error(self, proto, *args)
    567         if http_err:
    568             args = (dict, 'default', 'http_error_default') + orig_args
--> 569             return self._call_chain(*args)
    570
    571 # XXX probably also want an abstract factory that knows when it makes

/usr/local/lib/python3.8/urllib/request.py in _call_chain(self, chain, kind, meth_name, *args)
    500         for handler in handlers:
    501             func = getattr(handler, meth_name)
--> 502             result = func(*args)
    503             if result is not None:
    504                 return result

/usr/local/lib/python3.8/urllib/request.py in http_error_default(self, req, fp, code, msg, hdrs)
    647 class HTTPDefaultErrorHandler(BaseHandler):
    648     def http_error_default(self, req, fp, code, msg, hdrs):
--> 649         raise HTTPError(req.full_url, code, msg, hdrs, fp)
    650
    651 class HTTPRedirectHandler(BaseHandler):

HTTPError: HTTP Error 401: 401

Hi Ben, I'm updating the container and lsdviztools to make sure this works but it might take a day or two.

I have now updated lsdviztools as well as the lsdtt_pytools_docker container.
Warning: the new container required a different base image so you will have to pull an entirely new container. You may wish to do this overnight!
The updated version uses a file rather than entering the API key directly. Here is an example:
# YOU NEED TO PUT YOUR API KEY IN A FILE
your_OT_api_key_file = "my_OT_api_key.txt"

with open(your_OT_api_key_file, 'r') as file:
    print("I am reading you OT API key from the file "+your_OT_api_key_file)
    api_key = file.read().rstrip()
    print("Your api key starts with: "+api_key[0:4])

Dataset_prefix = "Xian"
source_name = "COP30"

Xian_DEM = bmt.ot_scraper(source = source_name,
                        lower_left_coordinates = [33.672715066202954,<PHONE_NUMBER>3333152],
                        upper_right_coordinates = [34.16323953210814,<PHONE_NUMBER>228437],
                        prefix = Dataset_prefix,
                        api_key_file = your_OT_api_key_file)

If you do not want to pull the new image you can still access the updated OT scraper by updating lsdviztools to version 0.4.8.


Create a "Lost at Sea" game module

Currently, this is the only game in the platform. We should consider splitting up the variations as tasks. From the tech doc:

It would be nice that once the module is created, it loops over all the items (in a randomized order) (6) + 8) to be discussed which way we can devise to organize module repetitions and loops)

Make the automation of experiment creation easier.
Make it possible to create a set of items that will be used (and a button to do random assignment, and ordering).

Current scope of this is to enable one-click creation of Lost at Sea stages (i.e., randomly generate item pairs and use to populate surveys and chat as they are created).
We can open up a follow-up FR to enable customization (e.g., specifying number of pairs, allowing re-randomization) - this requires more effort because it involves updating multiple stages, and we don't currently have a bit to track what module a stage is part of.