-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Remove lib.Archive.Files and lib.Archive.Scripts #838
Labels
Comments
mstoykov
added a commit
that referenced
this issue
Jun 26, 2019
This includes also change to the archive file structure. Now instead of separating files by whether they are scripts or no, they are separated based on whether their URI scheme. Through the (majority) of k6 now instead of simple strings a url.URL is used to idenitify files(scripts or otherwise). This also means that all imports or `open` can have schemes. Previously remote modules were supported specifically without scheme. With this change we specifically prefer if they are with a scheme. The old variant is supported but logs a warning. Additionally if remote module requires a relative/absolute path that doesn't have a scheme it is relative/absolute given the remote module url. Because of some of the changes, now caching is done through a afero.Fs instead of additional map. This also fixes not laoding remotely imported files from an archive, but instead requesting them again. fixes #1037, closes #838, fixes #887 and fixes #1051
mstoykov
added a commit
that referenced
this issue
Jul 31, 2019
This also includes a change to the archive file structure. Now instead of separating files by whether they are scripts or not, they are separated based on their URI scheme. Throughout the (majority) of k6 now, instead of simple strings, a url.URL is used to identify files (scripts or otherwise). This also means that all imports can have schemes. Previously remote modules were supported specifically without a scheme. With this change k6 prefers if they are with a scheme. The old variant is supported, but logs a warning. Additionally if remote module requires a relative/absolute path that doesn't have a scheme, it is relative/absolute given the remote module url. Because of some of the changes, now caching is done through a afero.Fs instead of additional maps. This also fixes the remotely imported files not properly loading from an archive, but instead requesting them again. This is supported with old archives and for github/cdnjs's shortcut loaders. For future-proof reasons the archive now also records the GOOS value of the k6 that generated it. Anonymize case insensitively as windows paths are (usually) case insensitive. fixes #1037, closes #838, fixes #887 and fixes #1051
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
After the retouching in #823 the two fields are not needed but are somewhat used for caching calls to open().
They should be removed and it should be checked that nothing breaks
The text was updated successfully, but these errors were encountered: