-
Notifications
You must be signed in to change notification settings - Fork 114
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
[KED-824] Adopt a new JSON format #2
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.
👍
package/kedro_viz/server.py
Outdated
@@ -21,7 +22,7 @@ def root(): | |||
|
|||
|
|||
@app.route("/logs/nodes.json") | |||
def nodes(): | |||
def nodes_old(): |
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.
Could we change the name to something like:
def nodes_old(): | |
def nodes_deprecated(): |
) | ||
all_tags.update(node.tags) | ||
for data_set in node.inputs: | ||
namespace = data_set.split("@")[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.
Is the term namespace
here the correct one? WDYT @LorenaBalanQB ?
package/tests/test_server.py
Outdated
@@ -10,12 +10,9 @@ | |||
|
|||
from kedro_viz import server | |||
|
|||
EXPECTED_PIPELINE_DATA = [ | |||
EXPECTED_PIPELINE_DATA_OLD = [ |
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.
⬆️ Same as the comment for nodes_old
.
@@ -49,6 +43,150 @@ | |||
] | |||
|
|||
|
|||
EXPECTED_PIPELINE_DATA = { |
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.
Is it possible to come up with a more minimalistic test case in order to be easier to change later?
package/tests/test_server.py
Outdated
@@ -146,9 +293,17 @@ def test_root_endpoint(client): | |||
assert "Kedro Viz" in response.data.decode() | |||
|
|||
|
|||
def test_nodes_endpoint(client): | |||
def test_old_nodes_endpoint(client): |
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.
⬆️
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.
LGTM! I left some comments. Could you please update PR context and tick the box?
@@ -21,7 +22,7 @@ def root(): | |||
|
|||
|
|||
@app.route("/logs/nodes.json") | |||
def nodes(): | |||
def nodes_deprecated(): |
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 want to throw deprecation warning for this in case users are confused between /api/nodes.json
and /logs/nodes.json
?
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.
users don't use this, the JS does, retaining the old one is purely so the Python and JS doesn't have to merge at the same time
parts = [n[0].upper() + n[1:] for n in name.split()] | ||
return " ".join(parts) | ||
|
||
pipeline = get_project_context("create_pipeline")() |
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.
What would happen if the passed pipeline is broken? Would it fail somewhere inside this function?
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.
it's up to the Pipeline constructor to ensure the constructed pipeline is valid
* Automating Release process (#1) * v6.3.6 * Revert "v6.3.6" This reverts commit 5ffe696. * v6.3.5 * testing release workflow-1 * testing release workflow-1 * testing release workflow-1 * Release/testing (#2) * v6.3.6 * Revert "v6.3.6" This reverts commit 5ffe696. * v6.3.5 * testing release workflow-1 * testing release workflow-1 * testing release workflow-1 * testing release workflow-1 * Release/testing (#3) * v6.3.6 * Revert "v6.3.6" This reverts commit 5ffe696. * v6.3.5 * testing release workflow-1 * testing release workflow-1 * testing release workflow-1 * testing release workflow-1 * final draft * update workflow config * Revert "Release/testing (#3)" This reverts commit d54180d. * merging main * reverting changes to main * final change to extract release notes * update contributing guide * modify Release doc * modify release guide and add release branch condition * fix PR comments
Signed-off-by: Sajid Alam <[email protected]>
* isPrettyName set default to false Signed-off-by: Sajid Alam <[email protected]> * debug Signed-off-by: Sajid Alam <[email protected]> * Update config.js Signed-off-by: Sajid Alam <[email protected]> * Update config.js Signed-off-by: Sajid Alam <[email protected]> * Update app.test.js Signed-off-by: Sajid Alam <[email protected]> * Update app.test.js Signed-off-by: Sajid Alam <[email protected]> * replace space with underscore Signed-off-by: Sajid Alam <[email protected]> * fix tests when pretty name is off by default Signed-off-by: Sajid Alam <[email protected]> * fix Signed-off-by: Sajid Alam <[email protected]> * Update index.js Signed-off-by: Sajid Alam <[email protected]> * more fixes Signed-off-by: Sajid Alam <[email protected]> * fix some failed tests that are related to the prettyName is off by default Signed-off-by: Huong Nguyen <huongg1409@gmail> * Add toLowerCase to some of the tests Signed-off-by: Huong Nguyen <huongg1409@gmail> * Update app.test.js Signed-off-by: Sajid Alam <[email protected]> * add cypress custom command to enable pretty name Signed-off-by: Sajid Alam <[email protected]> * Update commands.js Signed-off-by: Sajid Alam <[email protected]> * Update commands.js Signed-off-by: Sajid Alam <[email protected]> * Update global-toolbar.cy.js Signed-off-by: Sajid Alam <[email protected]> * beforeEach for isPrettyName added Signed-off-by: Jitendra Gundaniya <[email protected]> * menu test fix Signed-off-by: Jitendra Gundaniya <[email protected]> * Update experiment-tracking.cy.js Signed-off-by: Sajid Alam <[email protected]> * attempt #2 Signed-off-by: Sajid Alam <[email protected]> * attempt 3 Signed-off-by: Sajid Alam <[email protected]> * Test fix Signed-off-by: Jitendra Gundaniya <[email protected]> * Update experiment-tracking.cy.js Signed-off-by: Sajid Alam <[email protected]> * revert experiment tracking changes Signed-off-by: Sajid Alam <[email protected]> * Update experiment-tracking.cy.js Signed-off-by: Sajid Alam <[email protected]> * removed enablePrettyNames for exp tracking Signed-off-by: Jitendra Gundaniya <[email protected]> * test fix Signed-off-by: Jitendra Gundaniya <[email protected]> * remove redundant enableprettynames from several tests Signed-off-by: Sajid Alam <[email protected]> * revert removal of enableprettynames for several tests Signed-off-by: Sajid Alam <[email protected]> --------- Signed-off-by: Sajid Alam <[email protected]> Signed-off-by: Huong Nguyen <huongg1409@gmail> Signed-off-by: Jitendra Gundaniya <[email protected]> Co-authored-by: Huong Nguyen <huongg1409@gmail> Co-authored-by: Jitendra Gundaniya <[email protected]>
Notice
I acknowledge and agree that, by checking this box and clicking “Submit Pull Request”:
I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.
I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorised to submit this contribution on behalf of the original creator(s) or their licensees.
I certify that the use of this contribution as authorised by the Apache 2.0 license does not violate the intellectual property rights of anyone else.
Motivation and Context
Why was this PR created?
How has this been tested?
What testing strategies have you used?
Checklist
RELEASE.md
fileType
label to the PR