Skip to content
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

Py3 cmp #1605

Merged
merged 39 commits into from
Apr 28, 2020
Merged

Py3 cmp #1605

merged 39 commits into from
Apr 28, 2020

Conversation

brucelowekamp
Copy link
Contributor

This picks up on @nils-van-zuijlen work on fixing cmp for python3 compatibility in PR #1538 My client code works in python3 after these changes, so might be enough for #1506 though would like to get it built with python3 as well.

Note that Nils had added comments that functools requires dropping 2.7. As far as I can tell the features in 3.x were backported to 2.7, so dropping 2.6 would let a lot of the boilerplate here be ignored. Also, sorting None elements in with UID and MACAddress appear to work (judging by the tests) with the current implementation when functools.total_ordering is used. I updated comments to reflect that.

Changes in here on top of #1538

  • move to isinstance rather than comparing class
  • add tests for all the comparisons as well as ClientWrapper events and a simple DMX send test
  • implement all other comparisons in terms of eq and lt
  • ensure that hash are == when eq == True by not including extra fields in hash (alternatively if the other fields should be in hash, they should be included in cmp)
  • ResponderTest implements cmp by comparing names, which I think matches the original cmp. The only use I can come up for this is sorting the subclass test implementations, so this functionality is preserved in the comparisons, though I didn't find it used anywhere.

minor random changes:

  • support creating ClientWrapper events with TimeDelta instead of ms
  • exit ClientWrapper loop faster when stopping, though check sockets on our way out
  • 9010 was defined as a constant, but not used in code
  • the code seems to categorically ignore two other flake8 tests, so added them to exclude docs

@peternewman
Copy link
Member

peternewman commented Jan 8, 2020

Firstly thanks for this!

Note that Nils had added comments that functools requires dropping 2.7. As far as I can tell the features in 3.x were backported to 2.7, so dropping 2.6 would let a lot of the boilerplate here be ignored.

So taking Ubuntu as a good basemark, if we ignore the paid support option then 16.04 is the oldest supported OS, it's Python is still only 2.7:
https://packages.ubuntu.com/search?keywords=python&searchon=names&exact=1&suite=xenial&section=all

Although even 14.04 had 2.7...

However it would be a shame to break 2.6 in the 0.10.8 release, and not really in the spirit of bug-fixes only, but feel free to remove that requirement in the master/0.11 branch. 2.7 needs to keep working until at least April 2023 though!

I think 0.10.8 will be the final 0.10 branch release as there are some RDM changes to handle the E1.33/E1.37-7 PIDs which become too much of a new feature for a patch release, so that will help things too. If this PR becomes too awkward we can just push it into 0.11 anyway.

@peternewman peternewman added this to the 0.10.8 milestone Jan 8, 2020
Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add these new test scripts into debian/tests/control so they are tested as part of the Debian CI too.

Some initial comments

.travis.yml Outdated
@@ -287,6 +287,7 @@ before_cache:
install:
# Match the version of protobuf being installed via apt
- pip install --user protobuf==3.1.0
- pip install --user timeout-decorator
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a requirement we should add to the various build systems?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's used by the Event and OlaClient tests in ClientWrapperTest. Not used outside the tests. Honestly it could be dropped if it were preferable to let the tests hang if something breaks and let the build system kill them, but I hate tests that do that :)

Actually, I realized I forgot to add something to disable those tests in Windows in Py2. It relies on socketpair that wasn't supported natively in Win until 3.5, and IMHO it wouldn't be worth adding one of the various implementations at this point. Will add that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checked and the python code is already not windows compatible so not changing anything in that test.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it's required, we should add it to the Debian, configure script etc. Can I suggest taking out the decorators for the moment until we've got this in, and then looking at adding them back in later to simplify the merge, given if the tests are passing it will work fine without the decorators.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For posterity, the decorators are now commented out

README.developer Show resolved Hide resolved
python/ola/MACAddress.py Show resolved Hide resolved
Copy link
Contributor Author

@brucelowekamp brucelowekamp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Firstly thanks for this!

Note that Nils had added comments that functools requires dropping 2.7. As far as I can tell the features in 3.x were backported to 2.7, so dropping 2.6 would let a lot of the boilerplate here be ignored.

So taking Ubuntu as a good basemark, if we ignore the paid support option then 16.04 is the oldest supported OS, it's Python is still only 2.7:
https://packages.ubuntu.com/search?keywords=python&searchon=names&exact=1&suite=xenial&section=all

Although even 14.04 had 2.7...

However it would be a shame to break 2.6 in the 0.10.8 release, and not really in the spirit of bug-fixes only, but feel free to remove that requirement in the master/0.11 branch. 2.7 needs to keep working until at least April 2023 though!

I think 0.10.8 will be the final 0.10 branch release as there are some RDM changes to handle the E1.33/E1.37-7 PIDs which become too much of a new feature for a patch release, so that will help things too. If this PR becomes too awkward we can just push it into 0.11 anyway.

I think leaving 2.6 supported until the next major release makes sense. Having put the boilerplate code in, it doesn't really cost anything to leave it. If someone needs to refactor again they could remove the extra comparisons and do some things like shift the protocol classes to use the attrs package rather than tons of boilerplate, but it's fine now.

I don't believe 2.7 is going anywhere :)

IMHO this change ought to be in 10.8 for those who want to use the OLA client API with a py3 project. It would require them to do a manual install, but it would unblock them (and those who try to use the mac brew build that forced py3).

I have more changes that are mostly finished to make the whole thing build and install with python3. There are quite a few changes but they're mostly mechanical and not in the client sdk (Nils got most of them there). I don't know that there's a reason not to put the additional changes into 10.8 either, but as there's one non-trivial change (short but I will need help validating it), need for a new builder, and as there's no test-suite I don't really know if it runs, I felt like I would put it into a separate PR.

@brucelowekamp
Copy link
Contributor Author

Can you add these new test scripts into debian/tests/control so they are tested as part of the Debian CI too.

Haven't worked with debuild before but will try to get it added in the next day or two.

@brucelowekamp
Copy link
Contributor Author

@peternewman I got debuild working to the point toward the end that it noticed that my protobuf install wasn't from a deb and quit (I have a hand-built protobuf since I couldn't find a package for 3.1.0). There doesn't seem to be a way to bypass that check. Do you know the location of a package I could use instead or another way to get around that?

@peternewman
Copy link
Member

I think leaving 2.6 supported until the next major release makes sense. Having put the boilerplate code in, it doesn't really cost anything to leave it. If someone needs to refactor again they could remove the extra comparisons and do some things like shift the protocol classes to use the attrs package rather than tons of boilerplate, but it's fine now.

Sounds very sensible

I don't believe 2.7 is going anywhere :)

Indeed I suspect you're right.

IMHO this change ought to be in 10.8 for those who want to use the OLA client API with a py3 project. It would require them to do a manual install, but it would unblock them (and those who try to use the mac brew build that forced py3).

Yeah we always seem to be playing catchup now with new releases.

My thinking is release 0.10.8 probably as soon as this is in, possibly after one or two other minor bugs. Then I suspect release 0.11.0 almost immediately as it's had a queue of shiny new features appearing since 2016 (gulp), but no-one seems to offer to test it thoroughly when I ask, branch that off for 0.11.1 if there are any bugfixes, then master becomes what will be 0.12.0 and people can start culling or breaking things if they like, such as C++11 and Python 2, rather than throw away a lot of known good compatibility for no good reason. Then people have a choice of a bug fix on what they're using (0.10.8), latest stable (0.11.0) or bleeding edge (master).

I have more changes that are mostly finished to make the whole thing build and install with python3. There are quite a few changes but they're mostly mechanical and not in the client sdk (Nils got most of them there). I don't know that there's a reason not to put the additional changes into 10.8 either, but as there's one non-trivial change (short but I will need help validating it), need for a new builder, and as there's no test-suite I don't really know if it runs, I felt like I would put it into a separate PR.

Thanks @brucelowekamp sounds sensible, we can make a judgement on if it goes into 0.10.8 or gets pushed back.

@peternewman
Copy link
Member

@peternewman I got debuild working to the point toward the end that it noticed that my protobuf install wasn't from a deb and quit (I have a hand-built protobuf since I couldn't find a package for 3.1.0). There doesn't seem to be a way to bypass that check. Do you know the location of a package I could use instead or another way to get around that?

That's great news.

So the official Debian release gets round this by cherry-picking our hack that's only in our 0.10 branch to make Protobuf work with a newer version, I'm still on an older release which hence has an old protobuf and doesn't have these issues.

I suspect your best bet might be to test the debuild stuff against @yoe 's branch which is where the Debian package, and hence our debuild usage comes from:
0.10...yoe:master

Then just cherry-pick your debuild changes back from a fork of that into this PR or something? He can probably advise either way or possibly even give you some useful CI or something, he's certainly our guru when it comes to Debian!

@peternewman
Copy link
Member

peternewman commented Jan 21, 2020

To clarify here, do you think this PR is ready to go aside from debuild? I think while tests are nice, if it looks like it will be a long haul or you don't get too far with what it and you've tested what you've committed (which I'm guessing you have), we could get it merged and leave debuild as a nice to have and leave the issue open to track that as well as general Python code python3 compatibility.

@brucelowekamp
Copy link
Contributor Author

To clarify here, do you think this PR is ready to go aside from debuild? I think while tests are nice, if it looks like it will be a long haul or you don't get too far with what it and you've tested what you've committed (which I'm guessing you have), we could get it merged and leave debuild as a nice to have and leave the issue open to track that as well as general Python code python3 compatibility.

I've used it with my code in both 2.7 and 3.7. Now my code only sends and doesn't receive or do any sort of management, but as far as I can tell the changes are consistent. As I said in the other thread I'm not sure the new tests will pass in 2.6, but I believe that would be it.

Having said that, I went to look again and found that @nils-van-zuijlen original change altered the semantics of the comparison in PidStore.py. I'm not sure why (I tried to avoid that and made sure the hashes and comparisons were consistent, but I missed this one). Will ask if he remembers why.

@nils-van-zuijlen
Copy link
Member

I added checks for the other fields in 3d9d8d8 from @peternewman 's question in 3d9d8d8#r257505257

Copy link
Contributor Author

@brucelowekamp brucelowekamp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added checks for the other fields in 3d9d8d8 from @peternewman 's question in 3d9d8d8#r257505257

Thanks. I agree they should be there, but I realized I missed PidStore.py entirely, including testing. Hope to get some tests in later this week.

common/web/SchemaParserTest.cpp Show resolved Hide resolved
python/ola/PidStore.py Outdated Show resolved Hide resolved
@brucelowekamp
Copy link
Contributor Author

I added checks for the other fields in 3d9d8d8 from @peternewman 's question in 3d9d8d8#r257505257

Thanks. I agree they should be there, but I realized I missed PidStore.py entirely, including testing. Hope to get some tests in later this week.

@peternewman @nomis52 In doing a PidStore test (pulling tests from PidStoreTest.cpp), I discovered there is no override support in the python PidStore (loading common/rdm/testdata/pids fails). Doesn't appear hard to implement, but a comment in PidStore.h says higher version is a newer pid, but the PidStoreTest.cpp appears to assume the lower version will be used. It looks relatively easy to add version to the store and pids, but wanted to check that the "lower version wins" behavior is correct before I implement it.

@peternewman
Copy link
Member

@peternewman @nomis52 In doing a PidStore test (pulling tests from PidStoreTest.cpp), I discovered there is no override support in the python PidStore (loading common/rdm/testdata/pids fails). Doesn't appear hard to implement, but a comment in PidStore.h says higher version is a newer pid, but the PidStoreTest.cpp appears to assume the lower version will be used. It looks relatively easy to add version to the store and pids, but wanted to check that the "lower version wins" behavior is correct before I implement it.

Oops, good spot!

Where's the comment and test about versions, the only stuff I can find is here:
https://github.com/OpenLightingProject/ola/blob/master/include/ola/rdm/PidStore.h#L64-L66

I think the version comment is prior to overrides existing and I don't believe we actually check versions anywhere. The idea though is the override file gets loaded regardless of how versions might compare.

One thing, if we add this to the Python code, which as you say we should, it should probably be disabled by default in the RDM tests/model collector because I think by default it should probably use the "official" data.

@peternewman
Copy link
Member

I added checks for the other fields in 3d9d8d8 from @peternewman 's question in 3d9d8d8#r257505257

@nils-van-zuijlen what's the link to my question, it just seems to point to the commit?

@nils-van-zuijlen
Copy link
Member

It's #1538 (comment)

Sorry, I didn't check if the previous link was working as intended.

@brucelowekamp
Copy link
Contributor Author

Ah, I found a description of what the version number was, but not the overrides.proto comment (or the code corresponding to it).

Should be pretty easy to implement. Hope to get it in over the weekend and rebase the code on top of current 0.10.

Bruce

functools.total_ordering is only available from python 3.2
fix flake8 formatting
When you call RegisterUniverse with action set to UNREGISTER, you don't want to be forced to provide a data_callback
As stated in the doc (https://docs.python.org/2.7/reference/datamodel.html?highlight=cmp#object.__cmp__) __cmp__ is only called if rich comparison is not defined and we define it as it is the only way to support python 3
Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one comment for now @brucelowekamp .

@brucelowekamp
Copy link
Contributor Author

I started removing some double spaces while fixing some other minor typos @brucelowekamp , then I Googled and found out why, https://www.python.org/dev/peps/pep-0008/#comments (learning something new every day).

Every time I've pushed without running flake8, I've regretted it...

@brucelowekamp
Copy link
Contributor Author

fwiw, I've just merged this, with minimal changes, into my Debian branch, and pushed the result to https://salsa.debian.org/wouter/ola/-/tree/py3
I'll pass any fixes to make things work on Debian here.

Great thanks @yoe . Does that mean OLA should stay in Debian for the next release? I guess subject to https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=925793 AKA #1553 AKA #1583 ?

As soon as the Python3 build works in something that I can upload to Debian, and the code compiles with a compiler that's available in Debian, I'll reupload it. If that happens a few weeks before the relevant freeze for Bullseye (starting next January according to https://release.debian.org/) then it will still be in that release, yes.

I haven't had much time to look at finalizing the gcc9 issues, mainly because of https://jonathancarter.org/2020/03/02/free-software-activities-for-2020-02/, but hopefully I'll be able to pick that up again soon.

Any idea what we need to do to nudge the Ubuntu people to go the same way?

Unfortunately, it is too late for Focal (20.04) by now, since they're already in deep freeze in preparation for their release late this month. TTBOMK, it is not possible to add packages to Ubuntu after their freeze, let alone after the release. I could perhaps look at creating a PPA once everything is back in order in Debian if there is sufficient demand?

The other challenge is that this is only (I think the most important) part of the python3 work. I have another set of changes that got most of the tools/rdm working (or at least passing sanity checks), and there was another patch submitted a couple weeks ago for part of the API. Given how long it's taken getting these patches through, I thought it best to wait to put in a PR for more. The new protobuf code should help as well, though. But ultimately there's more work, and it will require testing from some folks who use that part of the code. (I only use the sending API)

Bruce

@yoe
Copy link
Contributor

yoe commented Apr 9, 2020

Another option (certainly not my favourite) if we are not able to get this done in time for the Ubuntu 20.10 release (which would require that this is all resolved by July-August if I'm not mistaken) is to upload a version of ola with all python support disabled at compile time.

That would definitely fit the bill as far as Debian is concerned, but is obviously not a very good long-term strategy, and disabling the python-based tools would have some downside. Still, it would get something in for Ubuntu 20.10, which is better than what's going to happen to 20.04.

Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few hash comparison comments

python/ola/PidStoreTest.py Show resolved Hide resolved
python/ola/PidStoreTest.py Show resolved Hide resolved
python/ola/UIDTest.py Show resolved Hide resolved
@peternewman
Copy link
Member

fwiw, I've just merged this, with minimal changes, into my Debian branch, and pushed the result to https://salsa.debian.org/wouter/ola/-/tree/py3
I'll pass any fixes to make things work on Debian here.

Great thanks @yoe . Does that mean OLA should stay in Debian for the next release? I guess subject to https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=925793 AKA #1553 AKA #1583 ?

As soon as the Python3 build works in something that I can upload to Debian, and the code compiles with a compiler that's available in Debian, I'll reupload it. If that happens a few weeks before the relevant freeze for Bullseye (starting next January according to https://release.debian.org/) then it will still be in that release, yes.

Ah great thanks @yoe , so we won't have dropped out of Debian, that's good. Your fix for GCC9 #1583 means it compiles with GCC at least (if not Clang currently).

I haven't had much time to look at finalizing the gcc9 issues, mainly because of https://jonathancarter.org/2020/03/02/free-software-activities-for-2020-02/, but hopefully I'll be able to pick that up again soon.

Amazing, congratulations to both of you! 🎊 👰‍♀️ 🤵‍♂️

Any idea what we need to do to nudge the Ubuntu people to go the same way?

Unfortunately, it is too late for Focal (20.04) by now, since they're already in deep freeze in preparation for their release late this month. TTBOMK, it is not possible to add packages to Ubuntu after their freeze, let alone after the release. I could perhaps look at creating a PPA once everything is back in order in Debian if there is sufficient demand?

Damn, I hoped they might have an exception for packages which had previously been in Ubuntu and it's a particular shame it's an LTS release. @VoltVisionFrenchy had previously made an OLA PPA, perhaps if we ask really nicely he'll be able to update that (or possibly automate it so it just pulls from Git and builds in future.

The other challenge is that this is only (I think the most important) part of the python3 work. I have another set of changes that got most of the tools/rdm working (or at least passing sanity checks), and there was another patch submitted a couple weeks ago for part of the API.

Yeah hopefully the other stuff is simpler when we've got the core changes in and should need less checking for example as it won't interact with other bits so much or be as complicated hopefully.

Given how long it's taken getting these patches through, I thought it best to wait to put in a PR for more. The new protobuf code should help as well, though. But ultimately there's more work, and it will require testing from some folks who use that part of the code. (I only use the sending API)

Yeah sorry I've been rather slow with some of these PR reviews @brucelowekamp . Various bits of other life going on. Hopefully given the current situation things will quieten down a bit! 😷

I'm sure we can cover off the testing too.

Another option (certainly not my favourite) if we are not able to get this done in time for the Ubuntu 20.10 release (which would require that this is all resolved by July-August if I'm not mistaken) is to upload a version of ola with all python support disabled at compile time.

Technically we could just release the ola deb couldn't we (without ola-python or ola-rdm-tests)?

That would definitely fit the bill as far as Debian is concerned, but is obviously not a very good long-term strategy, and disabling the python-based tools would have some downside. Still, it would get something in for Ubuntu 20.10, which is better than what's going to happen to 20.04.

Yeah definitely. I guess we missed a trick there and should have done just ola (without Python) for 20.04.

@yoe
Copy link
Contributor

yoe commented Apr 16, 2020

Another option (certainly not my favourite) if we are not able to get this done in time for the Ubuntu 20.10 release (which would require that this is all resolved by July-August if I'm not mistaken) is to upload a version of ola with all python support disabled at compile time.

Technically we could just release the ola deb couldn't we (without ola-python or ola-rdm-tests)?

Yes, we could (and we'd have to, otherwise those packages would be empty, and that makes no sense)

That would definitely fit the bill as far as Debian is concerned, but is obviously not a very good long-term strategy, and disabling the python-based tools would have some downside. Still, it would get something in for Ubuntu 20.10, which is better than what's going to happen to 20.04.

Yeah definitely. I guess we missed a trick there and should have done just ola (without Python) for 20.04.

Yup, but it's too late now, unfortunately.

Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few minor bits @brucelowekamp , mostly around that change of behaviour you flagged up, and then some minor tidying of the Makefiles, but this is basically ready to merge now.

Continued thanks for all your work on getting this over the line!

tools/rdm/TestStateTest.py Outdated Show resolved Hide resolved
python/ola/PidStoreTest.py Outdated Show resolved Hide resolved
python/ola/PidStoreTest.py Outdated Show resolved Hide resolved
python/ola/PidStoreTest.py Outdated Show resolved Hide resolved
python/ola/Makefile.mk Outdated Show resolved Hide resolved
python/ola/Makefile.mk Outdated Show resolved Hide resolved
tools/rdm/Makefile.mk Outdated Show resolved Hide resolved
tools/rdm/Makefile.mk Outdated Show resolved Hide resolved
tools/rdm/Makefile.mk Outdated Show resolved Hide resolved
@@ -65,7 +69,7 @@ class UnpackException(Error):


class MissingPLASAPIDs(Error):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we should really have renamed this (or kept the old one for backwards compatibility and subclass or re-raise or something)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The name hasn't changed since it was introduced, AFAICT. The comment change was one of the changes brought in from master.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah okay, one for after this mammoth PR is in then!

python/ola/PidStore.py Outdated Show resolved Hide resolved
python/ola/PidStoreTest.py Outdated Show resolved Hide resolved
Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few very minor comments here.

python/ola/PidStore.py Outdated Show resolved Hide resolved
python/ola/PidStore.py Outdated Show resolved Hide resolved
Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of other changes.

@peternewman
Copy link
Member

peternewman commented Apr 27, 2020

So, I think there is a deletion, an updated of a comment and a minor fix or deletion listed above. Then we're good to go! 🎉

Can you confirm, have you re-run a few basic real world tests since all the changes?

Fixes for later (in a future PR, by one of us):

  • Indenting of groups (and groups of groups), this seems to behave a bit oddly (the indent by 2 everywhere), and I think is broken for groups of groups, as they don't indent themselves.
  • MissingPLASAPIDs exception should become MissingESTAPIDs, possibly one for just 0.11.0 as a technically breaking change, although I doubt it's explicitly caught anywhere - Py3 cmp #1605 (comment)
  • Refactor GetDescription - Py3 cmp #1605 (comment)
  • Add timeout-decorator stuff that got temporarily removed

@brucelowekamp
Copy link
Contributor Author

So, I think there is a deletion, an updated of a comment and a minor fix or deletion listed above. Then we're good to go! 🎉

Can you confirm, have you re-run a few basic real world tests since all the changes?

Fixes for later (in a future PR, by one of us):

  • Indenting of groups (and groups of groups), this seems to behave a bit oddly (the indent by 2 everywhere), and I think is broken for groups of groups, as they don't indent themselves.
  • MissingPLASAPIDs exception should become MissingESTAPIDs, possibly one for just 0.11.0 as a technically breaking change, although I doubt it's explicitly caught anywhere - #1605 (comment)
  • Refactor GetDescription - #1605 (comment)

I put (part of) my lightshow back up when quarantine began and checked today that my code still works with the python lib (in both 2.7 and 3.7).

Groups didn't look like it would be hard to fix the indenting on given an example pid and deciding what it should actually produce :)

@peternewman
Copy link
Member

Groups didn't look like it would be hard to fix the indenting on given an example pid and deciding what it should actually produce :)

Yeah agreed, I think we'd just need to have a ponder exactly what we wanted to do, and to generate some test examples.

Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Massive thanks to @brucelowekamp for getting this across the line and also for @nils-van-zuijlen for your initial work on it and @yoe for some advice along the way and anyone else I've missed.

Now to fix all the other bits of Python 3 compatibility 😆

@peternewman peternewman merged commit 451fd45 into OpenLightingProject:0.10 Apr 28, 2020
@peternewman peternewman linked an issue Apr 28, 2020 that may be closed by this pull request
@yoe
Copy link
Contributor

yoe commented Apr 28, 2020

I gave advice on python stuff? Oh dear. I do have a reputation to consider ;-P

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Python 3 Compatibility
4 participants