Skip to content

Conversation

@tholp
Copy link
Contributor

@tholp tholp commented Jul 24, 2023

@jeanas
Copy link
Contributor

jeanas commented Aug 14, 2023

CI is failing in tox -e check:

<class 'pygments.lexers.lisp.CommonLispLexer'> needs analyse_text, multiple lexers for *.cl

Co-authored-by: Jean Abou-Samra <[email protected]>
@tholp
Copy link
Contributor Author

tholp commented Aug 15, 2023

Common Lisp is not my language, but I believe that '^\s*(defun\s' will be a very good indicator for that language. I can add the rule if you like.

@jeanas
Copy link
Contributor

jeanas commented Aug 15, 2023

Yes, good.

@tholp
Copy link
Contributor Author

tholp commented Aug 15, 2023

Fixed

@jeanas
Copy link
Contributor

jeanas commented Aug 16, 2023

Please take a look at the test failures revealed by the CI.

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

Yes, thank you for your patience :-). I have successfully run 'py -m tox" now.

@Anteru
Copy link
Collaborator

Anteru commented Aug 16, 2023

Still failing CI. Can you try to run tox -e check locally first? Otherwise this will burn a few more trees before we get there ...

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

tox is not a stand alone command on my computer. And it does not appear to have a -e option. Running

py -m tox -- -c check

says:

...
................................................................................................................ [ 91%]
..............................................s................................................................. [ 94%]
.........................................................s.......................................... [ 96%]
tests\test_coffeescript.py .................... [ 96%]
tests\test_html_formatter_linenos_elements.py .................................................................. [ 98%]
.............................................................. [100%]

========================================== 4140 passed, 12 skipped in 19.35s ==========================================
.pkg: _exit> python C:\Users\puls\AppData\Roaming\Python\Python39\site-packages\pyproject_api_backend.py True setuptools.build_meta
py: OK (23.48=setup[3.48]+cmd[20.00] seconds)
congratulations :) (23.73 seconds)

Maybe it is one of the 12 skipped tests that should have failed.

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

Generated new _mapping.py files. Which unfortunately get line endings (and have to be corrected manually afterwards).

Anyways, now the out put from py -m tox - e check is:

$ py -m tox -e check
.pkg: _optional_hooks> python C:\Users\puls\AppData\Roaming\Python\Python39\site-packages\pyproject_api_backend.py True setuptools.build_meta
.pkg: get_requires_for_build_editable> python C:\Users\puls\AppData\Roaming\Python\Python39\site-packages\pyproject_api_backend.py True setuptools.build_meta
.pkg: build_editable> python C:\Users\puls\AppData\Roaming\Python\Python39\site-packages\pyproject_api_backend.py True setuptools.build_meta
check: install_package> python -I -m pip install --force-reinstall --no-deps C:_git-ext\pygments\src.tox.tmp\package\23\Pygments-2.15.1-0.editable-py3-none-any.whl
check: commands[0]> python scripts/check_crlf.py pygments external
check: commands[1]> python scripts/detect_missing_analyse_text.py --skip-no-aliases
check: commands[2]> flake8 --select F --ignore F401 pygments
Exception in thread Thread-1:
Traceback (most recent call last):
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\threading.py", line 954, in _bootstrap_inner
self.run()
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\threading.py", line 892, in run
self._target(*self._args, **self._kwargs)
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\multiprocessing\pool.py", line 519, in _handle_workers
cls._wait_for_updates(current_sentinels, change_notifier)
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\multiprocessing\pool.py", line 499, in _wait_for_updates
wait(sentinels, timeout=timeout)
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\multiprocessing\connection.py", line 884, in wait
ready_handles = _exhaustive_wait(waithandle_to_obj.keys(), timeout)
File "C:\Users\puls\AppData\Local\Programs\Python\Python39\lib\multiprocessing\connection.py", line 816, in _exhaustive_wait
res = _winapi.WaitForMultipleObjects(L, False, timeout)
ValueError: need at most 63 handles, got a sequence of length 66

And those errors are meaningless to me.

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

The tox command leaves 70 python.exe processes running.

Not being able to figure out how to run the "check" I have instead added a doc string with copyright.

And will (sorry) waste a couple of your trees.

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

I was able to run 'py -m tox -e check' on a computer with fewer processors (I think the number of processors makes influences the number of python processes that are spawned and 64 processors is probably too many (there was something about too many handles in the errors).

However on that computer the -e check succeeds even though it failed when I pushed it to git.

Tried once more hope this time will succeed (I hoped that the other times as well).

@jeanas
Copy link
Contributor

jeanas commented Aug 16, 2023

Can you check the "Allow edits and access to secrets by maintainers" checkbox in the right sidebar please? That way we can fix those issues for you.

@jeanas
Copy link
Contributor

jeanas commented Aug 16, 2023

Oh, actually I see that it's checked. Which is strange because

Enumerating objects: 35, done.
Counting objects: 100% (35/35), done.
Delta compression using up to 8 threads
Compressing objects: 100% (19/19), done.
Writing objects: 100% (19/19), 7.11 KiB | 2.37 MiB/s, done.
Total 19 (delta 11), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (11/11), completed with 9 local objects.
To github.com:tholp/pygments.git
 ! [remote rejected]   tholp/master -> tholp/master (permission denied)
error: failed to push some refs to 'github.com:tholp/pygments.git'

@jeanas jeanas closed this Aug 16, 2023
@jeanas jeanas reopened this Aug 16, 2023
@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

I am blank about the permission thing.

Also my test run says no errors:

check: commands[2]> flake8 --select F --ignore F401 pygments
check: commands[3]> python scripts/check_sources.py -i pygments/lexers/_mapping.py -i docs/_build -i pygments/formatters/_mapping.py -i pygments/unistring.py -i tests/support/empty.py
No errors found.
check: commands[4]> python scripts/count_token_references.py --minfiles=1 --maxfiles=1 --minlines=1 --maxlines=3 --subtoken

Anyways I figured out that the underlining was wrong length, and have fixed that also.

@tholp
Copy link
Contributor Author

tholp commented Aug 16, 2023

And finally the testsuite succeeded :-).

@tholp
Copy link
Contributor Author

tholp commented Aug 28, 2023

Is there any problems I have to deal with?

@jeanas
Copy link
Contributor

jeanas commented Aug 28, 2023 via email

@tholp
Copy link
Contributor Author

tholp commented Aug 28, 2023

Of, course. Have a nice vacation.

@jeanas jeanas merged commit a54ad08 into pygments:master Sep 1, 2023
@jeanas
Copy link
Contributor

jeanas commented Sep 1, 2023

Thank you.

@Anteru Anteru added the A-lexing area: changes to individual lexers label Nov 17, 2023
@Anteru Anteru added this to the 2.17 milestone Nov 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-lexing area: changes to individual lexers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants