You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docsite/rst/porting_guides/porting_guide_12.rst
+139-9Lines changed: 139 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -55,7 +55,9 @@ An explicit predicate with a boolean result, such as ``| length > 0`` or ``is tr
55
55
- assert:
56
56
that: inventory_hostname
57
57
58
-
The error reported is::
58
+
The error reported is:
59
+
60
+
.. code-block:: text
59
61
60
62
Conditional result was 'localhost' of type 'str', which evaluates to True. Conditionals must have a boolean result.
61
63
@@ -80,7 +82,9 @@ The quoted part becomes the expression result (evaluated as truthy), so the expr
80
82
that: inventory_hostname is defined and 'inventory_hostname | length > 0'
81
83
82
84
83
-
The error reported is::
85
+
The error reported is:
86
+
87
+
.. code-block:: text
84
88
85
89
Conditional result was 'inventory_hostname | length > 0' of type 'str', which evaluates to True. Conditionals must have a boolean result.
86
90
@@ -105,7 +109,9 @@ Previous Ansible releases could mask some expression syntax errors as a truthy r
105
109
# ^ invalid comma
106
110
107
111
108
-
The error reported is::
112
+
The error reported is:
113
+
114
+
.. code-block:: text
109
115
110
116
Syntax error in expression: chunk after expression
111
117
@@ -125,7 +131,9 @@ The result is always a non-empty string, which is truthy.
125
131
that: inventory_hostname is contains "local" ~ "host"
126
132
127
133
128
-
The error reported is::
134
+
The error reported is:
135
+
136
+
.. code-block:: text
129
137
130
138
Conditional result was 'Truehost' of type 'str', which evaluates to True. Conditionals must have a boolean result.
131
139
@@ -152,7 +160,9 @@ Non-empty mappings are always truthy.
152
160
- result.msg == "some_key: some_value"
153
161
# ^^ colon+space == problem
154
162
155
-
The error reported is::
163
+
The error reported is:
164
+
165
+
.. code-block:: text
156
166
157
167
Conditional expressions must be strings.
158
168
@@ -186,7 +196,9 @@ This conditional references a variable using a template instead of using the var
186
196
value: 1
187
197
188
198
189
-
The error reported is::
199
+
The error reported is:
200
+
201
+
.. code-block:: text
190
202
191
203
Syntax error in expression. Template delimiters are not supported in expressions: expected token ':', got '}'
192
204
@@ -216,7 +228,9 @@ which was later evaluated by the ``assert`` action.
216
228
comparison: ==
217
229
218
230
219
-
The error reported is::
231
+
The error reported is:
232
+
233
+
.. code-block:: text
220
234
221
235
Syntax error in expression. Template delimiters are not supported in expressions: chunk after expression
222
236
@@ -235,7 +249,7 @@ The environment variable ``_ANSIBLE_TEMPLAR_UNTRUSTED_TEMPLATE_BEHAVIOR`` can be
235
249
236
250
Valid options are:
237
251
238
-
* ``warn`` - A warning will be issued when an untrusted template is encountered.
252
+
* ``warning`` - A warning will be issued when an untrusted template is encountered.
239
253
* ``fail`` - An error will be raised when an untrusted template is encountered.
240
254
* ``ignore`` - Untrusted templates are silently ignored and used as-is. This is the default behavior.
241
255
@@ -552,7 +566,9 @@ location of the expression that accessed it.
552
566
)
553
567
554
568
555
-
When accessing the `color_name` from the module result, the following warning will be shown::
569
+
When accessing the `color_name` from the module result, the following warning will be shown
570
+
571
+
.. code-block:: text
556
572
557
573
[DEPRECATION WARNING]: The `color_name` return value is deprecated. This feature will be removed from the 'ns.collection.paint' module in a future release.
558
574
Origin: /examples/use_deprecated.yml:8:14
@@ -762,6 +778,32 @@ Noteworthy plugin changes
762
778
This filter now returns ``False`` instead of ``None`` when the input is ``None``.
763
779
The aforementioned deprecation warning is also issued in this case.
764
780
781
+
* Passing nested non-scalars with embedded templates that may resolve to ``Undefined`` to Jinja2
782
+
filter plugins, such as ``default`` and ``mandatory``, and test plugins including ``defined`` and ``undefined``
783
+
no longer evaluate as they did in previous versions because nested non-scalars with embedded templates are templated
784
+
on use only.
785
+
In 2.19, this assertion passes:
786
+
787
+
.. code-block:: yaml
788
+
789
+
- assert:
790
+
that:
791
+
# Unlike earlier versions, complex_var is defined even though complex_var.nested is not.
792
+
- complex_var is defined
793
+
# Unlike earlier versions, the default value is not applied because complex_var is defined.
794
+
- (complex_var | default(unused)).nested is undefined
795
+
# Like earlier versions, directly accessing complex_var.nested evaluates as undefined.
796
+
- complex_var.nested is undefined
797
+
vars:
798
+
complex_var:
799
+
# Before 2.19, complex_var.nested is evaluated immediately when complex_var is accessed.
800
+
# In 2.19, complex_var.nested is evaluated only when it is accessed.
801
+
nested: "{{ undefined_variable }}"
802
+
unused:
803
+
# This variable is used only if complex_var is undefined.
804
+
# This only happens in ansible-core before 2.19.
805
+
nested: default
806
+
765
807
766
808
Porting custom scripts
767
809
======================
@@ -774,6 +816,94 @@ Networking
774
816
775
817
No notable changes
776
818
819
+
Porting Guide for v12.0.0b1
820
+
===========================
821
+
822
+
Added Collections
823
+
-----------------
824
+
825
+
- google.cloud (version 1.6.0)
826
+
827
+
Known Issues
828
+
------------
829
+
830
+
community.libvirt
831
+
^^^^^^^^^^^^^^^^^
832
+
833
+
- virt_volume - check_mode is disabled. It was not fully supported in the previous code either ('state/present', 'command/create' did not support it).
834
+
835
+
Breaking Changes
836
+
----------------
837
+
838
+
community.hashi_vault
839
+
^^^^^^^^^^^^^^^^^^^^^
840
+
841
+
- ansible-core - support for all end-of-life versions of ``ansible-core`` has been dropped. The collection is tested with ``ansible-core>=2.17`` (https://github.com/ansible-collections/community.hashi_vault/issues/470).
842
+
- python - support for older versions of Python has been dropped. The collection is tested with all supported controller-side versions and a few lower target-side versions depending on the tests (https://github.com/ansible-collections/community.hashi_vault/issues/470).
843
+
844
+
Major Changes
845
+
-------------
846
+
847
+
- The previously removed collection google.cloud was re-added to Ansible 12 (`https://forum.ansible.com/t/8609 <https://forum.ansible.com/t/8609>`__).
848
+
The sanity test failures have been addressed.
849
+
850
+
community.libvirt
851
+
^^^^^^^^^^^^^^^^^
852
+
853
+
- virt_volume - a new command 'create_cidata_cdrom' enables the creation of a cloud-init CDROM, which can be attached to a cloud-init enabled base image, for bootstrapping networking, users etc.
854
+
- virt_volume - the commands create_from, delete, download, info, resize, upload, wipe, facts did not work and were not tested. They have either been refactored to work, and tested, or removed.
855
+
- virt_volume - the mechanism of passing variables to the member functions was not flexible enough to cope with differing parameter requirements. All parameters are now passed as kwargs, which allows the member functions to select the parameters they need.
856
+
- virt_volume - the module appears to have been derived from virt_pool, but not cleaned up to remove much non-functional code. It has been refactored to remove the pool-specific code, and to make it more flexible.
857
+
858
+
community.zabbix
859
+
^^^^^^^^^^^^^^^^
860
+
861
+
- All Roles - Updated to support Zabbix 7.4
862
+
863
+
Removed Features
864
+
----------------
865
+
866
+
community.libvirt
867
+
^^^^^^^^^^^^^^^^^
868
+
869
+
- virt_volume - PoolConnection class has been removed
870
+
- virt_volume - the 'deleted' state has been removed as its definition was not entirely accurate, and the 'wipe' boolean option is added to 'state/absent' and 'command/delete'.
871
+
- virt_volume - undocumented but unused FLAGS have been removed.
872
+
- virt_volume - undocumented but unused/non-functional functions (get_status, get_status2, get_state, get_uuid, build) have been removed.
873
+
874
+
hitachivantara.vspone_block
875
+
^^^^^^^^^^^^^^^^^^^^^^^^^^^
876
+
877
+
- `hv_gateway_admin_password` module has been removed.
878
+
- `hv_gateway_subscriber_facts` module has been removed.
879
+
- `hv_gateway_subscriber` module has been removed.
880
+
- `hv_gateway_subscription_facts` module has been removed.
881
+
- `hv_gateway_unsubscribe_resource` module has been removed.
882
+
- `hv_storagesystem` module has been removed.
883
+
- `hv_system_facts` module has been removed.
884
+
- `hv_uaig_token_facts` module has been removed.
885
+
886
+
Deprecated Features
887
+
-------------------
888
+
889
+
community.general
890
+
^^^^^^^^^^^^^^^^^
891
+
892
+
- catapult - module is deprecated and will be removed in community.general 13.0.0 (https://github.com/ansible-collections/community.general/issues/10318, https://github.com/ansible-collections/community.general/pull/10329).
893
+
- pacemaker_cluster - the parameter ``state`` will become a required parameter in community.general 12.0.0 (https://github.com/ansible-collections/community.general/pull/10227).
894
+
895
+
community.hashi_vault
896
+
^^^^^^^^^^^^^^^^^^^^^
897
+
898
+
- ansible-core - support for several ``ansible-core`` versions will be dropped in ``v7.0.0``. The collection will focus on current supported versions of ``ansible-core`` going forward and more agressively drop end-of-life or soon-to-be EOL versions (https://docs.ansible.com/ansible/devel/reference_appendices/release_and_maintenance.html).
899
+
- python - support for several ``python`` versions will be dropped in ``v7.0.0``. The collection will focus on ``python`` versions that are supported by the active versions of ``ansible-core`` on the controller side at a minimum, and some subset of target versions (https://docs.ansible.com/ansible/devel/reference_appendices/release_and_maintenance.html).
900
+
901
+
community.zabbix
902
+
^^^^^^^^^^^^^^^^
903
+
904
+
- Web Role - Depricated `zabbix_web_SSLSessionCacheTimeout` for `zabbix_web_ssl_session_cache_timeout`
905
+
- Web Role - Depricated `zabbix_web_SSLSessionCache` for `zabbix_web_ssl_session_cache`
0 commit comments