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

Detect too-deep nested folder structure #464

Closed
TwitchBronBron opened this issue Oct 26, 2021 · 2 comments
Closed

Detect too-deep nested folder structure #464

TwitchBronBron opened this issue Oct 26, 2021 · 2 comments
Assignees

Comments

@TwitchBronBron
Copy link
Member

TwitchBronBron commented Oct 26, 2021

roku will not read files that are >= 8 directories deep like so:
image

We should determine the edge cases for this, and then add diagnostics for the destPath on files that are too nested.

Here are the tests that have been verified

  • components living in the 8th directory or deeper will not compile.
    • /components/modules/Test/Test/Test/Test/CustomProgressBar/CustomProgressBar.xml (WORKS)
    • /components/modules/Test/Test/Test/Test/Test/CustomProgressBar/CustomProgressBar.xml (FAILS)
  • images can be loaded at any directory level
    • used in <poster> node (WORKS)
    • used in manifest as the splash image (WORKS)
  • scripts at any level can be imported into components
    • <script uri="pkg:/components/modules/Test/Test/Test/Test/Test/Dummy/Dummy.brs"> (WORKS)

From all of these tests, it appears the issue is that that the BrightScript compiler file auto-discovery algorithm limits itself to 7 directories deep...but the files themselves still exist and can be directly referenced by uri-style references.

Here are the restrictions we need to guard against:

  • .xml files in the pkg:/components folder should be flagged if they are 8 or more directories deep
  • .brs and .bs files in the pkg:/source folder should be flagged if they are 8 or more directories deep
@iObject iObject self-assigned this Aug 22, 2022
@iObject
Copy link
Collaborator

iObject commented Aug 26, 2022

Note: This does not reflect images. Included ones referenced in the manifest.

@TwitchBronBron
Copy link
Member Author

Completed in #680

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

No branches or pull requests

2 participants