Updates from Madison Scott-Clary (Makyo) Toggle Comment Threads | Keyboard Shortcuts

  • Madison Scott-Clary (Makyo) 6:07 pm on May 10, 2013 Permalink | Reply
    Tags:   

    Cloud Sprint 13.05 Work 

    A lot of interesting work took place at the 13.05 Cloud Sprint, and I figured I’d be a good idea to summarize some of them.  If I miss any or don’t go into enough detail, I’m sure other folks would be more than happy to add notes about additional work.

    • Test for resizing textarea breaks in IE10 – Different browsers report dimensions differently for different means of getting them (getComputedStyle, etc).  This is now tested across all browsers working around this problem
    • Containergeddon – Tests now use a makeContainer method for testing GUI elements, which allows these containers to be easily cleaned up in tear-down methods in test suites.  This leads to greatly reduced DOM trash during testing.
    • Pop-up help and keyboard shortcuts – Keyboard shortcuts are now created using a declarative syntax, which also allows a pop-up help system (with the shortcut “?”) that utilizes the same delcarations.
    • GUI hangs in internal views if the object is deleted elsewhere – Concurrent editing of the environment was causing problems with internal (e.g.: service or unit) pages.
    • Sandbox simulator – This branch adds an environment simulator to the sandbox env that mocks deltas coming in from a real environment.  This helps with development branches to ensure that the branch you’re working on currently takes concurrent editing into account.
    • Silent errors in certain instances – Some errors did not provide very much in the way of user feedback.  For instance, dragging a service caused a permission denied error in read-only mode due to annotations.  This was an incremental branch, with the end goal of implementing a read-only indicator.
    • Unscaled pack layout – This branches a portion of the D3 layout code so as to ensure that the pack layout does not scale to a minimimum area (such as the window size or a default size).  The end result is that the initial layout doesn’t overlap services, with the eventual goal being different possible automatic layouts in the future.
    • Feature flags – A little micro-branch that allows controlling features through the URL using our name-spaced routing.  For instance, the /:flags:/charmbrowser.draganddrop.enable URL would set that feature-flag to true so that the UI could, say, only enable drag and drop from the charm browser if the flag is set.

    Looking forward to a cycle full of interesting work!

    Advertisements
     
  • Madison Scott-Clary (Makyo) 8:02 pm on April 11, 2013 Permalink | Reply  

    If you’ve re-bootstrapped with juju-core and are running the GUI locally by modifying app/config-debug.js with the requisite details, note that you may need to delete the certificates from the bootstrap node in Firefox. To do so, go to Edit -> Preferences -> Advanced -> Encryption and click View Certificates. In the Servers tab, scroll down to juju and click the ‘*’ entry, then Delete. After restarting the browser, you can go to https:// [bootstrapAddress] :17070 and re-accept the certificate.

     
  • Madison Scott-Clary (Makyo) 5:39 pm on April 11, 2013 Permalink | Reply  

    If you ever run into the error “error: cannot find tools: use of closed network connection” while bootstrapping with core, you can get around it by deleting the tools directory from your S3 bucket and trying again. Sometimes it gets corrupted, it appears.

     
  • Madison Scott-Clary (Makyo) 6:18 pm on April 5, 2013 Permalink | Reply
    Tags: tablet   

    Developing for Ubuntu on a tablet 

    With the arrival of my loaner Nexus 10, I’ve been having fun getting a good development environment up and running for some definitions of fun: there are a few weird spots in the process. A lot of this comes from the wiki, but I think it’s good to have a list of steps handy for getting the environment up and running all in one place.

    1. Get set up for accessing the tablet

    First, you’ll need to get all of the tools handy for accessing the tablet from your development box. This includes the phablet tools as well as the tools for working with an Android device.


    sudo add-apt-repository ppa:phablet-team/tools
    sudo apt-get update
    sudo apt-get install phablet-tools android-tools-adb android-tools-fastboot

    Make sure that you can see the device from your computer:


    $ adb devices
    List of devices attached
    XXXXXXXXXXX device

    If it isn’t showing up, make sure that the adb server is up and running as root:


    adb root

    Next, flash the device with the latest daily build of Ubuntu for tablets (this presumes that the tablet came with Ubuntu already on it, as mine did. There are instructions for starting from Android). Note, the tablet must be up and running in the OS, not recovery or bootloader mode!


    phablet-flash -b -l

    The -b flag bootstraps the device – if you have already done this, you may leave it off. This will pull down all of the images needed for the tablet and install them onto the device.

    2. Setting the tablet up for remote control

    You’ll have to get SSH running on the tablet to effectively develop on the tablet, as logging in with the ‘phablet’ user allows you to start programs as that user. This takes a few steps:


    adb root # make sure the adb server is running as root
    adb shell
    ubuntu_chroot shell
    su - phablet

    This will get you into the tablet’s shell and the ubuntu container, and then running as the phablet user. From here, you can install openssh-server:


    sudo apt-get install openssh-server

    Once openssh is installed, grab the IP address with ip addr show wlan0 and then log out of the tablet (ctrl+D three times to get out of the nested sessions). Now you can ssh into the tablet with ssh phablet@[ip_addr] and the password “phablet”.

    3. Developing on the tablet

    The reason for setting the tablet up like this is so that you can use the Browser inspector tool. To do so, log into the tablet through ssh as above, and then run the browser app with the following command:


    webbrowser-app --inspector http://uistage.jujucharms.com:8080

    This will open UIStage (or, more usefully, you can provide the link to your current branch) in the browser and run the inspector. Pay attention to the command’s output, as it will give you a link for the inspector. You can visit that link in a browser on your development computer and use something very similar to Chrome’s developer tools.

    Good luck, happy tablet-ing!

     
    • Matthew Scott (Makyo) 3:19 pm on April 8, 2013 Permalink | Reply

      Note that, if you can’t ssh to the tablet from your local computer (if you get a ‘no route to host’ error, for example), you can always follow the instructions in step 2 up to `su – phablet`, then run `ssh localhost`

    • Matthew Scott (Makyo) 4:25 pm on April 8, 2013 Permalink | Reply

      Another note: breakpoints currently cause the browser to crash, so…cheers!

    • Matthew Scott (Makyo) 7:09 pm on April 8, 2013 Permalink | Reply

      Tip: refreshing the inspector refreshes the tablet view.

c
Compose new post
j
Next post/Next comment
k
Previous post/Previous comment
r
Reply
e
Edit
o
Show/Hide comments
t
Go to top
l
Go to login
h
Show/Hide help
shift + esc
Cancel