Skip to content

Releases: slaclab/pydm

PyDM 1.7

12 Jun 23:17
7bfb9dc
Compare
Choose a tag to compare

PyDM 1.7 Release Notes

Hello, everyone. After a significant period (six months!) without any releases, we are finally releasing PyDM 1.7. There have been almost 150 commits since the last release (1.6.5), so there's quite a lot of features and bug fixes (see below for the full lists). Before you get to those lists, please read the info about our plan for releasing PyDM 2.0, which is happening some time in the next few months.

PyDM 2.0 Coming Soon!

PyDM 1.7 is intended to be the final minor version in the 1.0 series. The next non-bugfix release will almost definitely be 2.0, which will be centered around big changes to the flow of data between PyDM plugins and widgets. This will allow us to support sources of structured data, where multiple pieces of data are all sent as a single structure. This will allow us to support a whole new set of control system protocols, like EPICS7's PVAccess.

This will be a big overhaul, and there will be some breaking changes to the way things work - mostly in the data plugin department, but a few other places too. We'll publish migration guides to help you get any custom data plugins and widgets you have up in running in 2.0. Another change to be aware of is that we will be ending support for Python2.7 - all v2.0-and-up releases will only support Python 3.6 and higher.

Our plan is to have a separate '2.0' branch of the PyDM repository available (probably with pre-release tagged versions) for a few months, and let the user community try it out before finally merging it in and releasing 2.0 proper. Stay tuned!

New Features in 1.7

  • A new widget, PyDMTemplateRepeater, has been created. This new widget lets you specify a .ui file as a "template", and then specify a .json file as a "data source" that will fill in multiple instances of that template with values. The PyDMTemplateRepeater can lay out the instances vertically, horizontally, or in a 'flow' layout, which is like a grid layout that wraps to new rows as the row fills. If you use this widget in a python-based display, you can directly supply a list of dictionaries to use as a data source - giving you the possibility to hook it up to databases, web APIs, etc. This widget was built to create huge displays with lists of controls for dozens of devices, in a dynamic way, without having to write any code (unless you want to!).
  • PyDMLabels can now set their text via the Widget Rules system. This is pretty powerful, and lets you display custom text when a channel value (or multiple channels) change.
  • PyDMComboBox widgets can now be used with plain-old integer value channels. You can specify the text to display for each value inside Qt Designer (right click and chose 'Edit Items'). Integer values that don't correspond to a pre-defined string will just appear as an empty string in the combo box. (Thanks @ivany4)
  • The shorter EDM-style macro syntax ("key1=val1,key2=val2") now works in all widgets with a 'macros' field, in addition to the original JSON macro syntax.
  • All PyDM drawing widgets now have configurable Pen Cap and Join Style properties. (Thanks @hhslepicka)
  • PyDMRelatedDisplayButtons can now have multiple files specified on the same button. If you specify multiple files (which is now a QStringList property, rather than just a string), the button will give you a drop-down menu to let you choose a particular file to launch. This re-creates a feature available in MEDM.
  • PyDMPrimitiveWidget can now be subclassed with additional constructor parameters. (Thanks @hhslepicka)
  • PyDM now has a new pydm.data_plugins.connection_queue() context manager that will establish channel connections in a batch. PyDM now uses this feature internally when loading all displays. When instantiating large numbers of widgets, this results in faster connections and less user-interface pausing. See #467 for an example of how it is used - it may be useful in python-based displays or custom widgets that dynamically establish connections to channels.
  • PyDM now waits until the display appears on-screen before establishing connections. This doesn't affect the total time that it takes to display a screen and establish the connections, but does make PyDM feel more responsive to users - they don't have to wait for all the channels to connect before seeing the screen.
  • PyDMEmbeddedDisplay widgets have a new property, 'loadWhenShown'. This property will prevent the display from actually loading and connecting to widgets until it is actually visible on the screen. In cases where you have a display with a bunch of PyDMEmbeddedDisplay widgets inside tabs, this can make your display load much faster.
  • PyDMEmbeddedDisplay now works outside of PyDMApplication, including in Qt Designer. (Although in Qt Designer, you can't edit the content of an embedded window from the embedded window's parent - you'll still have to open it on its own to edit it.)
  • PyDM's CI has been moved to Azure Pipelines. (Thanks @hhslepicka)

Bug Fixes in 1.7

  • The ability to middle-click a widget to see its channel address works again (Thanks @hhslepicka)
  • PyDM now strips whitespace from the beginning and end of channel address strings (Thanks @hhslepicka)
  • Fixed pydm.utilities.establish_widget_connections, which never worked due to logic errors.
  • Fix a crash in PyDMWaveformPlot when all elements of the waveform data were +inf or -inf. (Thanks @hhslepicka)
  • Stylesheet properties now properly cascade to child widgets. (Thanks @hhslepicka)
  • The (always unused) 'channel' property on PyDMImageView has been hidden from Qt Designer (Thanks @hhslepicka)
  • PyDMLogDisplay now cleans up the log handler when it closes (Thanks @hhslepicka)
  • Fix a bug in setup.py when loading the requirements.txt file (Thanks @hhslepicka)
  • requirements.txt has been updated to better separate testing and CI requirements from the core PyDM requirements (Thanks @hhslepicka)
  • PyDMSliders will no longer crash PyDM if you try to use them without any specified high and low limits. (Thanks @ivany4)
  • Fix a crash when inserting a tab into PyDMTabWidget in Qt Designer (Thanks @ivany4)
  • Fix painting bug in PyDMByteWidget (Thanks @hhslepicka)
  • Hard-coded paths have been removed from some of PyDM's tests (Thanks @hhslepicka)

Refactoring

  • Value text formatting (setting precision, setting exponential format, appending unit strings, etc) functionality has now been moved out of PyDMBaseWidget and into its own mixin class. This means that text-formatting properties have been removed from widgets where they aren't relevant.

PyDM 1.6.5

12 Dec 01:22
de588d2
Compare
Choose a tag to compare

This release addresses a few small issues:

  • Increasing/decreasing font sizes works without needing to refresh the display, and is applied to all widgets, even if they have specified a custom font.
  • The pydm.PyQt module has been temporarily re-added. This is intended as a temporary stop-gap to fix crashes for users that have created Display classes that imported from pydm.PyQt. If you currently do this in your displays, please update them to import directly from the 'qtpy' module instead.
  • Remove the built-in margins around the PyDMByteWidget. If you need margins around a PyDMByteWidget, you can put it into a layout, or in code, you can manually set them with PyDMByteWidget.layout().setContentsMargins(left, top, right, bottom)

PyDM 1.6.4

06 Dec 01:51
6bd2aaa
Compare
Choose a tag to compare

PyDM 1.6.4 Release Notes

PyDM 1.6.4 is another bugfix release.

Bug Fixes

  • EPICS Data Plugins were never sending new value for widgets recently connected.
  • Stylesheet was not being applied unless specified using the --stylesheet argument. Tests were added to cover also this case. (Thanks @mattgibbs)

PyDM 1.6.3

04 Dec 23:36
eb5133b
Compare
Choose a tag to compare

PyDM 1.6.3 Release Notes

PyDM 1.6.3 is another bugfix release.

Bug Fixes

  • Base widget rules test was hanging on OSX.
  • A ValueError exception was being raised at data plugins when comparing the new value with old value if value was a numpy array.

PyDM 1.6.2

30 Nov 22:57
293ceec
Compare
Choose a tag to compare

PyDM 1.6.2 Release Notes

PyDM 1.6.2 is another bugfix release.

Bug Fixes

  • The middle-click tooltips that show the channel address associated with a widget have been fixed. (Thanks @klauer)
  • Display classes that don't specify a valid ui_filename no longer cause a crash. (Thanks @hhslepicka)
  • Widgets that display units or handle precision information will now update properly when the units or precision change. (Thanks @hhslepicka)
  • In some cases, pyepics and caproto data plugins were incorrectly emitting the 'new value' signal even though the value had not changed. This has been fixed. (Thanks @hhslepicka)
  • Fix broken unit tests for PyDMSpinbox (Thanks @hhslepicka)
  • The PyDMWidget event filter (which drives the ability to show custom context menus and middle-click tooltips) is now installed for any QApplication except Qt Designer. Previously, it was only installed for PyDMApplication. (Thanks @hhslepicka)
  • The PyDM Widget Rules system has been extracted from PyDMApplication into a utility module, allowing the use of widget rules outside of PyDMApplications. (Thanks @hhslepicka)
  • The PyDMScale widget now has properties for user-configurable limits, and a way to switch between user-configured limits, and limits from the channel. (Thanks @hhslepicka)
  • The 'Increase/Decrease Font Size' menu items work again. In addition, a 'Default Font Size' menu item has been added to reset the font to its default size.

PyDM 1.6.1

20 Nov 00:13
7a0a9af
Compare
Choose a tag to compare

PyDM 1.6.1 Release Notes

PyDM 1.6.1 fixes three small problems.

Bug Fixes

  • Remove the 'Checkbox' option from PyDMEnumButton, which didn't make any sense in the context of enums.
  • In setup.py, always decode README.md as UTF-8. This should fix a crash when installing PyDM while using an obscure default text encoding.
  • Stop putting the entire docstring for each widget into the 'whatsThis' property. This should considerably reduce .ui file sizes, and will also get rid of the laughably huge tooltips when hovering over PyDM widgets in Designer.

PyDM 1.6.0

19 Nov 00:26
9a3938c
Compare
Choose a tag to compare

PyDM 1.6 Release Notes

PyDM 1.6 makes some architectural changes to how widgets get data, makes it slightly easier to write python-based displays, and adds a new widget for interacting with enum channels. See below for all the details.

New Features

  • All connection between the PyDM widgets and data plugins are now handled in pydm.data_plugins. This means you can use the PyDM widget set without a PyDMApplication. (Thanks @teddyrendahl)
  • pydm.Display subclasses no longer need to include the 'ui_filepath' method.
  • pydm.Display subclasses can now specify ui_filepath by setting 'self.ui_filepath' inside __init__, or also by supplying a ui_filepath keyword argument in the constructor.
  • Management of PyDM external tools has now been extracted from PyDMApplication, into the pydm.tools module (Thanks @hhslepicka )
  • A new PyDMEnumButton widget has been added. This widget gives you new options for controlling enum channels, via a set of push buttons or radio buttons. (Thanks @hhslepicka )
  • PyDM should now be installable directly from pip: pip install pydm (Thanks @hhslepicka, who not only made all this work, but went through the arduous process of securing the 'pydm' name in PyPI!)

Bug Fixes

  • Fix a bug that was causing a crash if a channel was specified with an invalid protocol. (Thanks @fernandohds564 )
  • Rename the PyDM designer plugin file so that it won't collide with other generically-named designer plugins (Thanks @hhslepicka )
  • Shell Command widget tests no longer try to ping Google. (Thanks @hhslepicka )

Other Changes

  • The tutorial info has been extracted out of the PyDM documentation and into the PyDM Tutorial: https://slaclab.github.io/pydm-tutorial/
  • Command line argument text has been slightly tweaked for clarity.

PyDM 1.5

09 Oct 23:28
33487ea
Compare
Choose a tag to compare

PyDM 1.5 Release Notes

Today we're releasing PyDM 1.5. No huge user-facing features this time - this release is focused on the inner workings. The two most notable changes are enhancements to PyDMTimePlot, and the switch from our home-built PyQt compatibility layer (which has mostly been useless since we removed PyQt4 support) to QtPy. Besides those, there are all the usual bug fixes and minor improvements to widgets.

New Features

  • PyDM now uses QtPy as the compatibility layer, which lets us support both PyQt5, and PySide2. Note that right now, we are still only developing and testing using PyQt5, and so PySide2 should be considered experimental, and may be unstable. (Thanks @tacaswell for the work on this - the process must have been incredibly tedious!)
  • All Plot Widgets now support an optional right axis. For now, changing the scale of the right axis can only be done programmatically, but expect this to eventually be changeable in Designer. (Thanks @hmbui)
  • There have been many behind-the-scenes enhancements to the PyDMTimePlot widget to support TimeChart, our general purpose, standalone signal vs. time plotting tool. TimeChart hasn't had an official release yet, but expect to see one pretty soon. Many of these enhancements will eventually be exposed as properties in Designer, so stay tuned. (Thanks @hmbui)
  • Environment variables are now expanded when used to specify file paths (Thanks @hhslepicka)
  • Another EPICS data plugin has been added for the caproto client library. To use it, set the PYDM_EPICS_LIB environment variable: export PYDM_EPICS_LIB=CAPROTO (Thanks @hhslepicka)

Bug Fixes

  • Macro replacement is now done in-memory, rather than in a temporary file. This reduces disk thrashing. (Thanks @klauer)
  • Fixed a crash in Designer due to the PyDM Extensions system (Thanks @klauer)
  • Macros now correctly propagate to files opened using related display buttons (Thanks @klauer)
  • The X and Y axes on PyDMScatterPlots are no longer reversed (Thanks @klauer)
  • PyDMByteIndicators now work with values with more than 8-bits (You guessed it: Thanks @klauer)
  • Fixed a bug that could prevent PyDMWaveformPlot from triggering (Thanks @fernandohds564)
  • Updated the list of PyDM contributors on the 'About' screen
  • All plot widgets now only redraw if the data has changed, significantly reducing CPU usage
  • Minor errors corrected in docstrings for widgets, like parameters being listed as 'returns' (Thanks @KurtJacobson)
  • Fixed PyDMLineEdit's handling of PVs without units (Thanks @teddyrendahl)
  • Fix default stylesheet problem with pen width definition (Thanks @hhslepicka)

PyDM 1.4.2 Release Notes

22 Aug 02:08
e26aad5
Compare
Choose a tag to compare

PyDM 1.4.2 Release Notes

PyDM 1.4.2 is here. This is a bug fix release.
Someone once told me that it is a good practice to do frequent releases...
Read on for more details...

Bug Fixes

  • PyDM Waveform Plot and PyDM Scatter Plot were not respecting the AutoRange as well as the Range Limits defined by users. (#387)

PyDM 1.4.1 Release Notes

16 Aug 17:42
4f4097d
Compare
Choose a tag to compare

PyDM 1.4.1 Release Notes

PyDM 1.4.1 is here. This is mainly a bug fix release but it also adds some minor improvements for the recent released widget rules system. Read on for more details...

New Features

  • Added a new Opacity property to be used by the Rules mechanism for all PyDM widgets. This property can also be used with the python API through the set_opacity and opacity methods. (#382)
  • Added a new Index property to be used by the Rules mechanism for the PyDM Symbol widget. This now allow users to specify an expression to select the current image index to be displayed. When using the Index in a rule it is strongly recommended that you remove the Channel from the widget to avoid conflicts. (#382)

Bug Fixes

  • PyDM Rules Editor now has no parent which avoids the Stylesheet of a widget to be applied to the editor window when no proper selector was specified. (#382)
  • Fix an issue when removing a rule from the middle of the list in the Rules Editor. (#382)
  • Now the middle-click will properly copy the Channel address to the clipboard on Windows and MacOS and no longer present the message: Data set on unsupported clipboard mode. QMimeData object will be deleted.. (#384)
  • Fixed an issue that prevented files to be properly opened in a new window when using the Windows path separator. (#385)
  • Fixed an issue with the PyDMShellCommand when using the Windows path separator in a command. (#386)