You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "vishnuprakaz (via GitHub)" <gi...@apache.org> on 2026/06/08 12:55:38 UTC

[PR] [python][test] Add unit tests for tool schema conversion utilities [flink-agents]

vishnuprakaz opened a new pull request, #815:
URL: https://github.com/apache/flink-agents/pull/815

   <!--
     * Thank you very much for contributing to Flink Agents.
     * Please add the relevant components in the PR title. E.g., [api], [runtime], [java], [python], [hotfix], etc.
     -->
   
     <!-- Please link the PR to the relevant issue(s). Hotfix doesn't need this. -->
     Linked issue: #814
   
     ### Purpose of change
   
     The four schema-conversion helpers in `api/tools/utils.py` (used by the
     Java/Python tool bridge) had no direct unit tests. This adds tests for them.
   
     ### Tests
   
     Added `python/flink_agents/api/tools/tests/test_utils.py` with 15 unit tests
     covering all four functions, including a round-trip test for the inverse pair.
     Locally `pytest` and `ruff check`check all pass.
   
     ### API
   
     No public API changes.
   
     ### Documentation
   
     <!-- Do not remove this section. Check the proper box only. -->
   
     - [ ] `doc-needed` <!-- Your PR changes impact docs -->
     - [x] `doc-not-needed` <!-- Your PR changes do not impact docs -->
     - [ ] `doc-included` <!-- Your PR already contains the necessary documentation updates -->


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [python][test] Add unit tests for tool schema conversion utilities [flink-agents]

Posted by "wenjin272 (via GitHub)" <gi...@apache.org>.
wenjin272 commented on code in PR #815:
URL: https://github.com/apache/flink-agents/pull/815#discussion_r3378253175


##########
python/flink_agents/api/tools/tests/__init__.py:
##########
@@ -0,0 +1,16 @@
+################################################################################
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# limitations under the License.

Review Comment:
   It looks like a line is missing here:
   ```
   #  See the License for the specific language governing permissions and
   # limitations under the License.
   ```



##########
python/flink_agents/api/tools/tests/test_utils.py:
##########
@@ -0,0 +1,220 @@
+################################################################################
+#  Licensed to the Apache Software Foundation (ASF) under one
+#  or more contributor license agreements.  See the NOTICE file
+#  distributed with this work for additional information
+#  regarding copyright ownership.  The ASF licenses this file
+#  to you under the Apache License, Version 2.0 (the
+#  "License"); you may not use this file except in compliance
+#  with the License.  You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+#  Unless required by applicable law or agreed to in writing, software
+#  distributed under the License is distributed on an "AS IS" BASIS,
+#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# limitations under the License.

Review Comment:
   ditto



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [python][test] Add unit tests for tool schema conversion utilities [flink-agents]

Posted by "wenjin272 (via GitHub)" <gi...@apache.org>.
wenjin272 commented on PR #815:
URL: https://github.com/apache/flink-agents/pull/815#issuecomment-4657023558

   > Actually I copied from other file, on looking the same line is missing in entire module plan/tools/bash/ (5 files) and runtime/skill/skill_tools.py.
   > 
   > Happy to fix those in a separate PR [hotfix] or open an issue first?
   
   Thank you for your thorough review. I think a separate PR [hotfix] will suffice.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [python][test] Add unit tests for tool schema conversion utilities [flink-agents]

Posted by "vishnuprakaz (via GitHub)" <gi...@apache.org>.
vishnuprakaz commented on PR #815:
URL: https://github.com/apache/flink-agents/pull/815#issuecomment-4656803771

   Thanks @wenjin272 for the review !  added the missing See the License… line to both files.
   
   Actually I copied from other file, on looking the same line is missing in entire module plan/tools/bash/ (5 files) and runtime/skill/skill_tools.py. 
    
   Happy to fix those in a separate PR [hotfix] or open an issue first?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [python][test] Add unit tests for tool schema conversion utilities [flink-agents]

Posted by "wenjin272 (via GitHub)" <gi...@apache.org>.
wenjin272 merged PR #815:
URL: https://github.com/apache/flink-agents/pull/815


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org