-
Notifications
You must be signed in to change notification settings - Fork 24
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
🐍 Add a .pyi
file for integration with type checking, documentation, and IDE auto-completion
#604
base: main
Are you sure you want to change the base?
Conversation
…hon typing interface
…r consistency. Analogously for `volume`.
Signed-off-by: GitHub Actions <[email protected]>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #604 +/- ##
=======================================
Coverage 98.11% 98.12%
=======================================
Files 232 232
Lines 35410 35411 +1
Branches 1691 1691
=======================================
+ Hits 34744 34747 +3
+ Misses 664 662 -2
Partials 2 2
... and 2 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
# Conflicts: # bindings/mnt/pyfiction/__init__.py # bindings/mnt/pyfiction/test/layouts/test_coordinates.py
d38011d
to
ac2039e
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.
clang-tidy made some suggestions
@@ -12,28 +12,29 @@ | |||
|
|||
#include <pybind11/pybind11.h> | |||
|
|||
namespace pyfiction | |||
{ | |||
#include <sstream> | |||
|
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.
warning: included header sstream is not used directly [misc-include-cleaner]
@@ -5,7 +5,6 @@ | |||
#ifndef PYFICTION_LOGIC_SIMULATION_HPP | |||
#define PYFICTION_LOGIC_SIMULATION_HPP | |||
|
|||
#include "pyfiction/documentation.hpp" | |||
#include "pyfiction/types.hpp" |
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.
warning: 'pyfiction/types.hpp' file not found [clang-diagnostic-error]
#include "pyfiction/types.hpp"
^
@@ -8,7 +8,8 @@ | |||
#include "pyfiction/types.hpp" |
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.
warning: 'pyfiction/types.hpp' file not found [clang-diagnostic-error]
#include "pyfiction/types.hpp"
^
@@ -8,7 +8,8 @@ | |||
#include "pyfiction/types.hpp" | |||
|
|||
#include <pybind11/pybind11.h> | |||
#include <pybind11/stl.h> | |||
|
|||
#include <cstdint> | |||
|
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.
warning: included header cstdint is not used directly [misc-include-cleaner]
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.
clang-tidy made some suggestions
@@ -14,12 +14,18 @@ | |||
#include <pybind11/pybind11.h> | |||
#include <pybind11/stl.h> | |||
|
|||
#include <cstdint> | |||
|
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.
warning: included header cstdint is not used directly [misc-include-cleaner]
#include <cstdint> | ||
|
||
#include << stdexcept> | ||
|
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.
warning: included header stdexcept is not used directly [misc-include-cleaner]
@@ -6,7 +6,6 @@ | |||
#define PYFICTION_OCCUPATION_PROBABILITY_OF_EXCITED_STATES_HPP | |||
|
|||
#include "pyfiction/documentation.hpp" |
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.
warning: 'pyfiction/documentation.hpp' file not found [clang-diagnostic-error]
#include "pyfiction/documentation.hpp"
^
#include "pyfiction/types.hpp" | ||
|
||
#include <fiction/utils/layout_utils.hpp> | ||
#include <fiction/utils/version_info.hpp.in> | ||
|
||
#include <pybind11/pybind11.h> |
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.
warning: 'pybind11/pybind11.h' file not found [clang-diagnostic-error]
#include <pybind11/pybind11.h>
^
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.
clang-tidy made some suggestions
@@ -14,12 +14,17 @@ | |||
#include <pybind11/pybind11.h> | |||
#include <pybind11/stl.h> | |||
|
|||
#include <cstdint> | |||
#include <stdexcept> |
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.
warning: included header cstdint is not used directly [misc-include-cleaner]
#include <stdexcept> | |
#include <stdexcept> |
@@ -8,12 +8,10 @@ | |||
#include "pyfiction/documentation.hpp" |
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.
warning: 'pyfiction/documentation.hpp' file not found [clang-diagnostic-error]
#include "pyfiction/documentation.hpp"
^
@@ -8,12 +8,10 @@ | |||
#include "pyfiction/documentation.hpp" | |||
#include "pyfiction/types.hpp" | |||
|
|||
#include <fiction/traits.hpp> | |||
#include <fiction/utils/layout_utils.hpp> |
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.
warning: included header traits.hpp is not used directly [misc-include-cleaner]
#include <fiction/utils/layout_utils.hpp> | |
#include <fiction/utils/layout_utils.hpp> |
…ng interface (still a long way to go)
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.
clang-tidy made some suggestions
#include <pybind11/pybind11.h> | ||
#include <pybind11/stl.h> | ||
|
||
#include <string> | ||
#include <optional> | ||
|
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.
warning: included header optional is not used directly [misc-include-cleaner]
@@ -11,7 +11,8 @@ | |||
#include <fiction/algorithms/simulation/sidb/time_to_solution.hpp> | |||
|
|||
#include <pybind11/pybind11.h> | |||
#include <pybind11/stl.h> | |||
|
|||
#include <sstream> | |||
|
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.
warning: included header sstream is not used directly [misc-include-cleaner]
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.
clang-tidy made some suggestions
@@ -8,7 +8,6 @@ | |||
#include "pyfiction/documentation.hpp" |
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.
warning: 'pyfiction/documentation.hpp' file not found [clang-diagnostic-error]
#include "pyfiction/documentation.hpp"
^
Description
This PR adds a
.pyi
file that defines a type interface for all pyfiction classes and functions. This helps with integration with type checking, documentation, and IDE auto-completion.Checklist: