Skip to content

config:set fails with JSON values #22396

@MichaelThessel

Description

@MichaelThessel

Preconditions (*)

  1. 2.3.1

Steps to reproduce (*)

  1. Try to set a config value for a config option that uses JSON values via the command line cli
  2. i.e.: bin/magento config:set --scope default cataloginventory/item_options/min_sale_qty '{"_q0efyLTwddknOffVxvtSNpjQYmv9eAe9":{"customer_group_id":32000,"min_sale_qty":1}}' --lock-config

Expected result (*)

  1. Config is set to provided value

Actual result (*)

  1. Config is set to empty value.
  2. In the example above:
diff --git a/app/etc/config.php b/app/etc/config.php
index f3da38ee..34f30164 100644
--- a/app/etc/config.php
+++ b/app/etc/config.php
@@ -229,5 +229,15 @@ return [
         'Magento_WishlistGraphQl' => 1,
         'Temando_Shipping' => 1,
         'Vertex_Tax' => 1
+    ],
+    'system' => [
+        'default' => [
+            'cataloginventory' => [
+                'item_options' => [
+                    'min_sale_qty' => '',
+                ]
+            ]
+        ]
     ]
 ];

Metadata

Metadata

Assignees

Labels

Component: ConfigFixed in 2.2.xThe issue has been fixed in 2.2 release lineIssue: Clear DescriptionGate 2 Passed. Manual verification of the issue description passedIssue: ConfirmedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedIssue: Format is validGate 1 Passed. Automatic verification of issue format passedIssue: Ready for WorkGate 4. Acknowledged. Issue is added to backlog and ready for developmentReproduced on 2.3.xThe issue has been reproduced on latest 2.3 release

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions