Closed ljgonzalez1 closed 1 year ago
Hi there! As you're new to this repo, please make sure you've used an appropriate issue template and searched for duplicates (it helps us focus on actual development!). We'd also like to suggest that you read our contribution guidelines and our code of conduct. Thanks a bunch for opening your first issue! 🙏
As the error and docs state, you cannot build aw-server-rust on Rust stable. You need Rust nightly: https://rust-lang.github.io/rustup/concepts/channels.html
On Mon, Jan 9, 2023, 19:03 github-actions[bot] @.***> wrote:
Hi there! As you're new to this repo, please make sure you've used an appropriate issue template https://github.com/ActivityWatch/activitywatch/issues/new/choose and searched for duplicates (it helps us focus on actual development!). We'd also like to suggest that you read our contribution guidelines https://github.com/ActivityWatch/activitywatch/blob/master/CONTRIBUTING.md and our code of conduct https://github.com/ActivityWatch/activitywatch/blob/master/CODE_OF_CONDUCT.md . Thanks a bunch for opening your first issue! 🙏
— Reply to this email directly, view it on GitHub https://github.com/ActivityWatch/activitywatch/issues/837#issuecomment-1376035590, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAKXDOVCWNXXBFOANGEWJJ3WRRHIZANCNFSM6AAAAAATVW5NQY . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Oh, you are right. Thank you very much, and sorry for that.
Leaving this mostly for other people who skip steps like me and encounter the same problem:
Just ran this to change to rust nightly:
rustup toolchain install nightly && \
rustup run nightly rustc --version && \
rustup default nightly && \
rustup update
Checked dependecies (now rust shows as nightly):
echo "GIT:" && git --version;
echo "\nMAKE:" && make --version | head -n 1;
echo "\nPYTHON:" && python --version || python3 --version;
echo "\nPOETRY:" && poetry --version;
echo "\nNODE:" && node --version;
echo "\nRUST:" && cargo --version;
echo "\n7z:" && echo "$(7z)" | head -n 3 | tail -n 1
GIT:
git version 2.34.1
MAKE: GNU Make 4.3
PYTHON: Python 3.9.16
POETRY: Poetry (version 1.3.1)
NODE: v12.22.9
RUST: cargo 1.68.0-nightly (8c460b223 2023-01-04)
7z: p7zip Version 16.02 (locale=es_CL.UTF-8,Utf16=on,HugeFiles=on,64 bits,8 CPUs Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (906E9),ASM,AES-NI)
- Recompiled with `make build`.
- 🎉 This time plex compiles 🥳.
«...» Compiling aw-transform v0.1.0 (/home/luis/git/activitywatch/aw-server-rust/aw-transform) Compiling fern v0.6.1 Compiling rocket_cors v0.6.0-alpha1 (https://github.com/lawliet89/rocket_cors?rev=54fae07#54fae070) Compiling plex v0.2.5 Compiling uuid v1.2.1 Compiling gethostname v0.4.0 «...»
-
- There were some problems importing the aw_server module due to not changing to the correct folder in the Makefile. It said:
Traceback (most recent call last):
File "
so I replaced the line 59 from `python -c "import aw_server; print(aw_server.__version__)"` to `python -c "import importlib; aw_server = importlib.import_module('aw-server.aw_server'); print(aw_server.__version__)"`
-
- Failed again.
Traceback (most recent call last):
File "
-
- A bit tired. I surrender... for now. I'll try to build later/ another day.
---
### The good thing is that the rust related problem was solved. So, thank you very much @ErikBjare 😄
OS name and version: KDE Neon. An Ubuntu 22.04 based distro.
ActivityWatch version: Latest commit on master branch in github (09/01/2023 14:10 GMT-3)
Describe the bug
Program failed to compile from source due to problems related with plex. Can't give too much detail as I don't know the language well enough.
As far as I know the problem is from rust or rust-related. It says
#![feature(*)
sould not be used in a stable release and then it fails to compile.It is somewhat related to the issue #763, but there's not a lot of info in the issue and there was not a clear solution either.
To Reproduce
Steps to reproduce the behavior:
git clone https://github.com/ActivityWatch/activitywatch.git --recursive
cd ./activitywatch
MAKE: GNU Make 4.3 Built for x86_64-pc-linux-gnu Copyright (C) 1988-2020 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
PYTHON: Python 3.9.16
POETRY: Poetry (version 1.3.1)
NODE: v12.22.9
RUST: cargo 1.65.0 (4bc8f24d3 2022-10-20)
7z: 7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21 p7zip Version 16.02 (locale=es_CL.UTF-8,Utf16=on,HugeFiles=on,64 bits,8 CPUs Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (906E9),ASM,AES-NI)
if [ -e "aw-core/.git" ]; then \ echo "Submodules seem to already be initialized, continuing..."; \ else \ git submodule update --init --recursive; \ fi Submodules seem to already be initialized, continuing... pip install 'setuptools>49.1.1' Defaulting to user installation because normal site-packages is not writeable Requirement already satisfied: setuptools>49.1.1 in /usr/local/lib/python3.9/site-packages (58.1.0) make --directory=aw-core build make[1]: Entering directory '/home/luis/git/activitywatch/aw-core' poetry install Installing dependencies from lock file
«...»
Installing the current project: aw-watcher-window (0.2.0)
if macOS, build swift
if [ "Linux" = "Darwin" ]; then \ make build-swift; \ fi make[1]: Leaving directory '/home/luis/git/activitywatch/aw-watcher-window' make --directory=aw-server build SKIP_WEBUI= make[1]: Entering directory '/home/luis/git/activitywatch/aw-server' mkdir -p aw_server/static/ make --directory=aw-webui build DEV= make[2]: Entering directory '/home/luis/git/activitywatch/aw-server/aw-webui'
npm ci npm WARN deprecated stable@0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility npm WARN deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
«...»
WARNING Compiled with 2 warnings 14:46:07
warning
asset size limit: The following asset(s) exceed the recommended size limit (244 KiB). This can impact web performance. Assets: js/3097.fd7a90af.js (414 KiB) js/chunk-vendors.906b2183.js (943 KiB) js/6604.55c4d043.js (269 KiB)
warning
entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance. Entrypoints: index (1.16 MiB) css/chunk-vendors.82a142ae.css js/chunk-vendors.906b2183.js css/index.442e69e5.css js/index.723cfbad.js
«...»
dist/css/3467.547af20e.css 0.06 KiB 0.08 KiB dist/css/9663.380cc15a.css 0.06 KiB 0.08 KiB dist/css/5953.cd69135e.css 0.04 KiB 0.06 KiB
Images and other types of assets omitted. Build at: 2023-01-09T17:46:07.251Z - Hash: 098d290603da17ed - Time: 51574ms
DONE Build complete. The dist directory is ready to be deployed. INFO Check out deployment instructions at https://cli.vuejs.org/guide/deployment.html
make[2]: Leaving directory '/home/luis/git/activitywatch/aw-server/aw-webui' cp -r aw-webui/dist/* aw_server/static/
Needed for https://github.com/ActivityWatch/activitywatch/pull/274, works around https://github.com/pypa/pip/issues/6279
https://github.com/ActivityWatch/activitywatch/pull/367 Other solutions have been tried but did not actually work.
If you aren't sure windows long paths are working, don't remove this
rm -rf aw-webui/node_modules/.cache poetry install Installing dependencies from lock file
No dependencies to install or update
Installing the current project: aw-server (0.12.0) make[1]: Leaving directory '/home/luis/git/activitywatch/aw-server' Looking for rust... /home/luis/.cargo/bin/cargo Rust found! make[1]: Entering directory '/home/luis/git/activitywatch/aw-server-rust' cargo build --release --bin aw-server Compiling version_check v0.9.4 Compiling libc v0.2.137 Compiling proc-macro2 v1.0.47 Compiling quote v1.0.21 Compiling unicode-ident v1.0.5 Compiling syn v1.0.103 Compiling autocfg v1.1.0 Compiling cfg-if v1.0.0 Compiling typenum v1.15.0 Compiling memchr v2.5.0 Compiling generic-array v0.14.6 Compiling serde_derive v1.0.147 Compiling serde v1.0.147 Compiling log v0.4.17 Compiling futures-core v0.3.25 Compiling getrandom v0.2.8 Compiling rand_core v0.6.4 Compiling ahash v0.7.6 Compiling slab v0.4.7 Compiling futures-channel v0.3.25 Compiling futures-task v0.3.25 Compiling tokio v1.21.2 Compiling futures-util v0.3.25
«...»
Compiling aw-transform v0.1.0 (/home/luis/git/activitywatch/aw-server-rust/aw-transform) Compiling uuid v1.2.1 Compiling plex v0.2.5 Compiling gethostname v0.4.0 error[E0554]:
#![feature]
may not be used on the stable release channel --> /home/luis/.cargo/registry/src/github.com-1ecc6299db9ec823/plex-0.2.5/src/lib.rs:2:12 | 2 | #![feature(proc_macro_diagnostic)] | ^^^^^^^^^^^^^^^^^^^^^error[E0554]:
#![feature]
may not be used on the stable release channel --> /home/luis/.cargo/registry/src/github.com-1ecc6299db9ec823/plex-0.2.5/src/lib.rs:3:12 | 3 | #![feature(proc_macro_span)] | ^^^^^^^^^^^^^^^For more information about this error, try
rustc --explain E0554
.error: could not compile
plex
due to 2 previous errors warning: build failed, waiting for other jobs to finish... make[1]: [Makefile:19: aw-server] Error 101 make[1]: Leaving directory '/home/luis/git/activitywatch/aw-server-rust' make: [Makefile:36: build] Error 2