Skip to content
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

chore: add version.pyi in coffea 0.7.x #1262

Merged
merged 2 commits into from
Jan 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 2 additions & 10 deletions coffea/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,22 +27,14 @@
# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
from coffea._version import __version__
from . import _version
import re
import sys

__version__ = _version.__version__
version = __version__
version_info = tuple(re.split(r"[-\.]", __version__))


if sys.version_info.major < 3:
import warnings

warnings.warn("coffea only supports python3 as of 1 January 2020!")
warnings.warn(
"If you are using python2 and run into problems please submit a pull request to fix the issue!"
)

# control severity for utils.deprecate
deprecations_as_errors = False

Expand Down
4 changes: 4 additions & 0 deletions coffea/version.pyi
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
from __future__ import annotations

version: str
version_tuple: tuple[int, int, int] | tuple[int, int, int, str, str]