-
-
Notifications
You must be signed in to change notification settings - Fork 31
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
Dash R Core Package Unification #243
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a great start -- thanks for taking this project on, definitely not the low-hanging fruit but this will make maintaining the package far easier, and dramatically simplify installations and version control for users when upgrading! 🙌
I think we have a bit more to puzzle through here before we proceed. Here's a list of the initial items to resolve:
- Do away with
gulp-assets
, so we 🚁 relocate the artifacts we want to retain from the three core packages directly into the cloneddash
repo, which should simplify cleanup also - Remove the three package-specific
.Rd
files likedashCoreComponents-package.Rd
before merging - Edit
dash-info.yaml
to scrub references todashTable
,dashHtmlComponents
,dashCoreComponents
- Remove
&& require(dash)
from the example apps, since there won't be issues with loading the component libraries withoutdash
anymore 😁 - Avoid hardcoding version numbers in the
gulpfile.js
(I suggested some regex, but there are multiple ways around this, the preferred strategy is up to you) - Double-check that the unified package handles pathname resolution properly for the merged-in package assets (there's a comment about this, maybe I'm paranoid, I'll test myself also)
Once we've sorted out ☝️, we should probably consider a deprecation message to appear conditionally on startup if any of the libraries are attached that are now removed. It seems doable without much fuss by storing .packages()
and then checking whether the libraries were previously loaded, e.g. something like
> library(dashHtmlComponents)
> library(dashCoreComponents)
> library(dash)
NOTE: As of version 1.0, the following packages are deprecated and should no longer be installed or loaded when using Dash for R: dashHtmlComponents, dashCoreComponents, dashTable. These components are now bundled into the dash package.
... and then let's 💃 🕺 🚀
- bump
dash
version to 1.0 since the API and package loading syntax is now stable!
@@ -0,0 +1,24 @@ | |||
# AUTO GENERATED FILE - DO NOT EDIT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was the creation and commission of the gulp-assets
folder intentional? If it's possible to relocate the resources in-place once, that would be ideal (e.g. things destined for R
, man
, inst
are copied into dash
as needed and artifacts are committed only once to their final destination).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The main point of having a dedicated directory was for ease of development and updates - for any DashR releases or version updates for the component packages, we can simply copy over the existing component directories to gulp-assets
and run the update
script to move the assets within to their respective dependency directories.
I do want to take another pass over this and maybe make it a little more like the dash
build process so there's less relocation.
gulp-assets/dash-core-components/man/dashCoreComponents-package.Rd
Outdated
Show resolved
Hide resolved
namespace = 'dash_core_components', | ||
propNames = c('id', 'options', 'value', 'className', 'style', 'inputStyle', 'inputClassName', 'labelStyle', 'labelClassName', 'loading_state', 'persistence', 'persisted_props', 'persistence_type'), | ||
package = 'dashCoreComponents' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, my gut feeling is that we probably want to retain the vestigial package
value when serializing into JSON, even though dashCoreComponents
technically no longer exists.
In other words, right now this is the behaviour, and I'm guessing it should remain as-is:
> library(dash)
> library(dashHtmlComponents)
> htmlDiv()
{
"props": {},
"type": "Div",
"namespace": "dash_html_components",
"propNames": ["children", "id", "n_clicks", "n_clicks_timestamp", "key", "role", "accessKey", "className", "contentEditable", "contextMenu", "dir", "draggable", "hidden", "lang", "spellCheck", "style", "tabIndex", "title", "loading_state"],
"package": "dashHtmlComponents"
}
@alexcjohnson What are your thoughts? Should we retain the existing namespace
and package
values? I imagine the namespace
must stay the same, but should we update package
to be dash
now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HammadTheOne Given the reasons outlined in #243 (comment), I believe we'll need to retain the package
key and update it to reflect the migration of the underlying JS into the dash
package.
So the JSON returned here should look like this, since the namespace will remain the same, but package
will change (so R can identify the proper system path when Dash serves up the asset to the browser):
{
"props": {},
"type": "Div",
"namespace": "dash_html_components",
"propNames": ["children", "id", "n_clicks", "n_clicks_timestamp", "key", "role", "accessKey", "className", "contentEditable", "contextMenu", "dir", "draggable", "hidden", "lang", "spellCheck", "style", "tabIndex", "title", "loading_state"],
"package": "dash"
}
gulpfile.js
Outdated
function cleanDescriptionImports() { | ||
return src('./DESCRIPTION') | ||
.pipe(print()) | ||
.pipe(replace(/Imports:/, 'Imports:\n dashHtmlComponents (== 1.1.1),\n dashCoreComponents (== 1.13.0),\n dashTable (== 4.11.0),')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similarly here, for the "Imports" line I think we might want to use a regex to scrub the old package entries. This would enable us to avoid hardcoding version numbers.
Just as an example, I believe I wrote a pattern that might help here when I automated the Dash build tests for R:
dashR/tests/circleci/fixup_metadata.R
Lines 30 to 32 in edbcc04
remotes <- gsub("((?<=plotly\\\\/dash-html-components@)([a-zA-Z0-9]+))", dhc_hash, remotes, perl=TRUE) | |
remotes <- gsub("((?<=plotly\\\\/dash-core-components@)([a-zA-Z0-9]+))", dcc_hash, remotes, perl=TRUE) | |
remotes <- gsub("((?<=plotly\\\\/dash-table@)([a-zA-Z0-9]+))", dt_hash, remotes, perl=TRUE) |
Keep in mind that some of the characters are for escaping other characters and I haven't tested this pattern outside of R 🙈
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to be operating on DESCRIPTION
with gulp at all? That file isn't auto-generated AFAICT, and the changes we're making here don't depend on anything variable coming in from the components. Can't we just make these changes by hand and leave them alone?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HammadTheOne I'm with @alexcjohnson here, let's avoid editing DESCRIPTION
with Gulp.js, we build this package "by hand" anyhow.
Not entirely sure, but I suspect some test failures may have occurred as a result of now-deprecated packages being loaded. Removed those in ef6a5c7, will try to get those passing before we merge. |
f48e894
to
be70c48
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not entirely sure, but I suspect some test failures may have occurred as a result of now-deprecated packages being loaded. Removed those in 6ee0633, will try to get those passing before we merge.
In addition to the failing integration tests, we were seeing some failing unit tests, so I've fixed those also in ef6a5c7.
@@ -2,6 +2,10 @@ | |||
All notable changes to `dash` will be documented in this file. | |||
This project adheres to [Semantic Versioning](http://semver.org/). | |||
|
|||
## [1.0.0] - 2021-03-04 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✨
dashHtmlComponents (== 1.1.1), | ||
dashCoreComponents (== 1.13.0), | ||
dashTable (== 4.11.0), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Collate: | ||
'utils.R' | ||
'dependencies.R' | ||
'dash-package.R' | ||
'dash.R' | ||
'imports.R' | ||
'print.R' | ||
'internal.R' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did this get removed when you re-ran devtools::document()
? The collation order of the R source files may not be important, but if we remove the entry (or devtools
did) we should just ensure that no issues arise from the new sourcing order.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did remove this manually. Ideally what I would expect to happen is that all the new .R
files present in the package like htmlHeader.R
would be appended to the Collate
entry with roxygen2::oxygenise()
. However, when I execute this, it does not generate an updated DESCRIPTION
and instead reverts the dependencies in NAMESPACE
instead. If we have the Collate
entry present, all of the R
files must be included or installation of the package fails.
Do you think there's a better way around it than simply removing it? I didn't notice any issues arising from removing it myself.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HammadTheOne Collate
probably doesn't matter unless there are potential side effects, and apparently the most common cause of this is use of S4 methods, which we don't have in this package:
I think it's safe to remove it. If the tests pass, and the package functionality remains as before, I'm OK if we 🔪 this block.
6ded12c
to
ef6a5c7
Compare
The script tags unit test was failing because the metadata for the JavaScript assets is no longer provided by external packages, so I've updated it also in 227df58. I'm optimistic that this should address the remaining test issues following the unification. |
R/dependencies.R
Outdated
@@ -124,7 +124,7 @@ dashNoUpdate <- function() { | |||
#' @rdname selectors | |||
#' @export | |||
#' @examples | |||
#' if (interactive() && require(dash)) { | |||
#' if (interactive() ) { | |||
#' library(dashCoreComponents) | |||
#' library(dashHtmlComponents) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔪 (I made a similar comment above, are there more cases like this?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, for example man/dash.Rd
has a bunch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've updated it in d66d720 for this branch. However, for future dcc/html/table updates, we'll also need to make PR's in those repos once this PR is merged to update the dash-info.yaml
and scrub the library imports and require(dash)
from the examples. It should be a relatively minor update and I can open those PR's after this one is merged.
@ryan @alexcjohnson I think this PR should be in pretty good shape with these last few commits. CI tests are running successfully (thanks @rpkyle!) and I haven't encountered any obvious issues in running multiple test apps. There should be no more reference to imports of the component libraries, and I've added in some I'd love to know if you have any final feedback before we can close this one out 🙂 |
Random note: looks like the example URL for
to
|
@HammadTheOne I went through the process of running the full Gulp workflow, assembled the unified package, and was able to run an application successfully -- but not without this
I think this default
We should fix this before we merge, I think (assuming you can reproduce this also). |
Thanks for catching that 🐛 - based on our discussion, this is now fixed in ec1ab35. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HammadTheOne Thanks for the additional favicon fix, looks 👌 on my end. I took the liberty of editing gulpfile.js
to use a shallow repo clone to speed things up when rebuilding the package. 🏆 💃
I'll see if I can fix up the dash-info.yaml
in the core repos myself and then we can rebuild this again before the release with updated examples.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's do it! 💃
* contribute test script * remove version updating in DESCRIPTION * fix EOL Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Add support for user-defined server routes (#225) * Provide support for script and stylesheet attributes (#226) * Authenticate on pulls from Docker Hub (#231) * Add support for callback graph improvements and timing (#224) * Update CHANGELOG.md * 189 - Add Pattern Matching Callbacks for Dash R (#228) * Testing initial implementation * More testing * Callback Context Updates * Updating callback context logic * Fixing callback returns * Adding callback args conditional * Cleanup and additional changes to callback value conditionals * Comment cleanup * Added PMC callback validation, removed unnecessary code * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added build to gitignore * Updated dependencies.R * Update boilerplate docs and add wildcard symbols * Drying up validation code and applying symbol logic * Update test to use symbols * Cleaned up code and added allsmaller test example * Cleaning up redundant code * Update FUNDING.yml * Updated callback_args logic and example * Adding basic unittests, updated validation * Fixed response for MATCH callbacks * Added integration test and updated examples for docs * Added additional integration test * Formatting and cleanup * update docs * Update to-do app * Add comments to examples * Change empy vector to character type. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update boilerplate text. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Removed triple colon syntax * Use seq_along and remove unnecessary unittest * Update CHANGELOG.md * Update CHANGELOG.md * Add support for arbitrary and sorted keys * Whitespace deleted * Added integration tests * Fixing test output * Fixing flakiness * Update test_pattern_matching.py * Update test_pattern_matching.py * Updating boilerplate text and test with generalized keys * Minor test fixes Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> * Fixing Null error with glue::glue interpolation (#233) * Fixing NULL error with glue interpolation * Update utils.R * Update utils.R * Update CHANGELOG.md * Update dash-renderer to v1.8.2 (#234) * bump dash-renderer to v1.8.2 * Update CHANGELOG.md * add note about update to dash-renderer * Fixing flaky test * bump package version to v0.8.0 * Update R/dash.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update DESCRIPTION Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add PMC example * update documentation * update CHANGELOG release date * 🔨 PMC docs refactor * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add import of glue * add glue to imports.R * fix line length issue * Fix setCallbackContext for wildcard and ordinary inputs (#237) * Update setCallbackContext * Adding graphs test * Slight fix * bump version and update CHANGELOG * Less flaky test Co-authored-by: rpkyle <ryan@plotly.com> * bump dependency versions * update CHANGELOG * update dash-renderer to v1.8.3 * update CHANGELOG * Favicon fix (#240) * Adding default favicon * Removing redundant codeblock * Added default favicon * Minor fix to requests prefix * Update CHANGELOG.md Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added simple test * Fixed typo * Fixed typo Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Remove context reference from CircleCI (#241) * Dash R Core Package Unification (#243) * Initialize npm and gulpfile in repo * Adding directory structure * Initial implementation of unification script * Minor grep fixes * Fixed DESCRIPTION imports * Added updated dash-table deps * Regex for version numbers * Cut import entries from NAMESPACE * Remove && include(dashr) * Removing gulp-asset artifacts and rebuilding complete package * Removing unnecessary files * fix: remove html, core pkgs from tests * fix: update script tags unit test * Revert R6 import * Add temporary collate * Update README examples * Scrubbing imports * More import scrubbing * Package development updates * Update gitignore and namespace * Updated gulpfile jobs * Updated all dependencies * Added templates for namespace/internal exports * Update internal, namespace, and gulpfile cleanup * Fix dependency sourcing * Linting * Adding job for asset retrieval and deletion * Minor src change * Added error handling * Fixing favicon bug * chore: use shallow clone Co-authored-by: Ryan Patrick Kyle <ryan@plotly.com> * Added deprecation warning if dcc, html, or table packages are attached (#249) * Added deprecation warning * Update R/dash.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update `highlight.js` dependency for dash-table (#262) * Updating gulpfile * Updating dependencies for dash components * Updated highlight.js dependency source * Add Dash 2 layout syntax wrappers and html tags (#265) * Added add_meta helper * Add helper functions and export pipe * Adding in tags wrapper * Updating ci config * Updated CHANGELOG * Updated circleci to include rust package manager (cargo). * Removed dashr command in circleci config. * Updating changelog * added basic test * Cleaning up Dash 2 references and duplication * Updated documentation * Allow conditional UI * Add meta tag check * More cleanup * Last bit of cleanup Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com> * Fix suppress_callback_exceptions config (#268) * Add config key * Fixing CI * Simplified callback syntax and addtional utility functions (#270) * Tag updates * Added RStudio dash snippet * Added simple_table * Added flexible callbacks * Documentation and NAMESPACE updates * Updated DESCRIPTION * Adding unittests * Adding context tags to tests * Updated CHANGELOG * Update monorepo and rebuild package (#271) * Updating gulpfile and package.json * More package.json and linting updates * Adding in simplified callback updates/tests * Import fixes * Updating package.json * Gulpfile script changes * Gulpfile updates * Rebuilding package with monorepo updates * Re-running test * Updating unittest * Updating test dependencies * Updating DESCRIPTION and .Rbuildignore forchecks * Updating function descriptions and NAMESPACE imports * Fixed examples and updated docs * Updating version * Remove references to dash namespace within package * Update testthat and remove deprecated context calls * Removed fixup_metadata.R * Removing more dash namespace references * Concatenating component function files * Updating checks * Merging components into package R files * Fixing check * More package cleanup * testthat 3.0.0 * Rebuilding package * Fixed conditional for multiple outputs * Fix no_update test * Fixing callback_instrumentation test * Fixing unit test * Added DBC to Dash R package (#273) * Adding dbc to dashR namespace * updated gitignore * Adding dbc docs and updating gulpfile * Updating test with dbc * Moved misc tests and added dbc snapshot * Fixing test * fixing id * Fixed export and test * Reverting sorted prop order * Checks updates * Re-running test Co-authored-by: Ryan Patrick Kyle <ryan@plot.ly> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com>
* contribute test script * remove version updating in DESCRIPTION * fix EOL Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Add support for user-defined server routes (#225) * Provide support for script and stylesheet attributes (#226) * Authenticate on pulls from Docker Hub (#231) * Add support for callback graph improvements and timing (#224) * Update CHANGELOG.md * 189 - Add Pattern Matching Callbacks for Dash R (#228) * Testing initial implementation * More testing * Callback Context Updates * Updating callback context logic * Fixing callback returns * Adding callback args conditional * Cleanup and additional changes to callback value conditionals * Comment cleanup * Added PMC callback validation, removed unnecessary code * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added build to gitignore * Updated dependencies.R * Update boilerplate docs and add wildcard symbols * Drying up validation code and applying symbol logic * Update test to use symbols * Cleaned up code and added allsmaller test example * Cleaning up redundant code * Update FUNDING.yml * Updated callback_args logic and example * Adding basic unittests, updated validation * Fixed response for MATCH callbacks * Added integration test and updated examples for docs * Added additional integration test * Formatting and cleanup * update docs * Update to-do app * Add comments to examples * Change empy vector to character type. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update boilerplate text. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Removed triple colon syntax * Use seq_along and remove unnecessary unittest * Update CHANGELOG.md * Update CHANGELOG.md * Add support for arbitrary and sorted keys * Whitespace deleted * Added integration tests * Fixing test output * Fixing flakiness * Update test_pattern_matching.py * Update test_pattern_matching.py * Updating boilerplate text and test with generalized keys * Minor test fixes Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> * Fixing Null error with glue::glue interpolation (#233) * Fixing NULL error with glue interpolation * Update utils.R * Update utils.R * Update CHANGELOG.md * Update dash-renderer to v1.8.2 (#234) * bump dash-renderer to v1.8.2 * Update CHANGELOG.md * add note about update to dash-renderer * Fixing flaky test * bump package version to v0.8.0 * Update R/dash.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update DESCRIPTION Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add PMC example * update documentation * update CHANGELOG release date * 🔨 PMC docs refactor * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add import of glue * add glue to imports.R * fix line length issue * Fix setCallbackContext for wildcard and ordinary inputs (#237) * Update setCallbackContext * Adding graphs test * Slight fix * bump version and update CHANGELOG * Less flaky test Co-authored-by: rpkyle <ryan@plotly.com> * bump dependency versions * update CHANGELOG * update dash-renderer to v1.8.3 * update CHANGELOG * Favicon fix (#240) * Adding default favicon * Removing redundant codeblock * Added default favicon * Minor fix to requests prefix * Update CHANGELOG.md Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added simple test * Fixed typo * Fixed typo Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Remove context reference from CircleCI (#241) * Dash R Core Package Unification (#243) * Initialize npm and gulpfile in repo * Adding directory structure * Initial implementation of unification script * Minor grep fixes * Fixed DESCRIPTION imports * Added updated dash-table deps * Regex for version numbers * Cut import entries from NAMESPACE * Remove && include(dashr) * Removing gulp-asset artifacts and rebuilding complete package * Removing unnecessary files * fix: remove html, core pkgs from tests * fix: update script tags unit test * Revert R6 import * Add temporary collate * Update README examples * Scrubbing imports * More import scrubbing * Package development updates * Update gitignore and namespace * Updated gulpfile jobs * Updated all dependencies * Added templates for namespace/internal exports * Update internal, namespace, and gulpfile cleanup * Fix dependency sourcing * Linting * Adding job for asset retrieval and deletion * Minor src change * Added error handling * Fixing favicon bug * chore: use shallow clone Co-authored-by: Ryan Patrick Kyle <ryan@plotly.com> * Added deprecation warning if dcc, html, or table packages are attached (#249) * Added deprecation warning * Update R/dash.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update `highlight.js` dependency for dash-table (#262) * Updating gulpfile * Updating dependencies for dash components * Updated highlight.js dependency source * Add Dash 2 layout syntax wrappers and html tags (#265) * Added add_meta helper * Add helper functions and export pipe * Adding in tags wrapper * Updating ci config * Updated CHANGELOG * Updated circleci to include rust package manager (cargo). * Removed dashr command in circleci config. * Updating changelog * added basic test * Cleaning up Dash 2 references and duplication * Updated documentation * Allow conditional UI * Add meta tag check * More cleanup * Last bit of cleanup Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com> * Fix suppress_callback_exceptions config (#268) * Add config key * Fixing CI * Simplified callback syntax and addtional utility functions (#270) * Tag updates * Added RStudio dash snippet * Added simple_table * Added flexible callbacks * Documentation and NAMESPACE updates * Updated DESCRIPTION * Adding unittests * Adding context tags to tests * Updated CHANGELOG * Update monorepo and rebuild package (#271) * Updating gulpfile and package.json * More package.json and linting updates * Adding in simplified callback updates/tests * Import fixes * Updating package.json * Gulpfile script changes * Gulpfile updates * Rebuilding package with monorepo updates * Re-running test * Updating unittest * Updating test dependencies * Updating DESCRIPTION and .Rbuildignore forchecks * Updating function descriptions and NAMESPACE imports * Fixed examples and updated docs * Updating version * Remove references to dash namespace within package * Update testthat and remove deprecated context calls * Removed fixup_metadata.R * Removing more dash namespace references * Concatenating component function files * Updating checks * Merging components into package R files * Fixing check * More package cleanup * testthat 3.0.0 * Rebuilding package * Fixed conditional for multiple outputs * Fix no_update test * Fixing callback_instrumentation test * Fixing unit test * Added DBC to Dash R package (#273) * Adding dbc to dashR namespace * updated gitignore * Adding dbc docs and updating gulpfile * Updating test with dbc * Moved misc tests and added dbc snapshot * Fixing test * fixing id * Fixed export and test * Reverting sorted prop order * Checks updates * Re-running test * Remove html exports and update tags (#274) * Updating tags and html exports * Re-running tests * Updating tag generation * Re-running tests * Updating tests to use new html list syntax * Adjusting tests * Re-run tests again * Updating tests * Wrapping up test fixes * Percy test Co-authored-by: Ryan Patrick Kyle <ryan@plot.ly> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com>
* contribute test script * remove version updating in DESCRIPTION * fix EOL Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Add support for user-defined server routes (#225) * Provide support for script and stylesheet attributes (#226) * Authenticate on pulls from Docker Hub (#231) * Add support for callback graph improvements and timing (#224) * Update CHANGELOG.md * 189 - Add Pattern Matching Callbacks for Dash R (#228) * Testing initial implementation * More testing * Callback Context Updates * Updating callback context logic * Fixing callback returns * Adding callback args conditional * Cleanup and additional changes to callback value conditionals * Comment cleanup * Added PMC callback validation, removed unnecessary code * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update R/dependencies.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added build to gitignore * Updated dependencies.R * Update boilerplate docs and add wildcard symbols * Drying up validation code and applying symbol logic * Update test to use symbols * Cleaned up code and added allsmaller test example * Cleaning up redundant code * Update FUNDING.yml * Updated callback_args logic and example * Adding basic unittests, updated validation * Fixed response for MATCH callbacks * Added integration test and updated examples for docs * Added additional integration test * Formatting and cleanup * update docs * Update to-do app * Add comments to examples * Change empy vector to character type. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update boilerplate text. Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update wildcards_test.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Removed triple colon syntax * Use seq_along and remove unnecessary unittest * Update CHANGELOG.md * Update CHANGELOG.md * Add support for arbitrary and sorted keys * Whitespace deleted * Added integration tests * Fixing test output * Fixing flakiness * Update test_pattern_matching.py * Update test_pattern_matching.py * Updating boilerplate text and test with generalized keys * Minor test fixes Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> * Fixing Null error with glue::glue interpolation (#233) * Fixing NULL error with glue interpolation * Update utils.R * Update utils.R * Update CHANGELOG.md * Update dash-renderer to v1.8.2 (#234) * bump dash-renderer to v1.8.2 * Update CHANGELOG.md * add note about update to dash-renderer * Fixing flaky test * bump package version to v0.8.0 * Update R/dash.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/testthat/test-wildcards.R Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update DESCRIPTION Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add PMC example * update documentation * update CHANGELOG release date * 🔨 PMC docs refactor * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * Update tests/integration/callbacks/test_pattern_matching.py Co-authored-by: HammadTheOne <30986043+HammadTheOne@users.noreply.github.com> * add import of glue * add glue to imports.R * fix line length issue * Fix setCallbackContext for wildcard and ordinary inputs (#237) * Update setCallbackContext * Adding graphs test * Slight fix * bump version and update CHANGELOG * Less flaky test Co-authored-by: rpkyle <ryan@plotly.com> * bump dependency versions * update CHANGELOG * update dash-renderer to v1.8.3 * update CHANGELOG * Favicon fix (#240) * Adding default favicon * Removing redundant codeblock * Added default favicon * Minor fix to requests prefix * Update CHANGELOG.md Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Added simple test * Fixed typo * Fixed typo Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Remove context reference from CircleCI (#241) * Dash R Core Package Unification (#243) * Initialize npm and gulpfile in repo * Adding directory structure * Initial implementation of unification script * Minor grep fixes * Fixed DESCRIPTION imports * Added updated dash-table deps * Regex for version numbers * Cut import entries from NAMESPACE * Remove && include(dashr) * Removing gulp-asset artifacts and rebuilding complete package * Removing unnecessary files * fix: remove html, core pkgs from tests * fix: update script tags unit test * Revert R6 import * Add temporary collate * Update README examples * Scrubbing imports * More import scrubbing * Package development updates * Update gitignore and namespace * Updated gulpfile jobs * Updated all dependencies * Added templates for namespace/internal exports * Update internal, namespace, and gulpfile cleanup * Fix dependency sourcing * Linting * Adding job for asset retrieval and deletion * Minor src change * Added error handling * Fixing favicon bug * chore: use shallow clone Co-authored-by: Ryan Patrick Kyle <ryan@plotly.com> * Added deprecation warning if dcc, html, or table packages are attached (#249) * Added deprecation warning * Update R/dash.R Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> * Update `highlight.js` dependency for dash-table (#262) * Updating gulpfile * Updating dependencies for dash components * Updated highlight.js dependency source * Add Dash 2 layout syntax wrappers and html tags (#265) * Added add_meta helper * Add helper functions and export pipe * Adding in tags wrapper * Updating ci config * Updated CHANGELOG * Updated circleci to include rust package manager (cargo). * Removed dashr command in circleci config. * Updating changelog * added basic test * Cleaning up Dash 2 references and duplication * Updated documentation * Allow conditional UI * Add meta tag check * More cleanup * Last bit of cleanup Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com> * Fix suppress_callback_exceptions config (#268) * Add config key * Fixing CI * Simplified callback syntax and addtional utility functions (#270) * Tag updates * Added RStudio dash snippet * Added simple_table * Added flexible callbacks * Documentation and NAMESPACE updates * Updated DESCRIPTION * Adding unittests * Adding context tags to tests * Updated CHANGELOG * Update monorepo and rebuild package (#271) * Updating gulpfile and package.json * More package.json and linting updates * Adding in simplified callback updates/tests * Import fixes * Updating package.json * Gulpfile script changes * Gulpfile updates * Rebuilding package with monorepo updates * Re-running test * Updating unittest * Updating test dependencies * Updating DESCRIPTION and .Rbuildignore forchecks * Updating function descriptions and NAMESPACE imports * Fixed examples and updated docs * Updating version * Remove references to dash namespace within package * Update testthat and remove deprecated context calls * Removed fixup_metadata.R * Removing more dash namespace references * Concatenating component function files * Updating checks * Merging components into package R files * Fixing check * More package cleanup * testthat 3.0.0 * Rebuilding package * Fixed conditional for multiple outputs * Fix no_update test * Fixing callback_instrumentation test * Fixing unit test * Added DBC to Dash R package (#273) * Adding dbc to dashR namespace * updated gitignore * Adding dbc docs and updating gulpfile * Updating test with dbc * Moved misc tests and added dbc snapshot * Fixing test * fixing id * Fixed export and test * Reverting sorted prop order * Checks updates * Re-running test * Remove html exports and update tags (#274) * Updating tags and html exports * Re-running tests * Updating tag generation * Re-running tests * Updating tests to use new html list syntax * Adjusting tests * Re-run tests again * Updating tests * Wrapping up test fixes * Percy test * CRAN submission updates * Fix callback outputs with short ID's (#280) * CRAN submission updates * Callback output ID validation fixes * Updating duplicate callbacks test * Security updates * Update R/utils.R Co-authored-by: Dean Attali <dean@attalitech.com> * Updating error message Co-authored-by: Dean Attali <dean@attalitech.com> * Updating README link Co-authored-by: Ryan Patrick Kyle <ryan@plot.ly> Co-authored-by: Ryan Patrick Kyle <rpkyle@users.noreply.github.com> Co-authored-by: Nicolas Kruchten <nicolas@plot.ly> Co-authored-by: rpkyle <ryan@plotly.com> Co-authored-by: Steve Sperandeo <steve.sperandeo@gmail.com> Co-authored-by: Dean Attali <dean@attalitech.com>
This PR addresses plotly/dash-core#283 by introducing a
gulpfile
based script in the root directory of thedashr
repo. This script sources fromgulp-assets
, which contains the main, updated, R export files from the respective core packages (dash-core-components, dash-html-components, and dash-table).Running the
npm unify
command executes a series of tasks which incorporate the core package dependencies and NAMESPACE exports to thedash
package, in preparation for a CRAN release. Running thenpm clean
command restores these dependencies so that the package can be used independently off of GIthub with the other core packages.unify
.Rscript -e 'devtools::document()'
to populate documentation help index.gulp-assets
to reduce package size until needed.dcc
andhtml
to remove library imports from vignettes and examples.Closes plotly/dash-core#283.