Skip to content

Conversation

@Vaishnavigupta1312
Copy link
Contributor

@Vaishnavigupta1312 Vaishnavigupta1312 commented Apr 7, 2025

  • This contribution adheres to CONTRIBUTING.md.

  • I've updated CHANGELOG.md if applicable.

  • [] I've added very basic system test applicable for this pull request.
    System tests are not added in this initial submission, will be adding in the subsequent PRs.

    • NI-RFSG is installed on nimibot but the 25.0 version of NI-RFSG doesn't include the session lock call implementation, we need 25.3 version release which is not aligned with the existing MI drivers' version.
      (These lock unlock APIs were already supported for MX devices and hence were already present in our dvl layer, RFSA_G just extended support to newer VST devices. )
    • For now excluded nirfsg from action workflows, to not run system tests for nirfsg.
    • Will have to wait for a newer release for all drivers.

What does this Pull Request accomplish?

It adds nirfsg module to the repo.

This PR :-

  • Code generation for many of the functions is turned off based on proposed api decisions and pending template updates.
  • Private and obsolete apis are removed in the internal tooling stage itself except for the private apis being called by other apis.
  • Adds nirfsg to Makefile, conf.py.mako, tox-travis.ini, tox.ini, docs/_static/about.inc, docs/_static/documentation.inc, docs/_static/installation.inc , README.rst, CHANGELOG.md
  • Generates APIs, and rst files for documentation for NI-RFSG
  • Documentation is not final, might require modifications.

List of Issues :-

No issues for the scope of these initial changes.

Testing done includes - successful tox build including nirfsg, looking at the rendered RTD pages, running an example with some of the generated apis.

@codecov-commenter
Copy link

codecov-commenter commented Apr 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.05%. Comparing base (8b52559) to head (cc31893).
Report is 1 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2089      +/-   ##
==========================================
+ Coverage   91.34%   92.05%   +0.71%     
==========================================
  Files          66       56      -10     
  Lines       16292    14670    -1622     
==========================================
- Hits        14882    13505    -1377     
+ Misses       1410     1165     -245     
Flag Coverage Δ
codegenunittests ?
nidcpowersystemtests 94.59% <ø> (+0.04%) ⬆️
nidcpowerunittests 89.53% <ø> (ø)
nidigitalsystemtests 92.26% <ø> (ø)
nidigitalunittests 68.44% <ø> (ø)
nidmmsystemtests 92.72% <ø> (ø)
nifakeunittests 87.24% <ø> (ø)
nifgensystemtests 94.86% <ø> (ø)
nimodinstsystemtests 73.85% <ø> (ø)
nimodinstunittests 94.20% <ø> (ø)
niscopesystemtests 92.94% <ø> (ø)
niscopeunittests 43.20% <ø> (ø)
nisesystemtests 91.50% <ø> (ø)
niswitchsystemtests 82.03% <ø> (ø)
nitclksystemtests 94.87% <ø> (ø)
nitclkunittests 98.26% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

see 11 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8b52559...cc31893. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ni-jfitzger
Copy link
Collaborator

We don't have NI-RFSG or NI-RFSA installed on nimibot, at the moment. That will need to happen before you can run your new system tests. Actually, at the moment, we need to release (or at least fake a release) just to get a new Windows build of nimibot (so that we use the latest version of the tests and don't run into gRPC Device Server port collisions).

@ni-jfitzger
Copy link
Collaborator

I believe we'll need to create a readthedocs project for nirsg and setup a webhook to get the documentation for nirfsg building. I can help with that when you're ready.

@Vaishnavigupta1312
Copy link
Contributor Author

Vaishnavigupta1312 commented Apr 8, 2025

We don't have NI-RFSG or NI-RFSA installed on nimibot, at the moment. That will need to happen before you can run your new system tests. Actually, at the moment, we need to release (or at least fake a release) just to get a new Windows build of nimibot (so that we use the latest version of the tests and don't run into gRPC Device Server port collisions).

I have raised a PR for the updates required to have nimibot support nirfsg in AzDO.

@Vaishnavigupta1312
Copy link
Contributor Author

Private and obsolete apis are not generated.

Private functions should not even be in the metadata. You need to filter them out in the NI-internal tooling.

We went with what MI drivers have in the metadata, they have private functions.
I will remove the private attributes to match what is present in MI.

@Vaishnavigupta1312
Copy link
Contributor Author

Code generation for many of the functions is turned off based on proposed api decisions and pending template updates.

I suggest you turn on code-generation to make sure the generator can handle their signatures, even if they are not in the shape that you'd want to ship them in.

The disabled ones are either which have been decided to be not supported in python or the ones that need template updates to enable. we disabled them for the first pass so that the pr doesn't get bloated. We will be enabling them in subsequent PRs along with necessary template updates so that there is no throw away work in any individual PR.

@ni-jfitzger
Copy link
Collaborator

Private and obsolete apis are not generated.

Private functions should not even be in the metadata. You need to filter them out in the NI-internal tooling.

We went with what MI drivers have in the metadata, they have private functions. I will remove the private attributes to match what is present in MI.

We do include private functions if they are called by other functions. For example, a fancy function will typically still call the function that it replaces and some functions, such as those used to return a size for something, may be used in the implementation of one or more public functions.

@Vaishnavigupta1312
Copy link
Contributor Author

Private and obsolete apis are not generated.

Private functions should not even be in the metadata. You need to filter them out in the NI-internal tooling.

We went with what MI drivers have in the metadata, they have private functions. I will remove the private attributes to match what is present in MI.

We do include private functions if they are called by other functions. For example, a fancy function will typically still call the function that it replaces and some functions, such as those used to return a size for something, may be used in the implementation of one or more public functions.

We are following the same by including only those private functions which are called by other functions.

Copy link
Collaborator

@ni-jfitzger ni-jfitzger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see nothing egregiously wrong here.
I did not review function, attribute or enum metadata or documentation and do not intend to do so.
Nor did I review the generated API in any great detail.

@ni-jfitzger
Copy link
Collaborator

travis-ci says we need to rerun codegen.

@ni-jfitzger ni-jfitzger self-requested a review April 25, 2025 18:57
@ni-jfitzger ni-jfitzger merged commit 9efe042 into ni:master Apr 26, 2025
35 checks passed
@Vaishnavigupta1312 Vaishnavigupta1312 deleted the users/vagupta/adding_rfsg_apis branch June 10, 2025 05:48
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

Successfully merging this pull request may close these issues.

4 participants