Development issueshttps://lab.civicrm.org/groups/dev/-/issues2024-03-21T05:03:28Zhttps://lab.civicrm.org/dev/core/-/issues/3449Afform: checkboxes should have default false value2024-03-21T05:03:28ZRichAfform: checkboxes should have default false valueOverview
----------------------------------------
If you have a checkbox used, for example, for "is_test" on a contribution search table but without explictly configuring a default value, the UI shows an un-checked checkbox, which *shou...Overview
----------------------------------------
If you have a checkbox used, for example, for "is_test" on a contribution search table but without explictly configuring a default value, the UI shows an un-checked checkbox, which *should* be the visual representation of "is_test = 0" but is actually representing *no filter on is_test*.
After operating the checkbox the UI and the meaning are in-sync.
While this can be solved by the form builder designer setting an explicit default value, there is no logical sense to *not* having a default value when the form element is binary.
Current behaviour
----------------------------------------
If person who built the form forgets / does not know to include a default value on a checkbox, the UI is initially broken, results are misleading.
Proposed behaviour
----------------------------------------
A checkbox should insist on a default value, defaulting to false, so that the UI and the meaning of the filter are always in sync.
Comments
----------------------------------------
https://chat.civicrm.org/civicrm/pl/9613mtpi6j8ypxf879p7eyyz5ahttps://lab.civicrm.org/dev/core/-/issues/2941Follow-up task - Remove the CiviCRM Connections functionality from CiviCRM co...2024-03-21T05:03:26Zjustinfreeman (Agileware)Follow-up task - Remove the CiviCRM Connections functionality from CiviCRM core (Task 2 of 2) - Remove the codeThis is a follow-up task to https://lab.civicrm.org/dev/core/-/issues/2910 - which was changed to only remove the menu item from the menu as an intermediary step.
To complete this work, this task will remove the CiviCRM Connections func...This is a follow-up task to https://lab.civicrm.org/dev/core/-/issues/2910 - which was changed to only remove the menu item from the menu as an intermediary step.
To complete this work, this task will remove the CiviCRM Connections functionality from CiviCRM core. This concept was already approved on https://lab.civicrm.org/dev/core/-/issues/2910
Agileware Ref: CIVIBLD-286https://lab.civicrm.org/dev/core/-/issues/4154Number field input validation does not respect decimal separator setting2024-03-20T10:36:25ZnoahNumber field input validation does not respect decimal separator settingOverview
----------------------------------------
This issue has to do with "number" (float) custom fields on some edit forms. When you enter a number containing any character other than a digit or a period (full stop) into such a field,...Overview
----------------------------------------
This issue has to do with "number" (float) custom fields on some edit forms. When you enter a number containing any character other than a digit or a period (full stop) into such a field, validation fails. This happens even if the offending character has been set as the decimal separator in Civi's localization settings.
Reproduction steps
----------------------------------------
1. Under Administer > Localization > Languages, Currency, Locations, set "Decimal Delimiter" to "," (comma).
1. Create a custom field extending Activities. Data type: Number.
1. Add a new activity. In the number field, enter a number that includes a comma, such as "123,45" (one hundred twenty three and forty-five one-hundredths).
1. Press Save.
Current behaviour
----------------------------------------
Validation fails with the error message "[Custom Field Label] must be a number (with or without decimal point)."
Expected behaviour
----------------------------------------
The form should save the entered amount as (float) one hundred twenty three and forty-five one-hundredths.
Environment information
----------------------------------------
CiviCRM 5.60 (current master HEAD).
Comments
----------------------------------------
Somewhat entangled with #41525.68.0https://lab.civicrm.org/dev/core/-/issues/3773Deprecated function: Required parameter $sortCriteria follows optional parame...2024-03-20T05:03:26ZTobias KrauseDeprecated function: Required parameter $sortCriteria follows optional parameter $countEverytime cron runs I see this message in logs:
`Deprecated function: Required parameter $sortCriteria follows optional parameter $count in include() (line571 in /var/www/civi_live/vendor/composer/ClassLoader.php)`
After searching a li...Everytime cron runs I see this message in logs:
`Deprecated function: Required parameter $sortCriteria follows optional parameter $count in include() (line571 in /var/www/civi_live/vendor/composer/ClassLoader.php)`
After searching a little bit the only place which makes sense for this message is ezcMailImapTransport->sortFromOffset() in vendor/zetacomponents/mail/src/transports/imap/imap_transport.php
My setup:
- drupal 9.3.19
- CiviCRM 5.51.1
- PHP 8.0
I don't knowwhere this dependency comes from but this library needs an update for PHP 8.0 - or it should be considered to use another dependency. For IMAP handling I have good experiences with https://github.com/ddeboer/imaphttps://lab.civicrm.org/dev/core/-/issues/3770Figure out how to offer preferredLanguage in api explorer with options2024-03-20T05:03:26ZeileenFigure out how to offer preferredLanguage in api explorer with optionsFrom discussion of adding preferredLanguage - options should be explorer-discoverable
https://github.com/civicrm/civicrm-core/pull/24116#pullrequestreview-1057986655From discussion of adding preferredLanguage - options should be explorer-discoverable
https://github.com/civicrm/civicrm-core/pull/24116#pullrequestreview-1057986655https://lab.civicrm.org/dev/core/-/issues/5101Search Builder: Contact not in Tag don't takes contacts without tags into acc...2024-03-19T20:35:27ZglanzelSearch Builder: Contact not in Tag don't takes contacts without tags into accountOverview
----------------------------------------
In Search Generator When searching for not in Tag(s) it don't takes contacts without tags into account.
Reproduction steps
----------------------------------------
Click Search -> Sear...Overview
----------------------------------------
In Search Generator When searching for not in Tag(s) it don't takes contacts without tags into account.
Reproduction steps
----------------------------------------
Click Search -> Search Builder
and there choose
Contact -> Tags -> not in -> TagX.
as Search parameter.
Current behaviour
----------------------------------------
Only Persons with minimum one Tag but without TagX gets displayed.
Expected behaviour
----------------------------------------
Any Contact with Tags other than TagX **and** all Contacts without any Tag should be displayed.
Environment information
----------------------------------------
* CiviCRM:CiviCRM 5.73.alpha1
Comments
----------------------------------------https://lab.civicrm.org/dev/core/-/issues/5077civicrm.css loaded on front end when frontend theme set to 'None - Unstyled'2024-03-19T07:32:11ZMichael McAndrewcivicrm.css loaded on front end when frontend theme set to 'None - Unstyled'Wondering if I have found a bug or am just misunderstanding/mistaken or I have missed a decision to change things but I have reproduced this on 5.70 and 5.71. It was not happening in 5.64.4
Steps to reproduce:
1. Clean CiviCRM on WordP...Wondering if I have found a bug or am just misunderstanding/mistaken or I have missed a decision to change things but I have reproduced this on 5.70 and 5.71. It was not happening in 5.64.4
Steps to reproduce:
1. Clean CiviCRM on WordPress install
2. Set front end theme to **automatic**
3. Go to a front end page, e.g. /civicrm/mailing/subscribe
4. Notice that /wp-content/plugins/civicrm/civicrm/css/civicrm.css has been loaded - **good!**
5. Set front end theme **none - unstyled**
6. Go to a front end page, e.g. /civicrm/mailing/subscribe
7. Notice that /wp-content/plugins/civicrm/civicrm/css/civicrm.css has been loaded **- bad!**https://lab.civicrm.org/dev/core/-/issues/3757Users with administer_reports should be able to delete dashlets from the dash...2024-03-19T05:03:27ZandyburnsUsers with administer_reports should be able to delete dashlets from the dashboardThe current behavior I see is anyone with `administer_reports` can access the "Access" tab in a given report in CiviReport. Therefore, they can create dashlets. However, upon making a dashlet available for the dashboard, these can not be...The current behavior I see is anyone with `administer_reports` can access the "Access" tab in a given report in CiviReport. Therefore, they can create dashlets. However, upon making a dashlet available for the dashboard, these can not be removed by that same user, potentially resulting in a cluttered dashboard and user frustration.
Non-admins are missing trash can delete function:
![image](/uploads/206f154220c69227a784cc2d40e87a39/image.png)
Admin sees trash can:
![image](/uploads/21dbc1ca9cc3247a4752324df98a68b2/image.png)
Sure, interest in civireport is quite low now but this same behavior affects dashlets created from search kit.
For search kit, I would set that `administer data` or maybe `administer_reports` would be the needed permission to remove dashlets. Currently, it is not enough.https://lab.civicrm.org/dev/core/-/issues/4052Problem with custom group fields when cache get returns NULL from 'CRM_Core_D...2024-03-18T23:41:32ZLeanderJCCProblem with custom group fields when cache get returns NULL from 'CRM_Core_DAO_CustomGroup_QueryMultipleFields *' cache keyOverview
----------------------------------------
We had a problem where we did an APIv3 call on participants where it would cause an error resulting in a 500 response.
Some stack tracing showed us that in CRM/Core/BAO/CustomGroup.php t...Overview
----------------------------------------
We had a problem where we did an APIv3 call on participants where it would cause an error resulting in a 500 response.
Some stack tracing showed us that in CRM/Core/BAO/CustomGroup.php the code `$multipleFieldGroups = $cache->get($multipleFieldGroupCacheKey);` returned NULL (line 576). Since there is no check that says that it should not be NULL the code continues and errors on `if (in_array($table, $multipleFieldGroups) &&` because
> Argument #2 ($haystack) must be of type array, null given in in_array().
Reproduction steps
----------------------------------------
Could not specifically reproduce this with a clean install.
Current behaviour
----------------------------------------
Our page where the APIv3 Participant call was made would return a 500.
```
TypeError: in_array(): Argument #2 ($haystack) must be of type array, null given in in_array() (line 611 of /var/www/html/vendor/civicrm/civicrm-core/CRM/Core/BAO/CustomGroup.php)
#0 /var/www/html/vendor/civicrm/civicrm-core/CRM/Core/BAO/CustomGroup.php(611): in_array('civicrm_value_r...', NULL)
#1 /var/www/html/vendor/civicrm/civicrm-core/api/v3/utils.php(1449): CRM_Core_BAO_CustomGroup::getTree('Participant', Array, 1982, NULL, Array, NULL, true, NULL, true, false)
#2 /var/www/html/vendor/civicrm/civicrm-core/api/v3/Participant.php(154): _civicrm_api3_custom_data_get(Array, NULL, 'Participant', '1982', NULL)
#3 /var/www/html/vendor/civicrm/civicrm-core/Civi/API/Provider/MagicFunctionProvider.php(89): civicrm_api3_participant_get(Array)
#4 /var/www/html/vendor/civicrm/civicrm-core/Civi/API/Kernel.php(149): Civi\API\Provider\MagicFunctionProvider->invoke(Array)
#5 /var/www/html/vendor/civicrm/civicrm-core/Civi/API/Kernel.php(81): Civi\API\Kernel->runRequest(Array)
#6 /var/www/html/vendor/civicrm/civicrm-core/api/api.php(133): Civi\API\Kernel->runSafe('Participant', 'get', Array)
```
Expected behaviour
----------------------------------------
The page should load as normal.
Environment information
----------------------------------------
* __CiviCRM:__ _5.55.1_
* __PHP:__ _8.0.24_
* __CMS:__ _Drupal 9.4.8_
* __Database:__ _8.0.26_
* __Web Server:__ _nginx/1.20.2_
Comments
----------------------------------------
We fixed this issue by switching to APIv4 so it would no longer automatically get the custom groups and fields for the participant, but this still seemed a general issue to report.
I believe an if, at line 578 after settings the variable, would fix this issue.
```
if ($multipleFieldGroups === NULL) {
$multipleFieldGroups = [];
}
```https://lab.civicrm.org/dev/core/-/issues/5090Display of autocomplete multi-select custom fields for events is broken2024-03-18T23:14:49ZDetlev SieberDisplay of autocomplete multi-select custom fields for events is broken## Overview
For events, the display of autocomplete multi-select fields does not work anymore.
## Reproduction steps
1. Create a custom field for events:
1. Data Type Alphanumeric
2. Field Input Type: autocomplete
3. Multi-Se...## Overview
For events, the display of autocomplete multi-select fields does not work anymore.
## Reproduction steps
1. Create a custom field for events:
1. Data Type Alphanumeric
2. Field Input Type: autocomplete
3. Multi-Select: check
4. Add two options (e.g. "value1", "value2")
2. Edit an event, select "value1", Save.
3. Open the event again: the selected value(s) are not displayed (however, they are stored in the database).
## Current behaviour
Stored values of autocomplete multi-select fields for events are not displayed.
(This might create problems, because when you save, then the existing values are overwritten/nulled)
## Expected behaviour
Stored values of autocomplete multi-select fields for events should be displayed.
## Environment information
* This worked well with CiviCRM 5.64.4, but since some time it is broken.
* Tested here with 5.71.1
## Workaround
* Field input type can be changed to "checkbox(es)" - which however might be ugly and un-usable if there are many option.5.71.2https://lab.civicrm.org/dev/core/-/issues/4969Angular manager module caching issue (TypeError in_array)2024-03-18T21:46:01ZJKingsnorthAngular manager module caching issue (TypeError in_array)Related question was raised here: https://civicrm.stackexchange.com/questions/46379/typeerror-in-array-angular-managerresolvedefaultmodules-civicrm-version-5
I think this is a recent change which might have caused the issues (or highlig...Related question was raised here: https://civicrm.stackexchange.com/questions/46379/typeerror-in-array-angular-managerresolvedefaultmodules-civicrm-version-5
I think this is a recent change which might have caused the issues (or highlighted them): https://github.com/civicrm/civicrm-core/commit/604cca726c6a238e0530b5f660ab0e11596da090#diff-b26b657986ef8b8163e79bcaf85afe628f6d5457193253bc6ff4c009cca44bf5
---
We're seeing an intermittent issue where pages fail to load with a fatal error. The only path we've detected it on is /civicrm/transact .
It's caused by `\Civi\Angular\Manager::resolveDefaultModules` looking for the 'basePages' array for a module definition, but it's not there. After some checking, it looks like the value is just null (ie, there's no definition set).
Digging back through \Civi\Angular\Manager::getModules we can see that this checks to see if `$this->cache->get('moduleNames');` is null. If it is, it rebuilds the list of modules and saves it to the cache, and then goes through each module and saves the definition to the cache - using separate cache key entries (I guess because otherwise the cache entry would be too big?)
```
$angularModules = $this->resolvePatterns($angularModules);
$this->cache->set('moduleNames', array_keys($angularModules));
foreach ($angularModules as $moduleName => $moduleInfo) {
$this->cache->set("module $moduleName", $moduleInfo);
}
```
If `moduleNames` is already set, then it rehydrates the data from the cache:
```
// Rehydrate modules from cache
else {
foreach ($moduleNames as $moduleName) {
$angularModules[$moduleName] = $this->cache->get("module $moduleName");
}
```
The problem I think we're seeing intermittently is that `$this->cache->get('moduleNames');` is set but the individual module definitions (or some of them at least) are not set `$this->cache->get("module $moduleName");` . This means the value is set as 'NULL', which is causing the original error.
I'm struggling to find the exact steps to recreate this issue, but I think the related code could do with tightening up in either case?
It doesn't look like we can rely on the 'module ...' cache entries being set if the 'moduleNames' entry is set?
Ping @colemanwhttps://lab.civicrm.org/dev/core/-/issues/5085Incorrect fee level saved when editing event participant2024-03-18T19:23:47Zchrisgaraffachris@aghstrategies.comIncorrect fee level saved when editing event participantOverview
----------------------------------------
Editing an event participant changes the fee level and amount listed, seemingly at random.
Reproduction steps
----------------------------------------
- Register a contact for an event ...Overview
----------------------------------------
Editing an event participant changes the fee level and amount listed, seemingly at random.
Reproduction steps
----------------------------------------
- Register a contact for an event that uses a price set for fees (I'm using Summer Solstice Day Concert from dmaster in this example). Doesn't matter if they register online or an admin adds their registration
- Select Bass - $ 25.00
- Save the event registration
- Edit the event registration
- Change nothing
- Click Save
Current behaviour
----------------------------------------
The Fee level on the participant changes to something else - the specific value seems random on the first save, then doesn't seem to change.
Settings for adding the event registration:
![image](/uploads/04829e0ca7f423daf94a29b56883da07/image.png)
Display after creating the registration:
![image](/uploads/028cb9da80776075397f2df2541ee7a5/image.png)
Display after editing the registration, changing nothing, and saving:
![image](/uploads/5e63e0f24e9de983944a6c0e5873e577/image.png)
Expected behaviour
----------------------------------------
The fee level shouldn't change
Environment information
----------------------------------------
* __CiviCRM:__ Reproduced on 5.70.2, 5.71.0, dmaster (5.73.alpha1)https://lab.civicrm.org/dev/core/-/issues/2126Special characters become "?" On PDF report2024-03-18T05:03:27ZJeannSpecial characters become "?" On PDF reportOverview
----------------------------------------
There's an issue when exporting special characters to PDF format on civicrm report. All special characters turn into "?".
```
This problem can be replicated on https://dmaster.demo.civic...Overview
----------------------------------------
There's an issue when exporting special characters to PDF format on civicrm report. All special characters turn into "?".
```
This problem can be replicated on https://dmaster.demo.civicrm.org.
```
After discussing the problem on do-ocracy 2020 channel, we found out that dejavu fonts were removed on dompdf fonts folder to save about 12mb for civicrm. Thus, this issue emerged.
Comments
----------------------------------------
_Anything else you would like the reviewer to note._https://lab.civicrm.org/dev/core/-/issues/3694Get offline contribution-receipt fully working with preview screen2024-03-18T05:03:27ZeileenGet offline contribution-receipt fully working with preview screenThere is a long-term goal to get all templates working in the preview screen. This focusses on the backoffice contribution receipt.
Aside from the Usability benefit the process adds test cover and will eventually allow us to remove a si...There is a long-term goal to get all templates working in the preview screen. This focusses on the backoffice contribution receipt.
Aside from the Usability benefit the process adds test cover and will eventually allow us to remove a significant amount of unreliable and hard-to-read code (even the first PR wound up removing some data leakage). It also means the templates can be fired form outside the forms and separates the logic from the forms - which is important for alternate form layers
This involves that all variables in it can be provided by the workflow-template / example combo
- [ ] `$lineItem` -> supported variable -> `$lineItems` https://github.com/civicrm/civicrm-core/pull/23870
- [ ] `$getTaxDetails` - no longer used in default template https://github.com/civicrm/civicrm-core/pull/23870
- [ ] `$dataArray` -> supported variable -> `$taxRateBreakdown` https://github.com/civicrm/civicrm-core/pull/23870
- [ ] Amount before Tax - add a new token for this & use that - it is `{contribution.total_amount}` - `{contribution.tax_amount}` & can be added at apiv4 level - similar to https://github.com/civicrm/civicrm-core/pull/23802
- [ ] `$ccContribution`, `$formValues.hidden_CreditCard` - probably of marginal value - check the specific values instead before displaying or not
- [ ] `$billingName`, `$address` - add billing tokens - builds on https://github.com/civicrm/civicrm-core/pull/23845
- [ ] `$credit_card_type`, `$credit_card_number`, `$credit_card_exp_date` - potentially Payment tokens?
- [ ] `$customGroup` - propose removal https://lab.civicrm.org/dev/core/-/issues/3693
- [ ] `$softCreditTypes` `$softCredits` - fix is similar to line items - keep but rationalise & handle in WorkFlow Template
- [ ] `$formValues.product_name`, `$formValues.product_name`, `$formValues.product_option`, `$formValues.product_sku` `$fulfilled_date` - fix is similar to line items - keep but rationalise & handle in WorkFlow Template
Note `$formValues.receipt_text` REALLY IS tied to the form - as it is not stored in the DB - so that is an appropriate use of formValues.https://lab.civicrm.org/dev/core/-/issues/5005Error Saving Custom Field Group with Event Name that's disabled2024-03-17T21:17:39ZsavionleeError Saving Custom Field Group with Event Name that's disabledOverview
----------------------------------------
After disabling an event, an error is raised when trying to reuse a custom field group for a new event. It returns a message
```Supplied Sub type is not valid for the specified entity``...Overview
----------------------------------------
After disabling an event, an error is raised when trying to reuse a custom field group for a new event. It returns a message
```Supplied Sub type is not valid for the specified entity```
When trying to save on Civi 5.70 in Wordpress, this box was raised:
![image](/uploads/7ac617b95a1872ae6753b12c69c449fd/image.png)
The error message is presented after clicking through it in the pop up civi alerts.
Reproduction steps
----------------------------------------
1. Create *Event 1* copy it to *Event 1 Copy*
1. Create a Custom Field Set attach **Participant -> Partipants (Event Name)** Pick Event 1
1. Disable *Event 1*
1. Go back and add *Event 1 Copy* to Custom Field Set
1. Got an error "**message: Supplied Sub type is not valid for the specified entity**".
Current behaviour
----------------------------------------
_What happens currently. Please provide error messages, screenshots or gifs ([LICEcap](http://www.cockos.com/licecap/), [SilentCast](https://github.com/colinkeenan/silentcast)) where appropriate._
```
***ERROR***
message: Supplied Sub type is not valid for the specified entity
code:
exception: CRM_Core_Exception Object
(
[message:protected] => Supplied Sub type is not valid for the specified entity
[string:Exception:private] =>
[code:protected] => 0
[file:protected] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/api/api.php
[line:protected] => 138
[trace:Exception:private] => Array
(
[0] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Custom/Form/Group.php
[line] => 293
[function] => civicrm_api3
)
[1] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php
[line] => 641
[function] => postProcess
[class] => CRM_Custom_Form_Group
[type] => ->
)
[2] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/StateMachine.php
[line] => 144
[function] => mainProcess
[class] => CRM_Core_Form
[type] => ->
)
[3] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Next.php
[line] => 43
[function] => perform
[class] => CRM_Core_StateMachine
[type] => ->
)
[4] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php
[line] => 203
[function] => perform
[class] => CRM_Core_QuickForm_Action_Next
[type] => ->
)
[5] => Array
(
...
```
Expected behaviour
----------------------------------------
_What should happen._
I should be able to add a new event to the custom field group even though the old event is disabled.
Environment information
----------------------------------------
<!-- Some of the items below may not be relevant for every bug - if in doubt please include more information than you think is neccessary. -->
* __Browser:__ _Firefox 122.0.1_
* __CiviCRM:__ _5.70.0/5.72.0..._ <!-- If this problem relates to an upgrade, then specify both old and new versions -->
* __PHP:__ _8.1.1__
* __CMS:__ _Wordpress 6.4.3_
* __Database:__ _MariaDB..._
* __Web Server:__ _Apache..._
Comments
----------------------------------------
_Anything else you would like the reviewer to note._https://lab.civicrm.org/dev/core/-/issues/3751Export fails for contact reference of type multi-select2024-03-17T09:15:14ZKurund JalmiExport fails for contact reference of type multi-selectFor a multi-select custom field when multiple contacts are selected with long names then the export fails.
This happens because temp export table is created with a varchar 255 column. I feel it should be changed to type `text`.For a multi-select custom field when multiple contacts are selected with long names then the export fails.
This happens because temp export table is created with a varchar 255 column. I feel it should be changed to type `text`.https://lab.civicrm.org/dev/core/-/issues/5097Can't set Outbound Mail to use SMTP without a fatal error2024-03-17T08:26:35ZUpperholmeCan't set Outbound Mail to use SMTP without a fatal errorUsing CiviCRM 5.70.1 I want to set up Outbound Mail to send via SMTP. I provide the relevant details and login credentials via the form that would let me send via the mail account that I've set up expressly for this purpose. On testing -...Using CiviCRM 5.70.1 I want to set up Outbound Mail to send via SMTP. I provide the relevant details and login credentials via the form that would let me send via the mail account that I've set up expressly for this purpose. On testing - using the 'Save and send a test' functionality I would expect to see a positive response, along with an email, or an on-screen error message to indicate that the details entered were in some way inaccurate.
However all I get is a fatal error. The log reports this as:
```
Got error 'PHP message: PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rp/sites/live/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2123
PHP message: PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2123
PHP message: PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2123
PHP message: PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2123
PHP message: PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2123
PHP message: PHP Fatal error: Uncaught Error: Call to undefined function fsockopen() in /wp-content/plugins/civicrm/civicrm/vendor/pear/net_socket/Net/Socket.php:165
```
I tried various settings options, but it didn't matter what I entered into the settings form, I got the same result.
I asked a question about this on StackExchange: https://civicrm.stackexchange.com/questions/47564/what-values-are-required-in-order-to-send-outbound-mail-via-smtp
Seeing that version 5.71 included significant changes to CiviMail, I upgraded my development site and retested. Same result:
```
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2140;
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2140;
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2140;
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2140;
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Smtp::$_id in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2140;
PHP Fatal error: Uncaught Error: Call to undefined function fsockopen() in /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/vendor/pear/net_socket/Net/Socket.php:165
```
Stack trace:
```
#0 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/vendor/pear/net_smtp/Net/SMTP.php(451): Net_Socket->connect()
#1 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/vendor/pear/mail/Mail/smtp.php(449): Net_SMTP->connect()
#2 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/vendor/pear/mail/Mail/smtp.php(332): Mail_smtp->getSMTPObject()
#3 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/vendor/pear/mail/Mail/smtp.php(319): Mail_smtp->send_or_fail()
#4 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Utils/Mail/FilteredPearMailer.php(77): Mail_smtp->send()
#5 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/Admin/Form/Setting/Smtp.php(185): CRM_Utils_Mail_FilteredPearMailer->send()
#6 /home/rpdev/sites/dev/wp-content/plugins/civicrm/civicrm/CRM/...', referer: https://mysite.com/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fsetting%2Fsmtp&_qf_Smtp_display=true
```https://lab.civicrm.org/dev/core/-/issues/3737E_NOTICEs from CRM_Contribute_Task::permissionedTaskTitles() - undefined / nu...2024-03-17T05:03:31ZAdam WoodE_NOTICEs from CRM_Contribute_Task::permissionedTaskTitles() - undefined / null array errorsNot a major issue, but our log file is filling up with messages of the following nature:
```
[Thu Jul 14 13:28:43.516413 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Undefined offset: 8 in /...Not a major issue, but our log file is filling up with messages of the following nature:
```
[Thu Jul 14 13:28:43.516413 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Undefined offset: 8 in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 190, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
[Thu Jul 14 13:28:43.516486 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Trying to access array offset on value of type null in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 190, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
[Thu Jul 14 13:28:43.516486 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Undefined offset: 9 in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 191, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
[Thu Jul 14 13:28:43.516486 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Trying to access array offset on value of type null in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 191, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
[Thu Jul 14 13:28:43.516486 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Undefined offset: 402 in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 190, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
[Thu Jul 14 13:28:43.516486 2022] [fcgid:warn] [pid 52056] [client 92.40.175.17:63990] mod_fcgid: stderr: PHP Notice: Trying to access array offset on value of type null in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Contribute/Task.php on line 192, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/event/search&reset=1&force=1&status=true&event=364
```
(Running CiviCRM 5.50.4)
The issue seems to be that in `CRM_Contribute_Task::permissionedTaskTitles()`, there is a code path where the internal `$_task` array is not initialised by calling the `tasks()` method beforehand.
```php
public static function permissionedTaskTitles($permission, $params = []) {
if (!isset($params['softCreditFiltering'])) {
$params['softCreditFiltering'] = FALSE;
}
if (($permission == CRM_Core_Permission::EDIT)
|| CRM_Core_Permission::check('edit contributions')
) {
$tasks = self::taskTitles();
}
else {
/*** ISSUE IS HERE - NO PRIOR CALL TO self::tasks() OR self::taskTitles() ETC ***/
$tasks = [
self::TASK_EXPORT => self::$_tasks[self::TASK_EXPORT]['title'],
self::TASK_EMAIL => self::$_tasks[self::TASK_EMAIL]['title'],
self::PDF_RECEIPT => self::$_tasks[self::PDF_RECEIPT]['title'],
];
//CRM-4418,
if (CRM_Core_Permission::check('delete in CiviContribute')) {
$tasks[self::TASK_DELETE] = self::$_tasks[self::TASK_DELETE]['title'];
}
}
if ($params['softCreditFiltering']) {
unset($tasks[self::BATCH_UPDATE], $tasks[self::PDF_RECEIPT]);
}
$tasks = parent::corePermissionedTaskTitles($tasks, $permission, $params);
return $tasks;
}
```
Looks like a pretty easy fix (call `self::tasks()`), but I need to do some further digging to be sure of the implications and think about how we would test this. Will have to pick this up again in a couple of weeks, but raising the issue now so it's on file.
If someone else comes in with a fix in the meantime, then great :smile:https://lab.civicrm.org/dev/core/-/issues/3748Form Builder: Exceptions don't bubble up2024-03-16T05:03:27ZJonGoldForm Builder: Exceptions don't bubble upIf you submit a form that causes the underlying CRUD API to return an error, the error isn't recorded anywhere, displayed on screen, etc. You can replicate this by creating a FB form for an individual and submitting it without entering ...If you submit a form that causes the underlying CRUD API to return an error, the error isn't recorded anywhere, displayed on screen, etc. You can replicate this by creating a FB form for an individual and submitting it without entering any values.
The relevant code comment says:
> // What to do here? Sometimes we should silently ignore errors, e.g. an optional entity
intentionally left blank. Other times it's a real error the user should know about.
But a few lines above, we say:
```
if (empty($record['fields'])) {
continue;
}
```
So I'm guessing that comment predates the `if` statement, since blank entities shouldn't get saved. So I think we should always be notifying the user.
In addition to showing a message on screen, I think errors should be saved to the AfformSubmission record, that's a killer feature that would make troubleshooting form submission errors in production much easier than Webform.https://lab.civicrm.org/dev/core/-/issues/3743Form Builder: Load contact summary blocks on Print Summary page2024-03-16T05:03:26ZJonGoldForm Builder: Load contact summary blocks on Print Summary page### Replication Steps
* Create a Search Kit search and corresponding Form Builder form.
* Check the box indicating the FB form should appear as a block on the contact summary.
* Go to a contact and select **Actions menu » Print Summary**...### Replication Steps
* Create a Search Kit search and corresponding Form Builder form.
* Check the box indicating the FB form should appear as a block on the contact summary.
* Go to a contact and select **Actions menu » Print Summary**.
### Expected Result
Print Summary includes the FB block
### Actual Result
Nope.
I have a partial fix - I can load the block, but only if someone cancels the initial `window.print()`. I'm not sure how best to tackle the issue otherwise. I don't know that there's a way to delay the print until all the blocks load - if there is, that's ideal.JonGoldJonGold