Bumps [jupyter-lsp](https://github.com/jupyter-lsp/jupyterlab-lsp) from
2.2.0 to 2.2.2.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/jupyter-lsp/jupyterlab-lsp/blob/main/CHANGELOG.md">jupyter-lsp's
changelog</a>.</em></p>
<blockquote>
<h3><code>jupyter-lsp 2.2.2</code></h3>
<ul>
<li>bug fixes:
<ul>
<li>address warning about renamed <code>extension_points</code> (<a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1035">#1035</a>)</li>
<li>fix compatibility with jupyter server 1.x</li>
<li>fix an authentication-related security vulnerability (see <a
href="https://github.com/jupyter-lsp/jupyterlab-lsp/security/advisories/GHSA-4qhp-652w-c22x">the
advisory</a> for details)</li>
</ul>
</li>
<li>enhancements:
<ul>
<li>add authorization support (<code>lsp</code> resource, jupyter-server
v2+ only) - this allows server operators for fine grained access
control, e.g. in case if specific users (such as guest or read-only
users) should not be allowed to access LSP; this is in addition to
authentication fixes</li>
</ul>
</li>
</ul>
<h3><code>@jupyter-lsp/jupyterlab-lsp 5.0.1</code></h3>
<ul>
<li>bug fixes:
<ul>
<li>fix false “undefined name” in <code>%%time</code> and
<code>%%capture</code> magics <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1007">#1007</a>
(thanks <a
href="https://github.com/i-aki-y"><code>@i-aki-y</code></a>!)</li>
<li>fix completion items for paths and other long items being cut off <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1025">#1025</a></li>
<li>workaround issue with markdown lost on edit <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1016">#1016</a></li>
<li>fix latex/Greek letters insertion and other completions which do not
match prefix (do not pre-filter completions from kernel) <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1022">#1022</a></li>
<li>fix completions in Console <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1023">#1023</a></li>
<li>fix customising <code>priority</code> after pre-setting it with
<code>overrides.json</code> <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1027">#1027</a></li>
<li>fix jump to definitions in a file inside root in Pyright on Windows
<a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1024">#1024</a></li>
<li>fix typos in setting title and help message <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/999">#999</a>
and <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1010">#1010</a></li>
</ul>
</li>
<li>maintenance:
<ul>
<li>fix bootstrap script <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1021">#1021</a></li>
<li>bump axios from 1.2.1 to 1.6.2 <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1019">#1019</a></li>
<li>bump <code>@babel/traverse</code> from 7.22.5 to 7.23.4 <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1020">#1020</a></li>
</ul>
</li>
</ul>
<h3><code>jupyter-lsp 2.2.1</code></h3>
<ul>
<li>bug fixes:
<ul>
<li>use <code>APIHandler</code> over <code>JupyterHandler</code> to get
CORS OPTIONS <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/952">#952</a>
(thanks <a
href="https://github.com/zhanba"><code>@zhanba</code></a>!)</li>
<li>use <code>shutil.which</code> to discover <code>npm</code>
executable on Windows (thanks <a
href="https://github.com/jameshurst"><code>@jameshurst</code></a>!)</li>
</ul>
</li>
<li>maintenance:
<ul>
<li>resolve traitlets type warnings, lint, remove six <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/1015">#1015</a></li>
<li>use <code>sys.executable</code> in stdio tests <a
href="https://redirect.github.com/jupyter-lsp/jupyterlab-lsp/issues/998">#998</a></li>
</ul>
</li>
</ul>
<h3><code>@jupyter-lsp/jupyterlab-lsp 5.0.0</code></h3>
<ul>
<li>enhancements:
<ul>
<li>uses toast notifications instead of messages on status bar</li>
<li>diagnostics panel will be re-opened on reload</li>
</ul>
</li>
<li>maintenance:
<ul>
<li>support JupyterLab 4</li>
<li>use upstream <code>@jupyterlab/lsp</code> package</li>
<li>use camelCase convention in TypeScript/JavaScript code</li>
<li>use <code>@codemirror/linter</code> to show diagnostics
<ul>
<li>this comes with a different style of underlines and custom
tooltips</li>
</ul>
</li>
</ul>
</li>
<li>known issues/limitations:
<ul>
<li>configuration of language servers via JSON Settings Editor may
result in a spurious warning
due to a transitive clash with settings from the UI editor when using
nested pattern (e.g.
<code>{pylsp: {flake8: {enabled: true}}}</code>); the dotted pattern
(e.g. <code>{"pylsp.flake8.enabled": true}</code>)
does not lead to such problem.</li>
</ul>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/jupyter-lsp/jupyterlab-lsp/commits">compare
view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/thu-ml/tianshou/network/alerts).
</details>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This makes several largely unrelated improvements in the high-level API
and in the README.
Main improvements in high-level API:
* Improve naming in trainer-related abstractions, moved some classes
from examples to the library
* Improve environment factory abstraction
* Some bug-fixes
Main changes in README:
* Add high-level example and update procedural/low-level example
* Improve language/wording
Bumps [jinja2](https://github.com/pallets/jinja) from 3.1.2 to 3.1.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/pallets/jinja/releases">jinja2's
releases</a>.</em></p>
<blockquote>
<h2>3.1.3</h2>
<p>This is a fix release for the 3.1.x feature branch.</p>
<ul>
<li>Fix for <a
href="https://github.com/pallets/jinja/security/advisories/GHSA-h5c8-rqwp-cp95">GHSA-h5c8-rqwp-cp95</a>.
You are affected if you are using <code>xmlattr</code> and passing user
input as attribute keys.</li>
<li>Changes: <a
href="https://jinja.palletsprojects.com/en/3.1.x/changes/#version-3-1-3">https://jinja.palletsprojects.com/en/3.1.x/changes/#version-3-1-3</a></li>
<li>Milestone: <a
href="https://github.com/pallets/jinja/milestone/15?closed=1">https://github.com/pallets/jinja/milestone/15?closed=1</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pallets/jinja/blob/main/CHANGES.rst">jinja2's
changelog</a>.</em></p>
<blockquote>
<h2>Version 3.1.3</h2>
<p>Released 2024-01-10</p>
<ul>
<li>Fix compiler error when checking if required blocks in parent
templates are
empty. :pr:<code>1858</code></li>
<li><code>xmlattr</code> filter does not allow keys with spaces.
GHSA-h5c8-rqwp-cp95</li>
<li>Make error messages stemming from invalid nesting of <code>{% trans
%}</code> blocks
more helpful. :pr:<code>1918</code></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d9de4bb215"><code>d9de4bb</code></a>
release version 3.1.3</li>
<li><a
href="50124e1656"><code>50124e1</code></a>
skip test pypi</li>
<li><a
href="9ea7222ef3"><code>9ea7222</code></a>
use trusted publishing</li>
<li><a
href="da703f7aae"><code>da703f7</code></a>
use trusted publishing</li>
<li><a
href="bce1746925"><code>bce1746</code></a>
use trusted publishing</li>
<li><a
href="7277d8068b"><code>7277d80</code></a>
update pre-commit hooks</li>
<li><a
href="5c8a105224"><code>5c8a105</code></a>
Make nested-trans-block exceptions nicer (<a
href="https://redirect.github.com/pallets/jinja/issues/1918">#1918</a>)</li>
<li><a
href="19a55db3b4"><code>19a55db</code></a>
Make nested-trans-block exceptions nicer</li>
<li><a
href="716795349a"><code>7167953</code></a>
Merge pull request from GHSA-h5c8-rqwp-cp95</li>
<li><a
href="7dd3680e6e"><code>7dd3680</code></a>
xmlattr filter disallows keys with spaces</li>
<li>Additional commits viewable in <a
href="https://github.com/pallets/jinja/compare/3.1.2...3.1.3">compare
view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/thu-ml/tianshou/network/alerts).
</details>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* EnvFactory now uses the creation of a single environment as
the basic functionality which the more high-level functions build
upon
* Introduce enum EnvMode to indicate the purpose for which an env
is created, allowing the factory creation process to change its
behaviour accordingly
* Add EnvFactoryGymnasium to provide direct support for envs that
can be created via gymnasium.make
- EnvPool is supported via an injectible EnvPoolFactory
- Existing EnvFactory implementations are now derived from
EnvFactoryGymnasium
* Use a separate environment (which uses new EnvMode.WATCH) for
watching agent performance after training (instead of using test
environments, which the user may want to configure differently)
This PR adds strict typing to the output of `update` and `learn` in all
policies. This will likely be the last large refactoring PR before the
next release (0.6.0, not 1.0.0), so it requires some attention. Several
difficulties were encountered on the path to that goal:
1. The policy hierarchy is actually "broken" in the sense that the keys
of dicts that were output by `learn` did not follow the same enhancement
(inheritance) pattern as the policies. This is a real problem and should
be addressed in the near future. Generally, several aspects of the
policy design and hierarchy might deserve a dedicated discussion.
2. Each policy needs to be generic in the stats return type, because one
might want to extend it at some point and then also extend the stats.
Even within the source code base this pattern is necessary in many
places.
3. The interaction between learn and update is a bit quirky, we
currently handle it by having update modify special field inside
TrainingStats, whereas all other fields are handled by learn.
4. The IQM module is a policy wrapper and required a
TrainingStatsWrapper. The latter relies on a bunch of black magic.
They were addressed by:
1. Live with the broken hierarchy, which is now made visible by bounds
in generics. We use type: ignore where appropriate.
2. Make all policies generic with bounds following the policy
inheritance hierarchy (which is incorrect, see above). We experimented a
bit with nested TrainingStats classes, but that seemed to add more
complexity and be harder to understand. Unfortunately, mypy thinks that
the code below is wrong, wherefore we have to add `type: ignore` to the
return of each `learn`
```python
T = TypeVar("T", bound=int)
def f() -> T:
return 3
```
3. See above
4. Write representative tests for the `TrainingStatsWrapper`. Still, the
black magic might cause nasty surprises down the line (I am not proud of
it)...
Closes#933
---------
Co-authored-by: Maximilian Huettenrauch <m.huettenrauch@appliedai.de>
Co-authored-by: Michael Panchenko <m.panchenko@appliedai.de>
- [X] I have added the correct label(s) to this Pull Request or linked
the relevant issue(s)
- [X] I have provided a description of the changes in this Pull Request
- [X] I have added documentation for my changes
- [ ] If applicable, I have added tests to cover my changes.
- [X] I have reformatted the code using `poe format`
- [X] I have checked style and types with `poe lint` and `poe
type-check`
- [ ] (Optional) I ran tests locally with `poe test`
(or a subset of them with `poe test-reduced`) ,and they pass
- [X] (Optional) I have tested that documentation builds correctly with
`poe doc-build`
Changes in this PR (see individual commits):
* Fix: SamplingConfig.start_timesteps_random was not used
* Environments: Support use of different test environment factory in
convenience constructors `from_factory*`
* SamplingConfig: Improve/extend docstrings, clearly explaining the
parameters
* SamplingConfig: Change default of repeat_per_collect to 1
* Improve logging
* Fix doc-build on Windows
Closes#916
This PR presents an overhaul of how the docs are built and presented
1. Notebooks are no longer just links in some drive. They are checked in
without their outputs, executed in CI, and thereby serve as integration
tests as well as tutorials. They have been adjusted to work with the
current master branch
2. Execution of notebooks is cached, so it's very fast
3. The api docs are generated automatically with a custom script.
Previously this was only done for the highlevel module
4. The build is happening with jupyter-book (which still uses sphinx in
the backend). It is using the default jupyter book theme, which I think
looks very nice and adds useful navigation to the right side of the
screen
5. Customized api docs rendering for better appearance
6. The toc of the docs is built automatically with jupyter-book. The api
docs generation script has been adjusted accordingly
7. The viewcode and linkcode extensions add source code and links to it
to the docs
8. A bunch of docstrings have been adjusted to better reflect the
configured rules
9. Several typing issues improved to make mypy happy
It was quite a piece of work, I hope you like the result :)