-
Notifications
You must be signed in to change notification settings - Fork 319
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
New "Configuration Parameter" #377
Comments
@AdriaanRol in terms of who will improve existing drivers, I think the answer is pretty boring: those who use them. In general it's hard to improve them without "feeling" the limitations they have. As for the configuration parameter, I kind of see what you mean but need to think about it a bit more! |
@giulioungaretti , It indeed makes sense to somehow link this to the driver. However seeing as this is a problem that is quite general (and will certainly show up more times) I don't think it makes sense to lock it in the inheritance structure of the instrument classes. That being said. Let me know when you've given it some more thought. |
@AdriaanRol We have now thought about this issue in the sense that we encountered the same situation in some drivers we wrote. For instance, the ZI UHF-LI sweeper needs to be configured (sweep start, sweep stop, number of points, filter bandwidth, etc.) before the Have you yourself thought more about this in the meantime? I don't really see the advantage of promoting this bookkeeping to the instrument class. What would the benefit be over what we can call the signal hound approach? |
4559: Update towncrier requirement from ~=21.9.0 to ~=22.8.0 r=jenshnielsen a=dependabot[bot] Updates the requirements on [towncrier](https://github.com/hawkowl/towncrier) to permit the latest version. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/hawkowl/towncrier/releases">towncrier's releases</a>.</em></p> <blockquote> <h2>Towncrier 22.8.0</h2> <h1>towncrier 22.8.0 (2022-08-29)</h1> <p>No significant changes since the previous release candidate.</p> <h1>towncrier 22.8.0.rc1 (2022-08-28)</h1> <h2>Features</h2> <ul> <li> <p>Make the check subcommand succeed for branches that change the news file</p> <p>This should enable the <code>check</code> subcommand to be used as a CI lint step and not fail when a pull request only modifies the configured news file (i.e. when the news file is being assembled for the next release). (<code>[#337](twisted/towncrier#337) <https://github.com/hawkowl/towncrier/issues/337></code>_)</p> </li> <li> <p>Added support to tables in toml settings, which provides a more intuitive way to configure custom types. (<code>[#369](twisted/towncrier#369) <https://github.com/hawkowl/towncrier/issues/369></code>_)</p> </li> <li> <p>The <code>towncrier create</code> command line now has a new <code>-m TEXT</code> argument that is used to define the content of the newly created fragment. (<code>[#374](twisted/towncrier#374) <https://github.com/hawkowl/towncrier/issues/374></code>_)</p> </li> </ul> <h2>Bugfixes</h2> <ul> <li> <p>The extra newline between the title and rendered content when using <code>--draft</code> is no longer inserted. (<code>[#105](twisted/towncrier#105) <https://github.com/hawkowl/towncrier/issues/105></code>_)</p> </li> <li> <p>The detection of duplicate release notes was fixed and recording changes of same version is no longer triggered.</p> <p>Support for having the release notes for each version in a separate file is working again. This is a regression introduced in VERSION 19.9.0rc1. (<code>[#391](twisted/towncrier#391) <https://github.com/hawkowl/towncrier/issues/391></code>_)</p> </li> </ul> <h2>Improved Documentation</h2> <ul> <li>Improve <code>CONTRIBUTING.rst</code> and add PR template. (<code>[#342](twisted/towncrier#342) <https://github.com/hawkowl/towncrier/issues/342></code>_)</li> <li>Move docs too the main branch and document custom fragment types. (<code>[#367](twisted/towncrier#367) <https://github.com/hawkowl/towncrier/issues/367></code>_)</li> <li>The CLI help messages were updated to contain more information. (<code>[#384](twisted/towncrier#384) <https://github.com/hawkowl/towncrier/issues/384></code>_)</li> </ul> <h2>Deprecations and Removals</h2> <ul> <li>Support for all Python versions older than 3.7 has been dropped. (<code>[#378](twisted/towncrier#378) <https://github.com/hawkowl/towncrier/issues/378></code>_)</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/twisted/towncrier/blob/trunk/NEWS.rst">towncrier's changelog</a>.</em></p> <blockquote> <h1>towncrier 22.8.0 (2022-08-29)</h1> <p>No significant changes since the previous release candidate.</p> <h1>towncrier 22.8.0.rc1 (2022-08-28)</h1> <h2>Features</h2> <ul> <li> <p>Make the check subcommand succeed for branches that change the news file</p> <p>This should enable the <code>check</code> subcommand to be used as a CI lint step and not fail when a pull request only modifies the configured news file (i.e. when the news file is being assembled for the next release). (<code>[#337](twisted/towncrier#337) <https://github.com/hawkowl/towncrier/issues/337></code>_)</p> </li> <li> <p>Added support to tables in toml settings, which provides a more intuitive way to configure custom types. (<code>[#369](twisted/towncrier#369) <https://github.com/hawkowl/towncrier/issues/369></code>_)</p> </li> <li> <p>The <code>towncrier create</code> command line now has a new <code>-m TEXT</code> argument that is used to define the content of the newly created fragment. (<code>[#374](twisted/towncrier#374) <https://github.com/hawkowl/towncrier/issues/374></code>_)</p> </li> </ul> <h2>Bugfixes</h2> <ul> <li> <p>The extra newline between the title and rendered content when using <code>--draft</code> is no longer inserted. (<code>[#105](twisted/towncrier#105) <https://github.com/hawkowl/towncrier/issues/105></code>_)</p> </li> <li> <p>The detection of duplicate release notes was fixed and recording changes of same version is no longer triggered.</p> <p>Support for having the release notes for each version in a separate file is working again. This is a regression introduced in VERSION 19.9.0rc1. (<code>[#391](twisted/towncrier#391) <https://github.com/hawkowl/towncrier/issues/391></code>_)</p> </li> </ul> <h2>Improved Documentation</h2> <ul> <li>Improve <code>CONTRIBUTING.rst</code> and add PR template. (<code>[#342](twisted/towncrier#342) <https://github.com/hawkowl/towncrier/issues/342></code>_)</li> <li>Move docs too the main branch and document custom fragment types. (<code>[#367](twisted/towncrier#367) <https://github.com/hawkowl/towncrier/issues/367></code>_)</li> <li>The CLI help messages were updated to contain more information. (<code>[#384](twisted/towncrier#384) <https://github.com/hawkowl/towncrier/issues/384></code>_)</li> </ul> <h2>Deprecations and Removals</h2> <ul> <li>Support for all Python versions older than 3.7 has been dropped. (<code>[#378](twisted/towncrier#378) <https://github.com/hawkowl/towncrier/issues/378></code>_)</li> </ul> <h2>Misc</h2> <ul> <li><code>[#292](twisted/towncrier#292) <https://github.com/hawkowl/towncrier/issues/292></code><em>, <code>[#330](twisted/towncrier#330) <https://github.com/hawkowl/towncrier/issues/330></code></em>, <code>[#366](twisted/towncrier#366) <https://github.com/hawkowl/towncrier/issues/366></code><em>, <code>[#376](twisted/towncrier#376) <https://github.com/hawkowl/towncrier/issues/376></code></em>, <code>[#377](twisted/towncrier#377) <https://github.com/hawkowl/towncrier/issues/377></code><em>, <code>[#380](twisted/towncrier#380) <https://github.com/hawkowl/towncrier/issues/380></code></em>, <code>[#381](twisted/towncrier#381) <https://github.com/hawkowl/towncrier/issues/381></code><em>, <code>[#382](twisted/towncrier#382) <https://github.com/hawkowl/towncrier/issues/382></code></em>, <code>[#383](twisted/towncrier#383) <https://github.com/hawkowl/towncrier/issues/383></code><em>, <code>[#393](twisted/towncrier#393) <https://github.com/hawkowl/towncrier/issues/393></code></em>, <code>[#399](twisted/towncrier#399) <https://github.com/hawkowl/towncrier/issues/399></code><em>, <code>[#402](twisted/towncrier#402) <https://github.com/hawkowl/towncrier/issues/402></code></em></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/twisted/towncrier/commit/411f2676b18daf9ba1eb656f7dc6c726397c4a9e"><code>411f267</code></a> Update version for final release.</li> <li><a href="https://github.com/twisted/towncrier/commit/f031dfa94e52e07b6c71e88cd5cd50e3803ad96c"><code>f031dfa</code></a> towncrier build --yes</li> <li><a href="https://github.com/twisted/towncrier/commit/4c854f58a2074458cd66767aca9f3aaa34d842d8"><code>4c854f5</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/hawkowl/towncrier/issues/402">#402</a> from webknjaz/patch-2</li> <li><a href="https://github.com/twisted/towncrier/commit/f911402b69960bee358b0c2011d685721afa9454"><code>f911402</code></a> Pin external github actions,</li> <li><a href="https://github.com/twisted/towncrier/commit/a814202234214182855fe4a5ffb40c7f7aec2b04"><code>a814202</code></a> [pre-commit.ci] auto fixes from pre-commit.com hooks</li> <li><a href="https://github.com/twisted/towncrier/commit/675219a6deac7c65bb94b72da55059b7077e5ec4"><code>675219a</code></a> Add a dummy change note for PR <a href="https://github-redirect.dependabot.com/hawkowl/towncrier/issues/402">#402</a></li> <li><a href="https://github.com/twisted/towncrier/commit/b566bfb0dcdcd86fa9d349875eba15e647c06459"><code>b566bfb</code></a> Uninvent the wheel w/ <code>re-actors/alls-green</code> @ GHA</li> <li><a href="https://github.com/twisted/towncrier/commit/5bf0a4653bb2adf52162550d436f1dc39f6e0446"><code>5bf0a46</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/hawkowl/towncrier/issues/396">#396</a> from twisted/292-more-ci-checks</li> <li><a href="https://github.com/twisted/towncrier/commit/1bb62219a9e7b0d969292cae56104678b8bea151"><code>1bb6221</code></a> Merge branch 'trunk' into 292-more-ci-checks</li> <li><a href="https://github.com/twisted/towncrier/commit/07baa2ba4b1159462dcb212395be1de91674698d"><code>07baa2b</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/hawkowl/towncrier/issues/395">#395</a> from twisted/384-cli-help</li> <li>Additional commits viewable in <a href="https://github.com/hawkowl/towncrier/compare/21.9.0...22.8.0">compare view</a></li> </ul> </details> <br /> You can trigger a rebase of this PR 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` 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) </details> Changes needed for this * Invert logic for single file. 22.8.0 fixed the logic such that single_file=False is correct when you have more than one file * Pin versions of towncrier and sphinx towncrier to reflect this (so we get the right config) Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jens H. Nielsen <Jens.Nielsen@microsoft.com>
Based on a discussion with @damazter I would like to put forward the concept of a configuration parameter.
What is a configuration parameter?
_configure_required
toTrue
.configure()
method whenever_configure_required==True
.What problem does this solve?
I think this is a sufficiently common problem that it warrants a new parameter class. The current instruments that need it both have a different solution.
The signal hound driver solves this problem by using manual parameters and the requiring the user to call the configure command by hand. The ill documentation of this functionality, combined with the missing of a simple getable parameter that represents a measurement (based on my shoddy port of an existing qtlab driver) is what initiated this discussion.
The ATS driver solves this problem by introducing an unsetable
AlazarParameter
that can only be changed using either the private method or the configure command.I would argue that the concept of a configuration parameter is the prefered solution to this problem. However, I explicitly put this forward as a point of discussion as introducing a new concept must not be done lightly.
( @giulioungaretti, Probably intentional but I am no longer able to apply labels to issues, would make it easier to structure things a bit.)
P.S. as this issue was motivated by the low quality of a driver that I ported this raises a separate issue as to who will work on improving existing drivers, maybe an interesting subject for a discussion on Slack.
The text was updated successfully, but these errors were encountered: