Skip to content

Commit bd0913e

Browse files
authored
Fix tests (#1133)
* Fix traitlets warning * Fix failing pytest
1 parent 22bf2d3 commit bd0913e

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

jupyterlab_git/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class JupyterLabGit(Configurable):
3131
actions = Dict(
3232
help="Actions to be taken after a git command. Each action takes a list of commands to execute (strings). Supported actions: post_init",
3333
config=True,
34-
trait=List(
34+
value_trait=List(
3535
trait=Unicode(), help='List of commands to run. E.g. ["touch baz.py"]'
3636
)
3737
# TODO Validate

jupyterlab_git/git.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,8 +1350,9 @@ async def get_content(self, contents_manager, filename, path):
13501350
)
13511351
except tornado.web.HTTPError as error:
13521352
# Handle versioned file being deleted case
1353-
if error.status_code == 404 and error.log_message.startswith(
1354-
"No such file or directory: "
1353+
if error.status_code == 404 and (
1354+
error.log_message.startswith("No such file or directory: ")
1355+
or error.log_message.startswith("file or directory does not exist:")
13551356
):
13561357
return ""
13571358
raise error

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ install_requires =
2727
nbformat
2828
packaging
2929
pexpect
30+
traitlets~=5.0
3031
include_package_data = True
3132
zip_safe = False
3233
python_requires = >=3.6,<4

0 commit comments

Comments
 (0)