Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consistently resolve component resources using relative paths #3303

Merged
merged 6 commits into from Apr 3, 2022

Conversation

philippjfr
Copy link
Member

Followup for #3284

This PR cleans up some of the crufty bits that were in the original ComponentResourceHandler PR. Specifically all URLs for custom component resources are now expressed relative to the component. This means we are no longer encoding absolute paths in the URL (and indeed we no longer accept absolute paths either). Additionally this cleans up the code a bit ensuring that everywhere that generates and consumes component URLs uses the same functions to do so.

@codecov
Copy link

codecov bot commented Apr 3, 2022

Codecov Report

Merging #3303 (466ee90) into master (914ca6e) will increase coverage by 0.00%.
The diff coverage is 76.82%.

@@           Coverage Diff           @@
##           master    #3303   +/-   ##
=======================================
  Coverage   83.35%   83.36%           
=======================================
  Files         196      196           
  Lines       26485    26486    +1     
=======================================
+ Hits        22076    22079    +3     
+ Misses       4409     4407    -2     
Impacted Files Coverage Δ
panel/template/base.py 77.09% <68.88%> (+0.21%) ⬆️
panel/io/server.py 78.41% <72.72%> (+0.04%) ⬆️
panel/io/resources.py 86.77% <89.47%> (-0.42%) ⬇️
panel/tests/test_server.py 100.00% <100.00%> (ø)
panel/util.py 85.15% <100.00%> (+0.05%) ⬆️

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 914ca6e...466ee90. Read the comment docs.

@philippjfr philippjfr merged commit db8e0ac into master Apr 3, 2022
@philippjfr philippjfr deleted the relative_component_url branch April 3, 2022 11:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant