fast-aircraft-design / FAST-OAD

FAST-OAD: An open source framework for rapid Overall Aircraft Design
GNU General Public License v3.0
47 stars 25 forks source link

Now accepting upper case distribution names for plugins #499

Closed christophe-david closed 10 months ago

christophe-david commented 10 months ago

When installed from PyPI, Python package names are generally in lower case with hyphens, even if the official package is upper case (e.g. FAST-OAD-CS25).

Nevertheless, when installed in development mode using pip install ., the same package can be seen in pip list in its original form, that can contain upper case and underscores.

PEP 426 clearly states that such difference should have no impact :

All comparisons of distribution names MUST be case insensitive, and MUST consider hyphens and underscores to be equivalent.

Therefore, this PR makes sure that the distribution name of FAST-OAD plugins can be available in lower/upper case with hyphens or underscores without any impact.

codecov[bot] commented 10 months ago

Codecov Report

Merging #499 (94a2ca3) into master (6428b21) will increase coverage by 0.04%. Report is 7 commits behind head on master. The diff coverage is 91.52%.

@@            Coverage Diff             @@
##           master     #499      +/-   ##
==========================================
+ Coverage   84.41%   84.46%   +0.04%     
==========================================
  Files         131      132       +1     
  Lines        6018     6063      +45     
  Branches      883      891       +8     
==========================================
+ Hits         5080     5121      +41     
- Misses        783      785       +2     
- Partials      155      157       +2     
Files Changed Coverage Δ
src/fastoad/constants.py 76.92% <ø> (ø)
src/fastoad/module_management/_plugins.py 90.00% <89.28%> (-0.17%) :arrow_down:
src/fastoad/_utils/dicts.py 92.00% <92.00%> (ø)
...ls/performances/mission/segments/time_step_base.py 93.54% <100.00%> (+0.10%) :arrow_up: