propelorm / Propel2

Propel2 is an open-source high-performance Object-Relational Mapping (ORM) for modern PHP
http://propelorm.org/
MIT License
1.26k stars 399 forks source link

Bugfix: remove undefined index notice from profiler #1716

Closed mringler closed 3 years ago

mringler commented 3 years ago

When using the Profiler to check time and memory usage, php shows three notices:

Notice: Undefined index: microtime in vendor/propel/propel/src/Propel/Runtime/Util/Profiler.php on line 242 Notice: Undefined index: microtime in vendor/propel/propel/src/Propel/Runtime/Util/Profiler.php on line 253 Notice: Undefined index: memoryUsage in vendor/propel/propel/src/Propel/Runtime/Util/Profiler.php on line 261

The problem is outlined here.

If merged, this replaces #1647

codecov-io commented 3 years ago

Codecov Report

Merging #1716 (40012b7) into master (d0d4214) will increase coverage by 0.03%. The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #1716      +/-   ##
============================================
+ Coverage     88.26%   88.30%   +0.03%     
+ Complexity     7707     7705       -2     
============================================
  Files           261      261              
  Lines         22084    22081       -3     
============================================
+ Hits          19493    19498       +5     
+ Misses         2591     2583       -8     
Flag Coverage Δ Complexity Δ
5-max 88.30% <100.00%> (+0.03%) 0.00 <0.00> (ø)
7.4 88.30% <100.00%> (+0.03%) 0.00 <0.00> (ø)
agnostic 73.58% <100.00%> (+0.04%) 0.00 <0.00> (ø)
mysql 69.90% <0.00%> (-0.02%) 0.00 <0.00> (ø)
pgsql 70.43% <0.00%> (-0.02%) 0.00 <0.00> (ø)
sqlite 68.35% <0.00%> (-0.02%) 0.00 <0.00> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ Complexity Δ
...rc/Propel/Runtime/Connection/ConnectionWrapper.php 96.81% <ø> (-0.12%) 70.00 <0.00> (-3.00)
src/Propel/Runtime/Util/Profiler.php 87.95% <100.00%> (+10.45%) 34.00 <0.00> (+1.00)

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 d0d4214...40012b7. Read the comment docs.

dereuromark commented 3 years ago

Do we have a resolution on the open comments? Is this mergable?

mringler commented 3 years ago

Do we have a resolution on the open comments? Is this mergable?

Marked my walkthrough comments as resolved.