Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: handle null traits for regex evaluations #152

Merged
merged 1 commit into from
May 23, 2024

Conversation

matthewelwell
Copy link
Contributor

@matthewelwell matthewelwell commented May 23, 2024

This PR fixes an issue where the regex operator would throw an exception if the trait value was null.

Note that this PR also converts any non-string traits to strings to match the behaviour of the python client as seen here.

@matthewelwell matthewelwell force-pushed the fix/null-traits-breaks-regex branch from 30308cb to 3cddfb3 Compare May 23, 2024 16:23
@matthewelwell matthewelwell requested review from a team, gagantrivedi, rolodato and novakzaballa and removed request for a team May 23, 2024 16:23
@matthewelwell matthewelwell merged commit 57a5ce1 into main May 23, 2024
1 check passed
renovate bot referenced this pull request in open-feature/playground Jul 25, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [flagsmith-nodejs](http://flagsmith.com/)
([source](https://togithub.com/Flagsmith/flagsmith-nodejs-client)) |
[`3.3.0` ->
`3.3.3`](https://renovatebot.com/diffs/npm/flagsmith-nodejs/3.3.0/3.3.3)
|
[![age](https://developer.mend.io/api/mc/badges/age/npm/flagsmith-nodejs/3.3.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/flagsmith-nodejs/3.3.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/flagsmith-nodejs/3.3.0/3.3.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/flagsmith-nodejs/3.3.0/3.3.3?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>Flagsmith/flagsmith-nodejs-client (flagsmith-nodejs)</summary>

###
[`v3.3.3`](https://togithub.com/Flagsmith/flagsmith-nodejs-client/releases/tag/v3.3.3)

[Compare
Source](https://togithub.com/Flagsmith/flagsmith-nodejs-client/compare/v3.3.2...v3.3.3)

#### What's Changed

- Cancel timeout when it is no longer needed by
[@&#8203;wheineman-sunrun](https://togithub.com/wheineman-sunrun) in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/141](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/141)

#### New Contributors

- [@&#8203;wheineman-sunrun](https://togithub.com/wheineman-sunrun) made
their first contribution in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/141](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/141)

**Full Changelog**:
Flagsmith/flagsmith-nodejs-client@v3.3.2...v3.3.3

###
[`v3.3.2`](https://togithub.com/Flagsmith/flagsmith-nodejs-client/releases/tag/v3.3.2)

[Compare
Source](https://togithub.com/Flagsmith/flagsmith-nodejs-client/compare/v3.3.1...v3.3.2)

#### What's Changed

- fix: handle null traits for regex evaluations by
[@&#8203;matthewelwell](https://togithub.com/matthewelwell) in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/152](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/152)

**Full Changelog**:
Flagsmith/flagsmith-nodejs-client@v3.3.1...v3.3.2

###
[`v3.3.1`](https://togithub.com/Flagsmith/flagsmith-nodejs-client/releases/tag/v3.3.1)

[Compare
Source](https://togithub.com/Flagsmith/flagsmith-nodejs-client/compare/v3.3.0...v3.3.1)

#### What's Changed

- fix: only flush analytics once if requested concurrently by
[@&#8203;rolodato](https://togithub.com/rolodato) in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/148](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/148)
- fix: error evaluating CONTAINS / NOT_CONTAINS for null traits by
[@&#8203;matthewelwell](https://togithub.com/matthewelwell) in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/150](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/150)
- Bump version 3.3.1 by
[@&#8203;matthewelwell](https://togithub.com/matthewelwell) in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/151](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/151)

#### New Contributors

- [@&#8203;rolodato](https://togithub.com/rolodato) made their first
contribution in
[https://github.com/Flagsmith/flagsmith-nodejs-client/pull/148](https://togithub.com/Flagsmith/flagsmith-nodejs-client/pull/148)

**Full Changelog**:
Flagsmith/flagsmith-nodejs-client@v3.3.0...v3.3.1

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View the
[repository job
log](https://developer.mend.io/github/open-feature/playground).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40MzguMCIsInVwZGF0ZWRJblZlciI6IjM3LjQzOC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJyZW5vdmF0ZSJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants