# 2024 07 17 release notes (core)

## Release summary

This page summarises items scheduled for the following release to the Patchworks Production environment:

**Patchworks core (backend)**

| Release version | Release date                         |
| --------------- | ------------------------------------ |
| 1.21.5          | 17th July (starting between 8am-9am) |

**Patchworks dashboard (frontend)**

| Release version | Release date                         |
| --------------- | ------------------------------------ |
| 1.15.7          | 17th July (starting between 8am-9am) |

{% hint style="danger" %}
This release includes preparatory information for an upcoming change which affects the behaviour of filters when values are not of the expected data type. Please ensure that you check the [Breaking changes](#breaking-changes) section.
{% endhint %}

New features, updates, and enhancements of note are summarised by product area, below:

* [Process flows](#process-flows)
* [Breaking changes](#breaking-changes)

## Process flows

<table><thead><tr><th width="180">Type<select><option value="edbc33cea7f34e16b3a205c7a65c3172" label="New" color="blue"></option><option value="d8457d8925c74fab90fa132d141b764b" label="Change" color="blue"></option><option value="030babd6286a4fe19214da74af9afb98" label="Enhancement" color="blue"></option><option value="9a29ee576f43448f9b1623baca59c3db" label="Bug" color="blue"></option><option value="L09Gy6z2y7VD" label="Breaking change" color="blue"></option></select></th><th width="426">Summary</th><th>Ref #</th></tr></thead><tbody><tr><td><span data-option="edbc33cea7f34e16b3a205c7a65c3172">New</span></td><td><p><strong>New filter types for 'in' and 'not in' scenarios</strong><br>To handle cases where a filter needs to match incoming data based on one of many given values being present/not present, two new filter types have been implemented: <code>Contains one of many</code> and <code>Does not contain one of many</code>.</p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/Efgn5UQaAgskcrFHwTB0">Using contains one of many or does not contain one of many for string filters</a></p></td><td>CPT-1872</td></tr><tr><td><span data-option="030babd6286a4fe19214da74af9afb98">Enhancement</span></td><td><strong>Shape source endpoint selector</strong><br>In shapes where source instance/endpoint options are available (e.g. connector, flow control, route), the endpoint selector has been enhanced to include a search field, so you can quickly search for the required endpoint by name.</td><td>CPT-2500</td></tr><tr><td><span data-option="d8457d8925c74fab90fa132d141b764b">Change</span></td><td><p><strong>Run process flow shape</strong><br>When selecting a process flow to be initialised from a run process flow shape, ALL defined process flows and associated versions are available for selection (by default, the latest is prompted). This removes the restriction of only being able to call deployed &#x26; enabled process flows.  </p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/cCGFzBxcMQVD44UtAtSS">Run process flow shape</a></p></td><td>CPT-2983</td></tr><tr><td><span data-option="L09Gy6z2y7VD">Breaking change</span></td><td><p><strong>Filters: enforced validation for data types</strong> <br>Additional validation has been added for filters, which means that input values must be of the expected data type. For example, consider the payload below:</p><pre class="language-json" data-line-numbers><code class="lang-json">{"name": "Jane Smith",  "ref": "14"},
{"name": "Bob Smith",  "ref": 14},
</code></pre><p>Notice that both records include a ref field, but one (Jane) is a <code>string</code> type value and the other (Bob) is a <code>number</code> type value. Now suppose we define a filter to examine the <code>ref</code> field, and to expect the value of this field to be a <code>number</code> . </p><p></p><p>Previously, the data type was not validated, so both records (Jane and Bob) would have been matched. Now, the data type defined in filters is validated and a record will only be matched if the filter value is of the expected type. This is a phased change. </p><p></p><p><strong>Phase 1 (this release)</strong></p><p>In this release, any data type validation issues will be reported as warnings in run logs but this will <strong>not</strong> cause filter behaviour to change. So taking our example above, both records (Jane and Bob) would continue to be matched. </p><p></p><p><strong>Phase 2 (next release)</strong><br>In our next release, data type validation for filters will be enforced - i.e. filter behaviour will change so a record will only be matched if the required value is of the expected type. Taking our example above, only Bob will be matched - Jane would not be matched because the <code>ref</code> field is provided as a <code>string</code>.</p><p><br>For more information please see the <a href="https://doc.wearepatchworks.com/product-documentation/release-information/core-release-notes/2024-03-21-release-notes-core#breaking-changes">Breaking changes</a> section.</p></td><td>CPT-2862</td></tr><tr><td><span data-option="9a29ee576f43448f9b1623baca59c3db">Bug</span></td><td><p><strong>Company insights - usage stats</strong><br>Fixed issue where usage figures shown in the left-hand navigation bar may not match the main customer insights page.  </p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/M56kqGs9ntTD849w6gKi">Company insights </a></p></td><td>CPT-1568</td></tr><tr><td><span data-option="9a29ee576f43448f9b1623baca59c3db">Bug</span></td><td><p><strong>Company insights - graph display</strong><br>Fixed issue where the graph display could be lost when switching between process flows/connectors/shapes tabs multiple times in quick succession. Now, switching between tabs is not possible until the current graph is fully loaded. In a related issue, graph zoom has been disabled.  </p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/M56kqGs9ntTD849w6gKi">Company insights </a></p></td><td>CPT-3097 <br>CPT-3098</td></tr><tr><td><span data-option="9a29ee576f43448f9b1623baca59c3db">Bug</span></td><td><p><strong>Static date selector for variables</strong><br>Fixed issue where no time selector was available when choosing to add a static date/time in a flow variable or in the set variables shape. </p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/sCJOjrLZifsLUf5k3omc">Flow variables</a></p></td><td>CPT-2451</td></tr><tr><td><span data-option="9a29ee576f43448f9b1623baca59c3db">Bug</span></td><td><p><strong>Route shape settings</strong><br>Fixed issue where creating a new route for a route shape did not go on to display settings for that route. Now, associated settings are shown when a new route is created. </p><p> <img src="/files/MexWutUpX0IvLKh7ZgY1" alt=""><a href="/pages/7qvE65C5mdtXjrbB4swe">Route shape</a></p></td><td>CPT-3129</td></tr></tbody></table>

## Breaking changes

This release includes changes that may affect the behaviour of filters defined in existing process flows. Please follow the advice below to avoid any issues.

### **Filter validation enforcement**

When defining process flow filters (for example, in a [filter](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/filter-shape.md) or [route](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/route-shape.md) shape), you select a data field and then the corresponding data type for this field - for example:

![](https://lh7-us.googleusercontent.com/docsz/AD_4nXcbr4erJfrdkmkztTpMgy3MuHiunn26CKOyrXV9NQSMltTclitrEsVWXvsoaafpCMdfnGzXACkMaAhBX8-oc4N--Ie3Mjvs-w8zzYn2ZSQZmDykxdUHJsv995cyqEAi0G04YosQGPjjCWVHJujTmEyB6CJN?key=zfR9MIg31nNOlUtKeA-LUA)

\
In this release, we start to enforce the specified data type for any filters. For example, if a filter based on the `customer_id` field is defined to expect `string` data, but the incoming payload provides these values as numbers, this will cause a validation error.

#### What's happening?

Filter validation issues will be enforced in two phases:

<table><thead><tr><th>Phase</th><th width="340">What will happen</th><th>When</th></tr></thead><tbody><tr><td>1: Warning </td><td>In this release, any data type validation issues will be reported as warnings in run logs but this will <strong>not</strong> cause filter behaviour to change:<br><br><img src="https://lh7-us.googleusercontent.com/docsz/AD_4nXdT2iFqUYt-Eh0MfdetMg1-e5yoZq333MwBDCsOP1IqI5efVWOtznfQ9GBLftJrhTtGSQcTC2AggAcLB8cfCOJkNlrLRxKpe0iwmdq_taAwoScl3q9ksMbnYNQNSWFV60x88xzu4slW-9t8TUDAE2vDPyfT?key=zfR9MIg31nNOlUtKeA-LUA" alt=""><br></td><td>17th July 2024</td></tr><tr><td>2: Enforcement</td><td><p>If a process flow runs and an invalid data type is passed into a filter, a warning message is displayed in the run logs.</p><p></p><p>A record that previously matched a filter based on the required filter value will now fail to match if that value is not of the expected data type.   </p></td><td><a href="/pages/Iat2n94pLMd4SeTcIamx">24th July 2024</a></td></tr></tbody></table>

#### Phase 1 (recommended actions prior to this release)

Phase 1 is scheduled for implementation on the **17th July 2024**. We recommend making the following checks before this time:

*Filter & route shapes*

Check any [filter](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/filter-shape.md) and [route](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/route-shape.md) shapes in your process flows now, and ensure that defined data types reflect your source data. If you find a mismatch, you can:

* Change the data type for the process filter, if appropriate
* Apply a field transform (via a [map shape](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/map-shape.md)) immediately before the filter step to convert incoming values to a different data type. Several transform functions are available which can help to change data from one type to another - please see [Working with field mapping transformations](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/map-shape/working-with-field-transformations.md) for more information.
* Change the data type for this value at source (if you have the option to do so)

*Connector shapes*

Check any [connector](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/connector-shape.md) shapes in your process flows, and ensure that defined data types reflect your source data. If you find a mismatch, action depends on whether the connector is a standard [Patchworks connector](/product-documentation/connectors-and-instances/patchworks-connectors.md) or a custom connector that was built by your own company with the [Connector builder](/product-documentation/developer-hub/connector-builder.md):

* For a standard [Patchworks connector](/product-documentation/connectors-and-instances/patchworks-connectors.md), it’s advisable to change the data type for this value at source. If this isn’t possible, you can edit the filter within the [connector endpoint setup](/product-documentation/developer-hub/connector-builder/building-your-own-connector/4-endpoints/endpoint-options/url.md) and change the data type to match source data. However, be aware that if you subsequently install a Patchworks update for this connector, your changes will be overwritten.
* For custom connectors, you can edit the filter within the [connector endpoint setup](/product-documentation/developer-hub/connector-builder/building-your-own-connector/4-endpoints/endpoint-options/url.md) and change the data type to match source data.

#### Phase 1 (recommended actions ASAP after this release)

After the release on the **17th July 2024**, please review [run logs](/product-documentation/process-flows/error-reporting-and-exception-handling/run-logs-and-queue.md) for all of your active process flows and check if there are any warnings - for example:&#x20;

<figure><img src="/files/5DKZEMUOUJ3qdKsqBC8U" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
You can filter your run logs list so that only entries with warnings are displayed.
{% endhint %}

If warnings are given, please check the associated process flow and make changes as detailed [above](#phase-1-recommended-actions-prior-to-this-release).

#### Phase 2 action required

Phase 2 is scheduled for implementation on the [24th July 2024](/product-documentation/release-information/core-release-notes/2024-07-31-release-notes-core.md). We recommend checking [run logs](/product-documentation/process-flows/error-reporting-and-exception-handling/run-logs-and-queue.md) for your flows with extra care as soon as possible after this release, just in case validation issues are still present.

{% hint style="danger" %}
Please see release notes for the [24th July 2024](/product-documentation/release-information/core-release-notes/2024-07-31-release-notes-core.md) regarding Phase 2 of this change, and also Phase 2 of a similar change to transform validations.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.wearepatchworks.com/product-documentation/release-information/core-release-notes/2024-07-17-release-notes-core.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
