Commit Graph

51 Commits

Author SHA1 Message Date
Adeeb Shihadeh e077b5c2ff manager: kill UI when manager failed to start
old-commit-hash: edcee81796f335c87ec15c258f4f551a6fd21c55
2022-02-01 11:06:32 -08:00
Adeeb Shihadeh 543860d318 manager: don't start uploader with dongle id
old-commit-hash: 818d4a0a96cce12d9952c0a111f755fe7ac9fdc1
2022-01-25 15:42:38 -08:00
Ryan 0dbb4fb3b0 Add more type hinting (#23595)
* Add more type hinting.

* Revert joystick_alert changes.

* Add typing to statsd.

* Update selfdrive/statsd.py

* Update selfdrive/test/test_fingerprints.py

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: aa9e635311c4149b196f0c03afcb89d24106a62b
2022-01-21 15:11:16 -08:00
Adeeb Shihadeh fa8ba3617b sentry fixups (#23249)
* set env

* do init in same place

* no sentry for forks

* start session

* start session

* remove that

* val
old-commit-hash: b63bc89bc993648ec5cbe2b90b896ddae90077ed
2022-01-14 15:25:16 -08:00
Adeeb Shihadeh ccf91380f2 manager: log exit reason (#23532)
old-commit-hash: 308a6f1730d7347f530ad56aa609e47d8c5bf266
2022-01-14 08:55:51 -08:00
Willem Melching 729973f511 Do not disable loggerd when below 5% space (#23440)
old-commit-hash: 9e1428fd846b71394eefb5dcef8e8fc746437739
2022-01-13 10:31:37 +01:00
George Hotz 86a39e838b Add More Types for mypy (#23268)
* mypy passes

* a few more

* a few in manager

* more types, will lint

* more

* simple types

* events type

* Update selfdrive/thermald/thermald.py

* Apply suggestions from code review

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: dc96d4bee7b898172a6a15de4799af0e2d35605e
2021-12-28 18:07:00 +01:00
Adeeb Shihadeh 6fc218503c cloudlog: add daemon name to context for python daemons (#23225)
* python

* manager is a daemon too

* Update selfdrive/manager/process.py

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: b27a19e9d1cfe9e9f94ccb4978338ebe4a898bc3
2021-12-14 20:43:26 -08:00
Shane Smiskol ef38c36435 version.py: make function names more clear (#23216)
* rename a few version functions

* and is_prebuilt

* and some formatting 😊
old-commit-hash: b745a14ff71622fe1fe4c9c043c7d7694d23dc08
2021-12-14 12:15:13 +01:00
grekiki 9e4cc1f7ff Python: Replace more lists with generators (#23116)
* Replace lists with generators v2

* Replace set with {}

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>

* Replace more set() with {}

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 6951b3271d1770297cb6bd53878463035ec0bf43
2021-12-03 22:57:19 -08:00
Willem Melching 176f552c9e manager.py use get_short_branch() for GitBranch param
old-commit-hash: e8d56f241ad54730fd9458a9e1a481206ea27d52
2021-12-02 10:25:03 +01:00
Willem Melching 28dd415759 Do not run code on version.py import (#23063)
* Do not run code on version.py import

* fix athena
old-commit-hash: f7c46c694985456e569ce2313b29e43607c62a12
2021-11-29 19:38:55 +01:00
Willem Melching 1ae492370d Add LastPowerDropDetected and create bootlog before clearing params (#23062)
* Add LastControlledShutdown and create bootlog before clearing params

* update param name

* sorting
old-commit-hash: 7c8044d2dbb2ce74c0c622b468caec185e590d48
2021-11-29 15:51:27 +01:00
Adeeb Shihadeh 182a12fdca manager: kill procs in parallel (#23010)
* manager: kill procs in parallel

* oops block
old-commit-hash: ba67c355dbd032e4f6dfd95aaef519aa78c7c52a
2021-11-29 11:49:04 +01:00
Willem Melching 425349a55c swaglog.py: respect LOGPRINT env variable (#22950)
* swaglog.py: respect LOGPRINT env variable

* only change handler that prints

* keep usefull manager prints

* only print running list

* revert process changes

* fix test
old-commit-hash: 77b334a698300d6f763bfcc0210c32b6f2ae6f63
2021-11-18 16:05:06 +01:00
Willem Melching bb8d0aa76d Move shutdown/reboot handling to manager (#22882)
* Move shutdown/reboot handling to manager

* more logging

* check enagaged

* Apply suggestions from code review

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 07ff72472636237d7c47addfce4d8bbbda98e9d2
2021-11-12 09:10:34 -08:00
Willem Melching 06e22360ae Add DisableRadar_Allow param and settings toggle (#22329)
old-commit-hash: 8c01ae5716b558039946c07e63d42d16094037d2
2021-09-23 17:19:47 -07:00
Willem Melching 6f92abc815 Less open file permissions (#21922)
* Less open file permissions

* add test back

* remove params test for permissions

* remove umask

* bump cereal

Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: dddab597bcee0a103895509b7909743f97cbdf83
2021-08-28 18:25:05 -07:00
Adeeb Shihadeh 784601c8e1 remove lte toggle (#21392)
* remove lte toggle

* little more
old-commit-hash: a420c7ad50eec716e53537957b1439b2ce44d73e
2021-06-23 17:01:17 -07:00
Adeeb Shihadeh 03405b81fd acados support (#21319)
* acados support

* add pyextra to python path

* x86 libs
old-commit-hash: 6e4c2aa4d286bb43f091ad13820f564f70e4c0d7
2021-06-17 16:40:00 -07:00
Adeeb Shihadeh baa85548de don't write last update time param on pc
old-commit-hash: 29ac94b71997303fdd2cae137a1a3ccd016868e7
2021-06-07 14:07:08 -07:00
Adeeb Shihadeh 5a80518b52 tici, it's just like cici
old-commit-hash: 189ee62d002a765af4edf6a6689ef62c3c20599f
2021-05-25 20:36:50 -07:00
Willem Melching 9754f9fdc5 manager.py: fix UNREGISTERED_DONGLE_ID check (#21027)
old-commit-hash: ba5d6bbd702e35afad028fadd392d7ed8a2a8dc2
2021-05-25 17:26:25 +02:00
Adeeb Shihadeh 932486f4ef default lte param to on
old-commit-hash: 7a4d319035340bd5e472d673145d7189cef84605
2021-05-18 15:29:02 -07:00
Adeeb Shihadeh 8002b848b6 offroad alert for unregistered devices (#20870)
* offroad alert for unregistered devices

* update tests

* add param

* fix stretch
old-commit-hash: b93ccc465dbc8b847b65f7d062182465344dac4d
2021-05-11 03:18:45 -07:00
Adeeb Shihadeh 88434dc9e4 add CLEAR_ON_IGNITION param type (#20810)
old-commit-hash: b4447993c10b36628cb72b58dba8104c9060bb7f
2021-05-04 11:32:40 -07:00
Adeeb Shihadeh 8a759792c4 don't init sentry on non-comma remote
old-commit-hash: 5f3fe0100244cc519acdfd0c5f74d5c71dae0a62
2021-05-03 20:14:31 -07:00
Adeeb Shihadeh c9d5447edd registration unit tests (#20792)
* start tests

* more test

* done
old-commit-hash: 5b764ab47760f6b8b751cff074b245b988650051
2021-05-01 17:16:58 -07:00
Adeeb Shihadeh c7cca3b07e update registration policy (#20770)
* update registration policy

* move that

* handle 403

* fix that
old-commit-hash: 4d8a35d639739e9e00c5f5317e4489c4cb66524c
2021-04-28 14:09:13 -07:00
Adeeb Shihadeh 4c461b3f7f disable sentry for devices without a dongle ID (#20729)
* disable sentry for devices without a dongle ID

* import pc

* unused
old-commit-hash: 47ad2a485f927134ee2f93c497b1b6cb831def30
2021-04-23 11:29:38 -07:00
Willem Melching ab900874db manager.py: fix git commit param write outside of git repo
old-commit-hash: 01c5d7f7eddeaa19c5c776cb96a713689a3d92dd
2021-04-23 13:28:49 +02:00
Adeeb Shihadeh 3e4eb2e343 handle unregistered devices (#20728)
* handle unregistered devices

* cleanup

* no uploader or athena

* clean up
old-commit-hash: 1786d042396bcc079be5de33ed900f48effcec17
2021-04-22 21:03:57 -07:00
Willem Melching c0ca2ce743 Switch to new sentry_sdk (#20690)
* remove unused crash.install

* use sentry_sdk in crash.py

* athena crashes dont rely on excepthook

* make default crash handler work

* make it work in athena

* fixup tombstoned
old-commit-hash: ea0e61187298c9c02238ad673f5932f08aa6f0c7
2021-04-22 15:24:35 +02:00
Adeeb Shihadeh 6d04f375e0 upload raw on tici
old-commit-hash: a3df0e98273a93fc460f5ac699e3cb77edfecf62
2021-04-15 21:36:09 -07:00
Adeeb Shihadeh 50a73824f9 raw upload off by default
old-commit-hash: 9adaff5379e8634b4daf7f93b451eacc23b213c5
2021-04-14 21:06:30 -07:00
Adeeb Shihadeh f11dd415e8 update time from RTC on manager init (#20678)
* set time on manager init

* earlier

* handle exception

* logging

* add to release files

* run in launch script too

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 1adf34f033bc1efb592383ebb2dbaef909bac60b
2021-04-14 12:04:02 -07:00
Adeeb Shihadeh 89720ef6ce more apk cleanup (#20646)
* bump cereal

* cleanup

* little more

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 58dabdda00eae882b2290f7edd2d21dff81e3528
2021-04-10 14:53:51 -07:00
Willem Melching 51e12611ce use put_bool to set Passive
old-commit-hash: 2967e7929663147a5a99ce00f5f40df99dc53b3d
2021-04-09 17:56:50 +02:00
Willem Melching 8f4a445171 add putBool/getBool wrappers to cython params class (#20611)
* add putBool/getBool wrappers to cython class

* use new API

* some more puts

* fix mockparams arguments

* add get_bool to MockParams

* typo
old-commit-hash: ae094042ade44815fdba50196c15ba552bbf33d7
2021-04-07 15:36:37 +02:00
Greg Hogan 183d9f98a1 log to file and send through athena (#20250)
* log to file and send through athena

* rename logging level

* pass thru log formatter

* logMessage is TEXT

* send queue always strings

* switch to xattr and lower priority queue

* enable cloud logging for devices

* time or size based log rotation

* basename -> dirname

* remove HARDWARE.get_cloudlog_enabled

* fix errors

* fix another exception

* xattrs need to be bytes

* sending works

* cleanup files at start

* add id and adjust formatting

* do not send active log file

* better names

* separate log formatters

* fix formatter super init

* fix log file order

* ensure file always has file formatter

* i see why there was no formatter

* apply same formatting to cpp log msgs

* apply same formatting to cpp log msgs

* update queue names in tests

* strip deprecated keys in STATUS_PACKET

* strip DEPRECATED from dict recursively

* athena log queue test

* instanceof instead of type

* isinstance instead of type

* use super

* remove logentries

* last_scan param unused

* comment about special log msg attr names

* add dict_helpers.py to release files

* use monotonic time and counter for log rotation

* update for adjusted log file naming

* use monotonic clock for tracking last log file scan
old-commit-hash: 3d48bd934d6c84a5352c2a1d56e6f93ed59e28c4
2021-03-25 13:30:09 -07:00
Willem Melching 5c08699614 Start ui before manager preimport (#20468)
* start ui early

* test sets this afer import
old-commit-hash: 261045668bf7cf99c07f64034c7538aaeb227b9e
2021-03-25 17:27:15 +01:00
Adeeb Shihadeh 51c13aa552 APK purge (#20446)
* purge begins

* release files

* remove those

* no more android

* only qt

* text and spinner

* neos update script

* update sounds

* update cpu usage

* all done

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: e76c80ffa1b6167fd69465c66f31fbe475762330
2021-03-24 14:30:41 -07:00
HaraldSchafer eae1fa481c New KL model + laneless toggle (#20454)
* New model: 0bf38240-6b55-42b0-bcfb-da08ff5cd0b9/650

* laneless baby

* hardcode model difference for now

* kale toggle

* kale emoji

* sensible description

* make clear it is not just for ui

* emojis dont work yet

* 9671a8fe-539f-4a04-a163-54571df21139/650

* new model

* only read param on rising edge of ignition

* update toggle text

* fix that

* update refs

Co-authored-by: mitchell <mitchellgoffpc@gmail.com>
Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com>
old-commit-hash: 7ee79c99236f749d02a6779b006ee1ab187e0612
2021-03-24 01:10:31 -07:00
Adeeb Shihadeh 5cfc42911b Remove lane change toggle and default LDW to off (#20442)
* remove lane change toggle and default LDW to off

* update refs
old-commit-hash: 43ce7165c4eee9af167a650decdb8c3f11195d8d
2021-03-22 20:55:57 -07:00
Adeeb Shihadeh 1a0ac978ec record front lock (#20400)
* record front lock

* only if set

* add to internal installer

* move that

* change that bck

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: b60cd8d0a0a03b3c1f9f06cba1650a9afe8eb772
2021-03-18 20:15:51 -07:00
Comma Device 46f5cd3559 uncomment
old-commit-hash: 8111d78cf3e0c35c26dff511a80a706089c01ec4
2021-03-09 23:00:25 -08:00
Comma Device 4f26444344 smoother spinner transition on startup
old-commit-hash: 7a3d195f537230539566d7fe79940de9b77f099a
2021-03-09 22:59:43 -08:00
Shane Smiskol d670eb4125 Spinner: wait for UI to start (#20279)
* Impose a max rate for updating spinner progress

* fix import

* Show spinner until offroad is started

* no need for time

* Fix ROOT_DIR

* Fix fb include

* fix relative path

* don't touch these files

* Close spinner after all procs have started

* don't touch file

* Move up

* Revert changes to spinner, and only sleep on final progress update

* add this back

* revert time

* test sending 100

* test sending 100

* revert makefile changes

* rm 2nd 100% update

* pass spinner to thread function

* pass ignore list

* Default to None

Co-authored-by: Willem Melching <willem.melching@gmail.com>

Co-authored-by: Willem Melching <willem.melching@gmail.com>
old-commit-hash: a3556410deb187d7efd95631c970fc90d6861228
2021-03-09 13:37:11 -08:00
Adeeb Shihadeh 3ad7100cb4 fix manager crash on PC after going offroad
old-commit-hash: 7cfd6b1170f0ef46ad1df07821be9c6fd627cd25
2021-03-07 21:52:20 -08:00
Adeeb Shihadeh 8dc4500a83 fix uninstall after manager refactor
old-commit-hash: 745a4e884a6a91befe990bc26831d2a53bddac6d
2021-03-07 21:02:37 -08:00