Commit Graph

404 Commits (mark-ii/log-rotation)

Author SHA1 Message Date
Chris Veilleux 8f4f7fbaaf Add a new logger implementation that will eventually replace the old one. 2022-03-11 14:49:15 -06:00
Michael Hansen 497fe7be66 Fix portal check 2022-03-04 22:16:46 -05:00
Michael Hansen 626dc91b5a Use Mycroft page for captive portal check 2022-03-04 15:31:13 +00:00
Michael Hansen aa72f6420d Detect captive portal page, show browser in wifi connect skill 2022-03-01 22:03:41 +00:00
Michael Hansen b3cf7458a7 Use importlib for plugins instead of deprecated pkg_resources 2022-01-13 18:16:44 -05:00
Chris Veilleux abab1e9bda Merge branch 'feature/mark-2' into feature/mark-2-boot
# Conflicts:
#	mycroft/client/enclosure/mark2/interface.py
2021-12-30 12:06:14 -06:00
Michael Hansen a3c272c5e7 Add run_background in Activity 2021-12-16 17:11:04 -05:00
Michael Hansen 3c22bda38c Refactor and clean up code for wifi connect 2021-12-14 19:23:07 -05:00
Michael Hansen 56e6a4eb0f Add comment to network_utils 2021-12-09 17:55:32 -05:00
Michael Hansen a303177ed5 Check wifi/ethernet device states directly for connectivity 2021-12-08 15:17:56 -05:00
Michael Hansen 9e67748bea Use configuration for dbus address 2021-12-08 11:08:35 -05:00
Michael Hansen f0eb10d5ea Move some DBus code back into network_utils 2021-12-07 17:21:47 -05:00
Michael Hansen 8f0a5d65a4 timedatectl still failing in mark2 2021-12-07 16:28:12 -05:00
Michael Hansen 07c88b980d Add clock sync activity 2021-12-07 14:32:57 -05:00
Chris Veilleux ea5cf61361 Added a function to determine if time is synchronized via NTP and an activity in the enclosure service to leverage it. 2021-12-07 13:06:57 -06:00
Chris Veilleux 9819dbf2f7 Logging improvements 2021-12-02 16:04:37 -06:00
Michael Hansen 7f19bad4f3 Add unit tests for NetworkManager
==== Fixed Issues ====
Added unit tests for NetworkManager.
Restart DBus thread if an error occurs.
2021-12-02 11:07:47 -05:00
Michael Hansen 503c081d95 Add NetworkManager for checking connectivity
====  Tech Notes ====
Connects to org.freedesktop.NetworkManager over DBus to determine
connectivity status.

==== Environment Notes ====
Adds dbus-next Python package as a requirement
2021-12-01 16:15:02 -05:00
Kris Gesling be45edb54f autoformat 2021-12-01 09:32:24 +09:30
Åke Forslund 70df575d43 Make log settings not cache local only config
After startup the cached config would be without remote config. This
makes sure the config without remote isn't cached.
2021-11-09 21:04:58 +01:00
Kris Gesling 131a9ed03f PEP8 2021-11-04 20:53:00 +09:30
Gaëtan Trellu 0247b3a4b5
[log_format] Add an option to change the log format (#3016)
* [log_format] Add an option to change the log format

Hacing an option to change the log format could be useful when logs
are shipped into an aggregator such as Elasticsearch.

The current format is very hard to parse.

* [log_format] Set default Formatter

Because mycroft.configuration.Configuration() class import LOG class,
a default Formatter have to be defined before import the
mycroft.configuration.Configuration() class.
2021-10-29 14:59:22 +09:30
Kris Gesling 4df863633d Merge dev pre-XDG into feature/mark-2
This includes all commits up to but not including PR #2794
2021-08-17 15:56:42 +09:30
jarbasal 87d22d30a4 fix cyclic imports with LOG
The mycroft.util.log module called LOG.init() which needs to read the config,
the configuration module imports the log system to log causing cyclic import
issues.

This moves the LOG.init() call out of the log module making it possible
to use the normal config system to init the logs and does a slight
re-arrangement so that the uninited log can be used.
2021-08-05 10:04:45 +02:00
Åke Forslund 9029dc1f41 Slight cleanup
- Make XDG usage more visible by using the xdg module prefix
- fix overloaded python keywords
- remove unused imports
2021-08-05 10:04:45 +02:00
Åke Forslund 8e69d4616d Correct resolution order for resolving log configs 2021-08-05 10:04:45 +02:00
Bart Ribbers e20443b824 Use XDG Base directories for settings, cache and runtime data
Improve deprecation warning message
2021-08-05 10:04:45 +02:00
Kris Gesling a794db0c9a Make network tests configurable
Previously test URIs were hardcoded.
They can now be configured in mycroft.conf
2021-08-02 21:00:05 +09:30
ChanceNCounter a211441acc stop passing lang=None to Lingua Franca
LF's only breaking change over the past two versions has been the
deprecation of `lang=None` as a valid parameter. This is because the new
language loading paradigm wants to load certain functions on the fly,
which it cannot do when it is explicitly told to look for a null lang.

I've addressed this by passing `lingua_franca.get_default_lang()` where
the `lang=None` call remained.

Bonus: Gets rid of over 200 DeprecationWarnings in unit tests!
2021-06-23 21:56:19 -07:00
Kris Gesling 2c598fd96b Merge branch 'dev' into feature/mark-2 2021-06-15 12:01:18 +09:30
Åke Forslund cfc84bab27 Add approprate blank lines to fix phinxdoc warnings 2021-05-11 15:12:10 +09:30
Kris Gesling e75a05557b docstring cleanup 2021-05-11 15:10:32 +09:30
Kris Gesling 27cf725411 Merge branch 'dev' into feature/mark-2 2021-05-10 07:22:45 +09:30
Kris Gesling 6327ac5dbb
Upgrade Lingua Franca to v0.4.1 (#2890)
**Update Lingua Franca to v0.4.1**

The update from Lingua Franca v0.2.x to v0.4.x includes few
breaking changes.
- Some API methods have been updated.
- Mycroft-core tests have been updated to reflect improvements in
  Lingua Franca's formatting and parsing.
- add LF default lang setting method to config.locale 
  including warning that this method will change in the future
- Add TODO's for 21.08 - moving more methods to LF
- simplify loading and setting default of languages in Skills service
- Remove unneeded wrappers for Lingua Franca functions
- Fix documentation of format and parse utils
- Fix test warnings
2021-05-08 08:34:02 +09:30
Kris Gesling 784f166bc2 Raise TypeError rather than quietly fail 2021-05-03 20:13:21 +09:30
Kris Gesling 0fb90edd28 Rename to get_temp_path and add docstring 2021-04-30 16:49:59 +09:30
dzekem christa 7765d11224 ran autopep8 2021-04-30 14:48:15 +09:30
dzekem christa 3f745c52ad created temp path function 2021-04-30 14:47:49 +09:30
dzekem christa 621b4ab650 spaces added and uniformity in code 2021-04-30 14:46:36 +09:30
dzekem christa 9252158829 rectified pep8 issues 2021-04-30 14:46:36 +09:30
dzekem christa 32f666edd4 Issue-2727 - fixing hard coded /tmp 2021-04-30 14:46:36 +09:30
dzekem christa a174c3c822 replaced hard coded /tmp 2021-04-30 14:46:36 +09:30
Kris Gesling 6f1e708f34 Merge branch 'dev' into feature/mark-2 2021-03-31 21:38:16 +09:30
Åke Forslund 7bd27eb5df Make curate_cache() return removed files 2021-03-21 12:47:57 +01:00
Chris Veilleux 6ed674bd3e Merge remote-tracking branch 'origin/dev' into feature/mark-2
# Conflicts:
#	mycroft/audio/__main__.py
#	mycroft/client/speech/__main__.py
#	mycroft/skills/__main__.py
#	mycroft/util/process_utils.py
2021-02-26 11:49:30 -06:00
Ken Smith a7873cc22f Generic hardware enclosure capabilities should work with any device like your laptop or the Mark2. Provides a view of the default input devices (keyboards and mice) and default output devices (screens). Should be safe to merge to master also. 2021-02-09 16:28:48 -05:00
Kris Gesling cc3bf5b45a Change names for consistency 2021-01-28 17:21:33 +01:00
Åke Forslund bea1f008c6 Add ProcessStatus class
ProcessStatus tracks the process status and allows callbacks on changes
and status queries over the messagebus.

StatusCallbackMap is used to setup the callbacks

ProcessState is an enum tracking the different states.
2021-01-28 17:21:33 +01:00
Kris Gesling 767d2d6912 add whitelist arg to docstring 2021-01-11 16:57:25 +09:30
Kris Gesling ad32a7a873 move bus connect method to process_utils 2021-01-11 16:57:25 +09:30