python312Packages.textual: 2.1.2 -> 3.1.0 (#398096)
This commit is contained in:
@@ -63,6 +63,11 @@ python3Packages.buildPythonApplication rec {
|
||||
disabledTestPaths = [
|
||||
# Very time-consuming and some tests fails (performance-related?)
|
||||
"tests/integration/test_main.py"
|
||||
|
||||
# AssertionError since textual was updated to 3.1.0
|
||||
# https://github.com/bloomberg/memray/issues/750
|
||||
"tests/unit/test_tree_reporter.py"
|
||||
"tests/unit/test_tui_reporter.py"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
# tests
|
||||
pytestCheckHook,
|
||||
pytest-asyncio,
|
||||
tree-sitter-python,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
@@ -46,17 +47,27 @@ buildPythonPackage rec {
|
||||
nativeCheckInputs = [
|
||||
pytestCheckHook
|
||||
pytest-asyncio
|
||||
tree-sitter-python
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "textual_textarea" ];
|
||||
|
||||
disabledTestPaths = [
|
||||
pytestFlagsArray = [
|
||||
# "--deselect=tests/functional_tests/test_comments.py::test_comments[sql--- ]"
|
||||
];
|
||||
|
||||
disabledTests = [
|
||||
# Requires unpackaged tree-sitter-sql
|
||||
# textual.widgets._text_area.LanguageDoesNotExist
|
||||
"test_comments"
|
||||
|
||||
# AssertionError: assert Selection(sta...), end=(0, 6)) == Selection(sta...), end=(1, 0))
|
||||
# https://github.com/tconbeer/textual-textarea/issues/296
|
||||
"tests/functional_tests/test_textarea.py"
|
||||
"test_keys"
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "A text area (multi-line input) with syntax highlighting for Textual";
|
||||
description = "Text area (multi-line input) with syntax highlighting for Textual";
|
||||
homepage = "https://github.com/tconbeer/textual-textarea";
|
||||
changelog = "https://github.com/tconbeer/textual-textarea/releases/tag/v${version}";
|
||||
license = lib.licenses.mit;
|
||||
|
||||
@@ -23,18 +23,20 @@
|
||||
pytestCheckHook,
|
||||
syrupy,
|
||||
time-machine,
|
||||
tree-sitter-markdown,
|
||||
tree-sitter-python,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "textual";
|
||||
version = "2.1.2";
|
||||
version = "3.1.0";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Textualize";
|
||||
repo = "textual";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-VKo1idLu5sYGtuK8yZzVE6QrrMOciYIesbGVlqzNjfk=";
|
||||
hash = "sha256-JBqzaSsLSCzUYdIjlPZdPJlRKrqtWWPqJPp85uMcMLc=";
|
||||
};
|
||||
|
||||
build-system = [ poetry-core ];
|
||||
@@ -63,33 +65,25 @@ buildPythonPackage rec {
|
||||
syrupy
|
||||
time-machine
|
||||
tree-sitter
|
||||
tree-sitter-markdown
|
||||
tree-sitter-python
|
||||
];
|
||||
|
||||
disabledTestPaths = [
|
||||
# Snapshot tests require syrupy<4
|
||||
"tests/snapshot_tests/test_snapshots.py"
|
||||
|
||||
# Flaky: https://github.com/Textualize/textual/issues/5511
|
||||
# RuntimeError: There is no current event loop in thread 'MainThread'.
|
||||
"tests/test_focus.py"
|
||||
];
|
||||
|
||||
disabledTests = [
|
||||
# Assertion issues
|
||||
"test_textual_env_var"
|
||||
|
||||
# Requirements for tests are not quite ready
|
||||
"test_register_language"
|
||||
|
||||
# Requires python bindings for tree-sitter languages
|
||||
# https://github.com/Textualize/textual/issues/5449
|
||||
"test_setting_unknown_language"
|
||||
"test_update_highlight_query"
|
||||
];
|
||||
|
||||
# Some tests in groups require state from previous tests
|
||||
# See https://github.com/Textualize/textual/issues/4924#issuecomment-2304889067
|
||||
pytestFlagsArray = [ "--dist=loadgroup" ];
|
||||
pytestFlagsArray = [
|
||||
# Some tests in groups require state from previous tests
|
||||
# See https://github.com/Textualize/textual/issues/4924#issuecomment-2304889067
|
||||
"--dist=loadgroup"
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "textual" ];
|
||||
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
setuptools,
|
||||
tree-sitter,
|
||||
pytestCheckHook,
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "tree-sitter-markdown";
|
||||
version = "0.4.1";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "tree-sitter-grammars";
|
||||
repo = "tree-sitter-markdown";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-Oe2iL5b1Cyv+dK0nQYFNLCCOCe+93nojxt6ukH2lEmU=";
|
||||
};
|
||||
|
||||
build-system = [
|
||||
setuptools
|
||||
];
|
||||
|
||||
optional-dependencies = {
|
||||
core = [
|
||||
tree-sitter
|
||||
];
|
||||
};
|
||||
|
||||
pythonImportsCheck = [ "tree_sitter_markdown" ];
|
||||
|
||||
nativeCheckInputs = [
|
||||
pytestCheckHook
|
||||
tree-sitter
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "Markdown grammar for tree-sitter";
|
||||
homepage = "https://github.com/tree-sitter-grammars/tree-sitter-markdown";
|
||||
changelog = "https://github.com/tree-sitter-grammars/tree-sitter-markdown/releases/tag/v${version}";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ GaetanLepage ];
|
||||
};
|
||||
}
|
||||
@@ -17499,6 +17499,8 @@ self: super: with self; {
|
||||
|
||||
tree-sitter-make = callPackage ../development/python-modules/tree-sitter-make { };
|
||||
|
||||
tree-sitter-markdown = callPackage ../development/python-modules/tree-sitter-markdown { };
|
||||
|
||||
tree-sitter-python = callPackage ../development/python-modules/tree-sitter-python { };
|
||||
|
||||
tree-sitter-rust = callPackage ../development/python-modules/tree-sitter-rust { };
|
||||
|
||||
Reference in New Issue
Block a user