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

Provide completions after a variable resource path parameter in a resource access action #41628

Merged

Conversation

nipunayf
Copy link
Contributor

@nipunayf nipunayf commented Nov 2, 2023

Purpose

$title.

Fixes #41623

Approach

The current implementation of the type checker does not resolve the variable types of the path parameters if it encounters an error. The PR resolves the variable types despite the error conditions.

Samples

Completions are now shown after a resource path parameter with a variable, as shown below.

image

Check List

  • Read the Contributing Guide
  • Updated Change Log
  • Checked Tooling Support (#)
  • Added necessary tests
    • Unit Tests
    • Spec Conformance Tests
    • Integration Tests
    • Ballerina By Example Tests
  • Increased Test Coverage
  • Added necessary documentation
    • API documentation
    • Module documentation in Module.md files
    • Ballerina By Examples

@nipunayf nipunayf changed the title Provide completions after variable resource param Provide completions after a variable resource path parameter in a resource access action Nov 2, 2023
@nipunayf nipunayf force-pushed the fix-variable-resource-path branch 2 times, most recently from b6e1150 to 846a27f Compare November 6, 2023 04:31
@nipunayf nipunayf added the Team/LanguageServer Language Server Implementation related issues. #Compiler label Nov 8, 2023
@nipunayf nipunayf force-pushed the fix-variable-resource-path branch from 846a27f to 8dec779 Compare November 8, 2023 06:10
Copy link

codecov bot commented Nov 8, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (f95c5fb) 76.71% compared to head (a2f69d7) 76.71%.
Report is 3 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master   #41628      +/-   ##
============================================
- Coverage     76.71%   76.71%   -0.01%     
+ Complexity    52668    52667       -1     
============================================
  Files          2880     2880              
  Lines        198584   198585       +1     
  Branches      25802    25802              
============================================
- Hits         152343   152341       -2     
- Misses        37806    37807       +1     
- Partials       8435     8437       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

KavinduZoysa
KavinduZoysa previously approved these changes Nov 13, 2023
@nipunayf nipunayf force-pushed the fix-variable-resource-path branch 2 times, most recently from 3d9ce53 to 0f2b1f0 Compare November 18, 2023 14:18
@nipunayf nipunayf force-pushed the fix-variable-resource-path branch from 0f2b1f0 to a2f69d7 Compare November 20, 2023 11:32
@KavinduZoysa KavinduZoysa merged commit 03b5fb1 into ballerina-platform:master Nov 21, 2023
16 of 17 checks passed
@nipunayf nipunayf added this to the 2201.9.0 milestone Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team/LanguageServer Language Server Implementation related issues. #Compiler
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Completions are not provided after providing a variable for a resource path
3 participants