Skip to content

Commit ce60fd4

Browse files
committed
bug: relief jinja2 version restriction
jinja2 version 3 did not introduce breaking changes, so we can remove the version restriction add the requirement also for the jinja expert fix error message on the required library in the jinja expert
1 parent 39b0261 commit ce60fd4

File tree

4 files changed

+10
-3
lines changed

4 files changed

+10
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,12 +76,15 @@ CHANGELOG
7676
- `intelmq.bots.experts.remove_affix`: Remove prefix or postfix strings from a field (PR#1965 by Marius Karotkis).
7777
- `intelmq.bots.experts.asn_lookup.expert`: Fixes update-database script on the last few days of a month (PR#2121 by Filip Pokorný, fixes #2088).
7878
- `intelmq.bots.experts.threshold.expert`: Correctly use the standard parameter `redis_cache_ttl` instead of the previously used parameter `timeout` (PR#2155 by Karl-Johan Karlsson).
79+
- `intelmq.bots.experts.jinja2.expert`: Lift restriction on requirement jinja2 < 3 (PR#2158 by Sebastian Wagner).
7980

8081
#### Outputs
8182
- Removed `intelmq.bots.outputs.postgresql`: this bot was marked as deprecated in 2019 announced to be removed in version 3 of IntelMQ (PR#2045 by Birger Schacht).
8283
- Added `intelmq.bots.outputs.rpz_file.output` to create RPZ files (PR#1962 by Marius Karotkis).
8384
- Added `intelmq.bots.outputs.bro_file.output` to create Bro intel formatted files (PR#1963 by Marius Karotkis).
84-
- `intelmq.bots.outputs.templated_smtp.output`: Add new function `from_json()` (which just calls `json.loads()` in the standard Python environment), meaning the Templated SMTP output bot can take strings containing JSON documents and do the formatting itself (PR#2120 by Karl-Johan Karlsson).
85+
- `intelmq.bots.outputs.templated_smtp.output`:
86+
- Add new function `from_json()` (which just calls `json.loads()` in the standard Python environment), meaning the Templated SMTP output bot can take strings containing JSON documents and do the formatting itself (PR#2120 by Karl-Johan Karlsson).
87+
- Lift restriction on requirement jinja2 < 3 (PR#2158 by Sebastian Wagner).
8588

8689
### Documentation
8790
- Feeds: Add documentation for newly supported dataplane feeds, see above (PR#2102 by Mikk Margus Möll).
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# SPDX-FileCopyrightText: 2022 Sebastian Wagner <[email protected]>
2+
# SPDX-License-Identifier: AGPL-3.0-or-later
3+
4+
jinja2>=2.11

intelmq/bots/experts/jinja/expert.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class JinjaExpertBot(Bot):
3232

3333
def init(self):
3434
if not Template:
35-
raise MissingDependencyError("Library 'jinja2' is required, please install it.")
35+
raise MissingDependencyError("jinja2")
3636

3737
for field, template in self.fields.items():
3838
if template.startswith("file:///"):
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# SPDX-FileCopyrightText: 2021 Linköping University <https://liu.se/>
22
# SPDX-License-Identifier: AGPL-3.0-or-later
33

4-
jinja2>=2.11,<3
4+
jinja2>=2.11

0 commit comments

Comments
 (0)