CQ-editor
CQ-editor copied to clipboard
Fix empty dict as default arg
See e.g. https://towardsdatascience.com/python-pitfall-mutable-default-arguments-9385e8265422
(It happened to me that an object was stubbornly getting color set in previous runs.)
Codecov Report
Merging #322 (14146f8) into master (0d091ba) will increase coverage by
0.00%
. The diff coverage is100.00%
.
@@ Coverage Diff @@
## master #322 +/- ##
=======================================
Coverage 88.59% 88.59%
=======================================
Files 19 19
Lines 1490 1491 +1
Branches 201 201
=======================================
+ Hits 1320 1321 +1
Misses 137 137
Partials 33 33
Impacted Files | Coverage Δ | |
---|---|---|
cq_editor/widgets/object_tree.py | 93.92% <100.00%> (+0.02%) |
:arrow_up: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 0d091ba...14146f8. Read the comment docs.
Thanks, how did you manage to modify the dict? Or did it happen in the CQ-editor code?
Thanks, how did you manage to modify the dict? \
I can't remember anymore; I was trying different ways to make show_object
show the object with label (and persistent properties) in the CQ editor; and then it happened that re-running the script with options removed was still setting the color.