-
Notifications
You must be signed in to change notification settings - Fork 6
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
Port to Gtk3 and Python3 #9
Conversation
Reviewed, thanks. a1c423b contains changes not included in the commit message. Starting a server throws this error,
0493182 could have a better commit message. You can consider demoting logging as the logs seem to be noisy. As this is a Also consider fixing #7. Kindly test your changes before making a PR. |
Please review and re-use any changes from #4 which was closed after progress stalled. When re-using, use "git commit --author" to credit properly. |
@quozl Reviewed #4 didn't find anything . The changes are almost same.
The steps for installation are-
|
The installation steps are not practical. A child learner or elementary school teacher won't be able to follow those steps, because they are too complex, or because they require administration rights. The x11vnc file is also very very old, so we can't use it. See #7 for how this should be fixed. |
There's a checklist in #7, you can take a look at it. To elaborate, use distro specific binaries as the ones used in the activity are old and have vulnerabilities. |
Sorry, I did think it was obvious, and surprised I have to explain. 😁 Rephrasing part of #7, It is much the same reason why we don't include In future, strategic plans for an issue are best discussed in the issue; #7, otherwise we fragment the discussion. |
I think the fix for #7 needs to be incorporated here so we can know if the activity works as intended and why are you looking for all dependencies related to x11vnc if I may ask? The idea behind #7 is using a distro specific binary when available, pkgs.org lists the You'll want to;
The x11vnc homepage might be of help. |
I agree, it should be straightforward, and you don't need to know the dependencies of x11vnc as these will be handled automatically by whatever package management system is used. It may help to understand why this situation happened. The activity was written for the OLPC XO laptop. Activities could not depend on the ability to install dependencies, because they did not run as root, and there was an amazing security system called Bitfrost. So activities that needed dependencies ended up with embedded binaries, which complicated their maintenance but got the job done. Now, the activities don't have to focus on the same environment, and we can assume that the user has the capacity to install dependencies if needed. This does mean that any user who downloads the .xo bundle from a Sugar app store won't necessarily be able to install the dependency, which is why the warning is needed. |
I think adding a script for it is a bit overkill, you can just include
instructions for some distros in the Readme - there's an existing commit
you can look at for such -.
…On Sat, May 2, 2020, 3:07 PM Saumya Mishra ***@***.***> wrote:
@chimosky <https://github.com/chimosky> @quozl <https://github.com/quozl>
Thanks for your suggestions. Now I am thinking to include a script related
to installation of x11vnc which must work on all distros possible.. and I
will add steps for running the script in Readme. Will It be good or not,
You both suggest please.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AD3UAOREJOCMKNCOKBROOTLRPQSJFANCNFSM4L2MM2ZA>
.
|
@Saumya-Mishra9129, thanks for the offer, but I don't think a script is needed. Let me put this activity into perspective.
It's 2006. When the OLPC XO was produced, classroom displays and projectors were rare and expensive, and usually were not available in the third-world global-south where we wanted to deploy the laptops. So we did not include an external socket for connecting to them. This saved cost, risks of a physical gap in the casing, risks of electrostatic discharge damage, risks of a VGA connector being used to bend the circuit board when someone tripped over a cable, and VGA connectors had a limited lifetime of several hundred insertion removal cycles. We also increased a focus on collaboration via wireless networking. Sugar was part of OLPC XO product and was not easily available on other computers. It's 2008. The VNC Launcher activity was also created, by volunteers, to provide a way for teachers in first-world scenarios to use a projector with an attached computer. It's 2020. What has changed since then;
I don't recommend spending much effort in maintaining this activity. It is such a small corner case, and the people who need it will have the skills to follow instructions. They won't need a script. We also can't afford to maintain a script against changes made to all distros. Hope that helps! |
Yeah!! It will help for sure. Now I think including instructions for some distros in the Readme will be enough for it. Thanks |
Perhaps we can think here for releasing new version as specified in #1 . Also activity doesn't specify a license. |
I guess so. Users of this activity are teachers, and the instructions from 2011 do give some indication. If you think teachers won't be able to use IP addresses, then I guess the next thing to try is registering an mDNS name on the network and having the VNC client use that. |
@JuiP Can you please look and plan for a new release of activity?
Can we plan a release now, and leave it as I tried to find out the ways , I got to know about python3-avahi but it is not supported by all linux distributions, I couldn't find it for Ubuntu. |
PyGObject has an Avahi API. I've not used it.
|
Yeah I saw about this. But I have no experience with this and how this works. I am planning to work on this. But for now it would be out of scope of this pull request. I will make a new one probably after implementing Avahi. |
Please read the manual page for Tested.
That said, it does work. |
configparser accepts <class 'str'> as *args. Boolean and integer args had to be converted to str
Fixes TypeError: Expected a Vte.CursorBlinkMode, but got str
TypeError: Must be number, not str
configparser accepts str as argument. Boolean and integers values need to be converted to str first
Vte didn't had focus to begin with. Workaround was to click in the widget first
a007853
to
05995ea
Compare
Re: my earlier comment #9 (comment) ... I still don't see this winning any users. As far as I can see from the limited information; a teacher would have to install this activity on her device, install x11vnc on her device, then for each child device install a VNC viewer, and teach the child how to type a Terminal command. Where's the corresponding viewer activity? This search is interesting; there's a viewer that isn't on GitHub yet. (Also, for history, one of the reasons the activity existed was because the OLPC XO had no external monitor socket, and teachers with classroom projectors needed a way to show the Sugar desktop from an XO using their Windows classroom system. They would install this activity on the XO, a VNC viewer on their Windows system, and demo from there. The method we eventually settled on at OLPC was to sell USB to VGA adapters. Now, the latest OLPC hardware has external monitor sockets.) |
In 51344d9, I tried to give a feature by which when a user installs activity for the first time, he/she will be automatically able to install x11vnc without a need to type terminal commands. I tested it with Ubuntu and Debian, If @chimosky can test this with fedora then it will be good to go.
Thanks I saw this , but no information where source code can be found. Should we try to contact to Author of the Xo VNC Viewer. ?
I couldn't find a way to use x11vnc 's avahi option. I am trying to find out a way.
Actually I think it is a easy way to install RealVNC this way. Setting up TightVNC with terminal is so complex , It requires a large setup. Downloading this way can work on Windows and Linux both as you mentioned about windows also above. |
vnclauncher.py
Outdated
if platform.version().find("Ubuntu") > -1 or platform.version().find("Debian"): | ||
cmd = "apt install x11vnc" | ||
if platform.version().find("Fedora") > -1: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might be better to use platform.linux_distribution()[0]
because on fedora systems, platform.version().find("Fedora")
will always return -1
as Fedora
isn't part of the string returned by platform.version()
. Although it's deprecated in python>=3.5.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Find a way to check for Fedora
distros.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
platform.platform()
contains the necessary information.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Done in c733b9b.
@quozl said
I agree. |
@Saumya-Mishra9129 wrote:
What for? We have the activity bundle, isn't that enough to begin with? An ideal VNC activity would offer a "share my desktop" button, support Sugar Toolkit collaboration, and joiners would automatically start a VNC viewer, perhaps in read-only mode. Obtaining the IP address through the collaboration stack is fairly easy, see the Level activity for details. |
- add x11vnc dependency for Fedora , Ubuntu and Debian. - add info required to install VNC Viewer. - Modify how to use section
05995ea
to
c733b9b
Compare
Thanks. Updated checkboxes. |
a6cf893
to
c2367cf
Compare
The activity was written for an OLPC XO years ago, which had one network device wlan0, which would have one IP address. Nowadays, We use sugar on laptops and computers with both wireless and wired network connections. The patch displays all the IP(IPv4 and IPV6) addresses assigned to your system (Wired and Wireless)
c2367cf
to
477d141
Compare
The activity is working as expected.
The Pr includes-
Port to Gtk3
Python3
Fixes #2.
Fixes #3.
Fixes #7.