Michael Hudson-Doyle
f2918fa30b
Merge pull request #550 from mwhudson/reprobe-block-devices-on-shell-exit
...
Reprobe block devices on debug shell exit
2019-10-09 15:37:23 +13:00
Dimitri John Ledkov
3e39db4013
Asciify color pallete
2019-10-07 22:30:23 +01:00
Dimitri John Ledkov
3f548665e1
Add ASCII mode
2019-10-04 17:17:26 +01:00
Michael Hudson-Doyle
7a3a88ab0c
add a signal that is fired when a debug shell exits
2019-10-04 15:10:11 +13:00
Michael Hudson-Doyle
36cdf0effd
some better names
2019-10-04 13:39:39 +13:00
Michael Hudson-Doyle
415db68e36
always use vt100 codes for white/black/default
...
For maximum compatibility in mono mode.
2019-10-04 13:39:39 +13:00
Michael Hudson-Doyle
cea3a65ca1
refactor how palettes and colors and screens are set up
2019-10-04 13:39:39 +13:00
Michael Hudson-Doyle
29c9e0c984
add a hot key (f4) for turning color on and off
2019-10-04 13:39:39 +13:00
Michael Hudson-Doyle
93732dfb73
fix run_command_in_foreground to disconnect from stdin while in backgound
...
Not sure how I didn't notice this when implementing it for the first
time but well. This is all fairly confusing.
2019-09-30 16:26:24 +13:00
Michael Hudson-Doyle
b6bf3fcc42
a bit too much effort making one particular log statement look nice
2019-09-09 15:32:49 +12:00
Michael Hudson-Doyle
0eb4dcfdfb
more logging tweaks
2019-09-09 15:27:56 +12:00
Michael Hudson-Doyle
ca6ebf84f4
only call is_linux_tty once
2019-09-09 15:27:34 +12:00
Michael Hudson-Doyle
5dca5e861e
remove some pointless wrapping of exceptions
2019-09-09 14:30:49 +12:00
Michael Hudson-Doyle
3d9cbeac95
light sanitization of log statements
2019-09-09 14:28:48 +12:00
Dimitri John Ledkov
25ed1e281f
Merge pull request #533 from mwhudson/app-specific-uis
...
allow the application to have a widget in the bottom right
2019-09-05 14:36:12 +01:00
Michael Hudson-Doyle
3f8c005237
allow console_conf and subiquity to use different UI classes
...
Subiquity is going to grow some global UI elements that console_conf
does not want.
2019-09-05 11:58:25 +12:00
Michael Hudson-Doyle
9a05653150
Tweak Controller API
...
* rename 'default' method to 'start_ui'
* add 'end_ui' hook
* add Application.cur_controller helper
2019-09-04 15:18:45 +12:00
Michael Hudson-Doyle
3605514d30
extract some methods out of Application.run
2019-09-03 13:14:17 +12:00
Michael Hudson-Doyle
43f414da1f
add a way to suspend the subiquity UI and run some other command
...
This will be used for the drop to shell functionality and also to allow
viewing an error report before we submit it to daisy.
It is almost but not quite surprisingly easy (I added a long-ish comment
about the difficulties).
2019-08-23 11:19:21 +12:00
Michael Hudson-Doyle
1947abcc5e
fix mismerge self.common["loop"] vs self.loop
2019-08-20 10:34:31 +12:00
Dimitri John Ledkov
1dfffbda01
Merge pull request #523 from mwhudson/run_in_bg-fd-leak
...
fix fd leak in run_in_bg
2019-08-19 11:30:52 +01:00
Michael Hudson-Doyle
b38f47bf42
Merge branch 'master' into core-cleanups
2019-08-16 14:24:56 +12:00
Michael Hudson-Doyle
9b7eb8883c
fix fd leak in run_in_bg
...
Notices this while debugging something entirely different.
2019-08-15 13:59:29 +12:00
Michael Hudson-Doyle
90d376fbbd
put the terminal into raw mode
...
For whatever reason, urwid puts the terminal into cbreak mode during
initialization. If we put the terminal into raw mode instead, then we
don't have to ignore SIGINT and SIGQUIT, which is good, because when we
support dropping to a subshell we don't want to run that subshell with
those signals ignored, because that is extremely confusing.
This also lets me dump the code that puts the terminal into raw mode
during keyboard detection.
2019-08-15 13:50:23 +12:00
Michael Hudson-Doyle
518e52e8e2
move "global" key handling to an unhandled_input handler
...
The only observable difference here is that ctrl-x now exits in dry-run
mode when a pop up is open.
2019-08-15 13:34:10 +12:00
Michael Hudson-Doyle
98908e91b2
get rid of silly common dictionary that was passed around a bit everywhere
2019-08-15 13:33:38 +12:00
Dimitri John Ledkov
e46de5def8
Drop Installpath
2019-05-14 15:09:55 +02:00
Michael Hudson-Doyle
bdf33a2adf
make SubiquityModel objects easier to construct
...
So I can write a unittest more easily.
This involves shuffling around how locale changes are done but as my new
design document says the "controller also manages the relationship
between the outside world and the model and views" this does make things
more consistent.
2019-05-10 09:44:01 +12:00
Michael Hudson-Doyle
3e8bc81190
add some logging around moving between screens
...
my best guess at why CI is currently hanging sometimes is that the
'next-screen' signal is being sent too often / too early. add some
logging around this so that we will be able to confirm / deny this by
reading the logs.
2019-04-18 10:22:05 +12:00
Dimitri John Ledkov
488f6fd2c0
Lock answers file.
2019-04-12 17:36:12 +01:00
Michael Hudson-Doyle
7cc56a8b58
trying to debug edge ci failures
...
* add a bit more logging
* wait for initial network apply to finish before moving on from
network screen
2019-04-04 12:06:41 +13:00
Michael Hudson-Doyle
b169d35316
display any error received when checking for updates
2019-03-12 11:49:03 +13:00
Michael Hudson-Doyle
b91c961165
implement screens up to the point of offering the update
...
don't display anything about check failures yet, or actually allow the
user to start the update
2019-03-12 11:49:03 +13:00
Michael Hudson-Doyle
9aea579027
support a controller being shown more than once
2019-03-12 11:48:58 +13:00
Michael Hudson-Doyle
a51f04b02c
start network probing after all signals have been connected
2019-03-07 15:31:39 +13:00
Michael Hudson-Doyle
6e077ef457
move code for configuring snapd proxy out of snaplist controller
2019-03-07 15:18:34 +13:00
Michael Hudson-Doyle
d0c41469a7
remove login model/controller/view from subiquitycore
...
long ago subsumed into other code
2019-03-07 14:01:52 +13:00
Michael Hudson-Doyle
9937ebe6e1
add a more systematic way for controllers to record their state
...
so we can return the point where the user left off on update
2019-03-06 15:55:15 +13:00
Michael Hudson-Doyle
98bf6a4254
add a way for a controller to be skipped
...
will need this for the refresh screen if there is no update
2019-03-06 15:32:31 +13:00
Michael Hudson-Doyle
b77aa9499e
make sure all delays during replaying answers repsect SUBIQUITY_REPLAY_TIMESCALE
2019-02-21 11:07:54 +01:00
Dimitri John Ledkov
0d35fa613c
core: special case s390x vt220 console on /dev/ttysclp0, as it supports colors.
2018-11-23 01:24:34 +00:00
Ryan Harper
d7c8b1111b
pep8 fixes for subiquitycore/core.py
2018-05-24 16:59:31 -05:00
Ryan Harper
9159cd0003
pep8 fixes for subiquitycore/core.py
2018-05-24 16:51:51 -05:00
Michael Hudson-Doyle
384dadc5ed
hack to stop ThreadPoolExecutor blocking exit
2018-05-21 11:58:10 +12:00
Michael Hudson-Doyle
35c08f1d6f
up thread pool limit
...
otherwise we can only do one thing at once! many of the things
we do in the background do not really require an OS thread but oh well
2018-05-18 12:33:25 +12:00
Michael Hudson-Doyle
5a6d0ac90f
a docstring
2018-05-01 13:00:27 +12:00
Michael Hudson-Doyle
acdd3bdec7
refactor a bit
2018-05-01 12:57:03 +12:00
Michael Hudson-Doyle
58d64eb419
over engineered way to delay command-line supplied script invocation
...
use this to allow click helper to wait for a button to appear
2018-05-01 12:49:39 +12:00
Michael Hudson-Doyle
db4d8a537e
add a way to specify actions to take in the UI on the command line
...
--script takes a little python snippet to run in a helpful namespace
--click is a wrapper around --script to click a button
2018-05-01 12:29:29 +12:00
Michael Hudson-Doyle
1794ed53dd
implement keyboard selection ( #276 )
...
A new screen immediately after language.
2018-02-08 10:37:22 +13:00
Michael Hudson-Doyle
ad9c527b51
touch /run/casper-no-prompt if answers are supplied
2017-12-21 11:40:51 +13:00
Michael Hudson-Doyle
e211f67b72
permit myself one bit of clever code
2017-11-22 12:16:09 +13:00
Michael Hudson-Doyle
ab9e382387
remove some more leftover bits
2017-11-22 12:05:30 +13:00
Michael Hudson-Doyle
20d4e04efd
streamline a bit, add comments
2017-11-22 11:49:20 +13:00
Michael Hudson-Doyle
225a7637ca
move color scaffolding into core
2017-11-22 11:37:49 +13:00
Michael Hudson-Doyle
918a1979b3
stop modifying the xterm palette at all and use ISO 8613 3 codes instead
2017-11-22 11:26:47 +13:00
Michael Hudson-Doyle
cfbc4ffc0c
more precise color rendering in xterm-like terminals
2017-11-21 15:24:07 +13:00
Michael Hudson-Doyle
6919e5ce68
minimal implementation of canned answers
...
this allows automation of the enter-enter-enter flow, not much more than that
2017-11-17 13:25:16 +13:00
Michael Hudson-Doyle
8086d5df81
move to a unified model instance
...
and stop having the controllers construct each model instance for itself
2017-11-16 12:48:20 +13:00
Michael Hudson-Doyle
bf85eaf05f
do not overwrite the top 8 colors of the palette with black
2017-10-10 21:58:54 +13:00
Michael Hudson-Doyle
e3aadb195b
add a way to run console-conf or subiquity with a subset of the screens
2017-10-10 09:21:42 +13:00
Michael Hudson-Doyle
cd85358a1b
overwrite more of the console palette
2017-09-28 09:58:09 -04:00
Michael Hudson-Doyle
86ac32905b
change the progress bar to show x / y rather than a %age
...
Also make its progress more automatic.
2017-09-26 09:01:22 -04:00
Dimitri John Ledkov
00c4fe935b
Setup orange for fbterm too
2017-09-12 14:28:08 +01:00
Michael Hudson-Doyle
7a09db2cd4
ridiculous stuff to show ubuntu orange on the linux tty
2017-09-08 15:59:30 +12:00
Michael Hudson-Doyle
34f1e67d49
make it possible for subiquity and console_conf to use different colours
2017-09-07 21:37:48 +12:00
Michael Hudson-Doyle
3f425c9e05
make the netplan file name and path depend (very slightly) on subiquity vs console-conf
2017-03-16 22:52:05 +13:00
Michael Hudson-Doyle
66c1d94a4b
consolidate mountpoint validation a bit
2017-03-07 21:10:03 +13:00
Michael Hudson-Doyle
a4d6682478
simpler api for doing stuff in a background thread
2017-01-18 12:03:56 +13:00
Michael Hudson-Doyle
fa95fb55ad
make callfromthread functionality more available, use it in installprogress
2017-01-18 12:02:34 +13:00
Michael Hudson-Doyle
8ede2d730c
and with that, we no longer depend on tornado
2017-01-18 12:02:34 +13:00
Michael Hudson-Doyle
6febf16d22
clean up some silly stuff in core.py
2017-01-13 15:08:31 +13:00
Michael Hudson-Doyle
17b943209e
remove subiquitycore/async.py
...
it was just a glorified global variable.
2017-01-13 15:08:31 +13:00
Michael Hudson-Doyle
ae05b66a47
rewrite Selector to work like an HTML <select> widget
...
This was way way harder than it seemed like it should be, but it seems a lot
nicer to me.
For https://bugs.launchpad.net/ubuntu/+source/subiquity/+bug/1654387
2017-01-09 16:11:32 +13:00
Michael Hudson-Doyle
8020dd38c7
address review comments
2016-09-29 14:06:09 +13:00
Michael Hudson-Doyle
d9095336e5
do not have controllers (or view code!!) know the order of the screens
2016-09-27 21:35:47 +13:00
Michael Hudson-Doyle
d6cf8e1bcf
prevent C-c / C-x from exiting console conf
...
I've left C-x as a way to get out in dry-run mode as that's useful for
debugging.
2016-08-31 10:58:26 +12:00
Michael Hudson-Doyle
e95daf25ba
Re-introduce 'subiquity' package for installer specific things.
...
Only move the Application object for now.
2016-07-25 12:51:39 +12:00
Michael Hudson-Doyle
173fdcb77f
rename subiquitycore.core.Controller to Application
...
Also CoreControllerError -> ApplicationError
2016-07-25 12:38:19 +12:00
Mathieu Trudel-Lapierre
f6bb666c4d
Simplify defining core with only the general flow.
...
Signed-off-by: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com>
2016-06-30 14:50:21 -04:00
Mathieu Trudel-Lapierre
e1970b6477
Rename subiquity to subiquitycore -- will serve as base classes for everything
...
Signed-off-by: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com>
2016-06-30 14:17:01 -04:00