Giter VIP home page Giter VIP logo

clipboard-manager's People

Contributors

leb-kuchen avatar qs5779 avatar wiiznokes avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

clipboard-manager's Issues

Invalid handling of unicode

thread 'main' panicked at /rustc/c9f8f3438a8134a413aa5d4903e0196e44e37bbc/library/core/src/str/mod.rs:659:21:
byte index 50 is not a char boundary; it is inside 'r' (bytes 49..52) of `In Another Life 【slowed + reverb】`
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
^C

It is your formatted_value function in utils.rs
pop-os/cosmic-launcher#114

Mime type support

Currently, a clipboard value can be copied differently based on his mime type. So we can't just expose all mimetype that was used by source applications. We need to support the most commun one.

  • text
  • image
  • links
  • ... ?

And see how this could be done.

For image, we need to check if the db is appropriate

Image get duplicated

Steps to Reproduce

  1. copy an image
  2. copy text
  3. copy the same image from 1. form the clipboard manager

the image is duplicated

Does not work on cosmic alpha

Bug Description

$ /usr/bin/cosmic-ext-applet-clipboard-manager
2024-08-12T19:26:14.570739Z ERROR inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
2024-08-12T19:26:14.576757Z ERROR A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor

Expected Result

Expected to see an app icon and a clipboard manager

Steps to Reproduce

build and install per readme.md
run /usr/bin/cosmic-ext-applet-clipboard-manager

Possible Solutions (optional)

Possible Additional Information (optional)

Logs

Aug 12 15:26:14 dev cosmic-ext-applet-clipboard-manager[188903]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Aug 12 15:26:14 dev cosmic-ext-applet-clipboard-manager[188903]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor

subscription full error

[2024-04-13T14:18:20Z WARN iced_futures::subscription::tracker] Error sending event to subscription: TrySendError { kind: Full }

Build Error

Bug Description

When compiling I get the following error:

Compiling cosmic-ext-applet-clipboard-manager v0.1.0 (/home/theo/Applications/cosmic/clipboard-manager)
error[E0432]: unresolved import 'std::hash::DefaultHasher'
 --> src/db.rs:7:12
  |
7 |     hash::{DefaultHasher, Hash, Hasher},
  |            ^^^^^^^^^^^^^ no 'DefaultHasher' in 'hash'
  |
  = help: consider importing this struct instead:
          std::collections::hash_map::DefaultHasher

For more information about this error, try 'rustc --explain E0432'.
error: could not compile 'cosmic-ext-applet-clipboard-manager' (bin `"cosmic-ext-applet-clipboard-manager")` due to previous error
error: Recipe 'build-release' failed on line 33 with exit code 101

Expected Result

Finish compile

Steps to Reproduce

git clone https://github.com/wiiznokes/clipboard-manager.git
cd clipboard-manager
just build-release
sudo just install

Logs

--- No Entries ---

Error on installation

Bug Description:

got this error on installation

Logs, Panic Messages, Stack Traces:

cargo build -r
error: failed to parse manifest at /home/anik/cosmic-clipboard-manager/Cargo.toml

Caused by:
no targets specified in the manifest
either src/lib.rs, src/main.rs, a [lib] section, or [[bin]] section must be present
error: Recipe install failed on line 5 with exit code 101

Global shorcut

2 ways:

  • workarround with custom shortcut in cosmic-comp and listen d-bus
  • global shortcut from portal, but its not currently impl in cosmic

Build issue

Bug Description

Hi,

Im just create this issue for help user if you have the same issue.

Best Regards

error: linking with `cc` failed: exit status: 1
= note: /usr/bin/ld: cannot find -lsqlite3: No such file or directory
          collect2: error: ld returned 1 exit status

Expected Result

Steps to Reproduce

git clone https://github.com/wiiznokes/clipboard-manager.git
cd clipboard-manager
just build-release
sudo just install

Possible Solutions

https://users.rust-lang.org/t/how-to-fix-error-linking-with-cc-failed-exit-status-1/108922
Probably : sudo apt install -y sqlite3 but that not work for me... :(

data control new way

/etc/cosmic-comp/config.ron is not a thing anymore

Env var now.

Command:

sudo sh -c 'mkdir -p /etc/environment.d/ && echo COSMIC_DATA_CONTROL_ENABLED=1 > /etc/environment.d/cosmic-ext-applet-clipboard-manager.conf'

For packaging on fedora, use /usr/lib/environment.d/*.conf

see pop-os/cosmic-comp#600

require reboot

Applet doesn't work properly with a multi-monitor setup.

Bug Description

After adding it to the panel from the settings, it only appears on one of the panels in a multi-monitor setup.
image

Expected Result

It should appear on all panels on all screens.

Steps to Reproduce

  1. Use multiple screens with Panel setting "Show on display" set to "all".
  2. Try to add applet to the panel.

Db is blocked and panics

Apr 03 05:44:28 pop-os /usr/libexec/gdm-wayland-session[3497]: 2024-04-03T03:44:28.322726Z INFO cosmic-panel: cosmic_session::notifications: 2024-04-03T03:44:28.322652Z ERROR stderr{client=InnerClientId { ptr: 0x5f10f630da80, alive: false }}: com.wiiznokes.CosmicClipboardManager: 0: rust_begin_unwind
Apr 03 05:44:28 pop-os cosmic-session[3497]: 2024-04-03T03:44:28.319213Z ERROR stderr{client=InnerClientId { ptr: 0x5f10f630da80, alive: false }}: com.wiiznokes.CosmicClipboardManager: stack backtrace:
Apr 03 05:44:28 pop-os cosmic-session[3497]: 2024-04-03T03:44:28.319198Z ERROR stderr{client=InnerClientId { ptr: 0x5f10f630da80, alive: false }}: com.wiiznokes.CosmicClipboardManager: called Result::unwrap() on an Err value: Io(Custom { kind: Other, error: "could not acquire lock on "/tmp/welcome-to-sled/db": Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" }" })
Apr 03 05:44:28 pop-os cosmic-session[3497]: 2024-04-03T03:44:28.319164Z ERROR stderr{client=InnerClientId { ptr: 0x5f10f630da80, alive: false }}: com.wiiznokes.CosmicClipboardManager: thread 'main' panicked at src/app.rs:72:32:

FR: QR code

KDE have this feature and it could be useful sometime

db

  • change the database to use diesel (or not) (with a SQL backend probably)
  • is it suitable for image ?
  • in debug, the db doesn't seems to works as expected

Clipboard Manager Installation Failure in COSMIC

This report details the failure encountered while attempting to install the clipboard manager application for COSMIC desktop environment.

Environment:

Operating System: Pop!_OS 22.04 LTS (x86_64)
Device Model: VivoBook ASUS Laptop X513IA_M513IA 1.0
Kernel Version: 6.9.3-76060903-generic
Desktop Environment: COSMIC
Rust Version: stable-x86_64-unknown-linux-gnu (unchanged - rustc 1.80.1)
Clipboard Manager Source: [invalid URL removed]

Steps Taken:

Cloned the clipboard manager source code from the provided GitHub repository.
Installed dependencies: sudo apt install libsqlite3-dev sqlite3
Executed build command: just build-release
Attempted installation: sudo just install

Error Encountered:

The build process failed during the build-release step with exit code 101. Recipe build-release failed on line 28 with exit code 101

Clipboard manager no longer populating

Bug Description

Was working well for me for the past two weeks, but no longer works. Running latest source build, and latest cosmic packages (popdev) the applet is no longer capturing items copied to clipboard.

Expected Result

On copy, a new entry is added to the clipboard manager

Steps to Reproduce

  1. Pull latest (as of writing), build, and install
  2. Reboot
  3. Copy text from Firefox
  4. Click the clipboard-manager applet to reveal the history
    ER: Text copied from FF appears at top of list
    AR: List is empty

Logs

$ cat /etc/os-release
NAME="Pop!_OS"
VERSION="22.04 LTS"
ID=pop
ID_LIKE="ubuntu debian"
PRETTY_NAME="Pop!_OS 22.04 LTS"
VERSION_ID="22.04"
HOME_URL="https://pop.system76.com"
SUPPORT_URL="https://support.system76.com"
BUG_REPORT_URL="https://github.com/pop-os/pop/issues"
PRIVACY_POLICY_URL="https://system76.com/privacy"
VERSION_CODENAME=jammy
UBUNTU_CODENAME=jammy
LOGO=distributor-logo-pop-o
$ ps aux | grep cosmic-ext-applet-clipboard-manager
curious+    9825  0.0  0.0 916820 23300 tty1     SNl+ 14:34   0:00 cosmic-ext-applet-clipboard-manager
$ cat /var/log/syslog | grep 'clipboard'
Jul 22 09:58:40 localhost cosmic-ext-applet-clipboard-manager[4752]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 09:58:40 localhost cosmic-ext-applet-clipboard-manager[4752]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 09:58:40 localhost cosmic-ext-applet-clipboard-manager[4752]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 09:58:40 localhost cosmic-ext-applet-clipboard-manager[4752]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 13:26:39 localhost cosmic-ext-applet-clipboard-manager[76705]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 13:26:42 localhost cosmic-ext-applet-clipboard-manager[76705]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 13:26:43 localhost cosmic-ext-applet-clipboard-manager[76705]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 13:26:43 localhost cosmic-ext-applet-clipboard-manager[77018]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 13:26:43 localhost cosmic-ext-applet-clipboard-manager[77018]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 13:26:43 localhost cosmic-ext-applet-clipboard-manager[77018]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 13:26:43 localhost cosmic-ext-applet-clipboard-manager[77018]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:19:36 localhost cosmic-ext-applet-clipboard-manager[86429]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 14:19:36 localhost cosmic-ext-applet-clipboard-manager[86429]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 14:19:36 localhost cosmic-ext-applet-clipboard-manager[86429]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:19:36 localhost cosmic-ext-applet-clipboard-manager[86429]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:20:19 localhost cosmic-ext-applet-clipboard-manager[86864]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 14:20:20 localhost cosmic-ext-applet-clipboard-manager[86864]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 14:20:20 localhost cosmic-ext-applet-clipboard-manager[86864]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:20:20 localhost cosmic-ext-applet-clipboard-manager[86864]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:21:51 localhost cosmic-ext-applet-clipboard-manager[88076]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 14:21:51 localhost cosmic-ext-applet-clipboard-manager[88076]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 14:21:51 localhost cosmic-ext-applet-clipboard-manager[88076]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 14:21:51 localhost cosmic-ext-applet-clipboard-manager[88076]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 15:47:05 localhost cosmic-ext-applet-clipboard-manager[101228]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 15:47:39 localhost cosmic-ext-applet-clipboard-manager[101228]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 15:47:39 localhost cosmic-ext-applet-clipboard-manager[101228]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 15:47:39 localhost cosmic-ext-applet-clipboard-manager[101228]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 15:47:40 localhost cosmic-ext-applet-clipboard-manager[101611]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 15:47:41 localhost cosmic-ext-applet-clipboard-manager[101611]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 15:47:41 localhost cosmic-ext-applet-clipboard-manager[101611]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 15:47:41 localhost cosmic-ext-applet-clipboard-manager[101611]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 23:57:32 localhost cosmic-ext-applet-clipboard-manager[3421]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 22 23:57:32 localhost cosmic-ext-applet-clipboard-manager[3421]: No `wp_viewporter`. Subsurfaces not supported.
Jul 22 23:57:32 localhost cosmic-ext-applet-clipboard-manager[3421]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 22 23:57:32 localhost cosmic-ext-applet-clipboard-manager[3421]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 10:03:32 localhost cosmic-ext-applet-clipboard-manager[4299]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 23 10:03:32 localhost cosmic-ext-applet-clipboard-manager[4299]: No `wp_viewporter`. Subsurfaces not supported.
Jul 23 10:03:32 localhost cosmic-ext-applet-clipboard-manager[4299]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 10:03:33 localhost cosmic-ext-applet-clipboard-manager[4299]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:16:49 localhost cosmic-ext-applet-clipboard-manager[39067]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 23 12:16:49 localhost cosmic-ext-applet-clipboard-manager[39067]: No `wp_viewporter`. Subsurfaces not supported.
Jul 23 12:16:49 localhost cosmic-ext-applet-clipboard-manager[39067]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:16:49 localhost cosmic-ext-applet-clipboard-manager[39067]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:37:47 localhost cosmic-ext-applet-clipboard-manager[3384]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 23 12:37:47 localhost cosmic-ext-applet-clipboard-manager[3384]: No `wp_viewporter`. Subsurfaces not supported.
Jul 23 12:37:47 localhost cosmic-ext-applet-clipboard-manager[3384]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:37:47 localhost cosmic-ext-applet-clipboard-manager[3384]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:38:11 localhost cosmic-ext-applet-clipboard-manager[5060]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 23 12:38:11 localhost cosmic-ext-applet-clipboard-manager[5060]: No `wp_viewporter`. Subsurfaces not supported.
Jul 23 12:38:11 localhost cosmic-ext-applet-clipboard-manager[5060]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 12:38:11 localhost cosmic-ext-applet-clipboard-manager[5060]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 14:34:41 localhost cosmic-ext-applet-clipboard-manager[9825]: Failed to initialize viewporter: the requested global was not found in the registry
Jul 23 14:34:41 localhost cosmic-ext-applet-clipboard-manager[9825]: inside error: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
Jul 23 14:34:41 localhost cosmic-ext-applet-clipboard-manager[9825]: No `wp_viewporter`. Subsurfaces not supported.
Jul 23 14:34:41 localhost cosmic-ext-applet-clipboard-manager[9825]: A required Wayland protocol (zwlr_data_control_manager_v1 version 1) is not supported by the compositor
$ apt list cosmic-*
Listing... Done
cosmic-app-library/jammy,now 0.1.0~1721054203~22.04~3489c53 amd64 [installed]
cosmic-applets/jammy,now 0.1.0~1721314847~22.04~0c7083e amd64 [installed]
cosmic-bg/jammy,jammy,now 0.1.0~1720050061~22.04~343410f amd64 [installed]
cosmic-comp/jammy 0.1~1721743951~22.04~4f04313 amd64 [upgradable from: 0.1~1721316717~22.04~ec5d89e]
cosmic-design-demo/jammy 0.1.0~1704748391~22.04~d58cfad amd64
cosmic-edit/jammy,now 0.1.0~1721650308~22.04~33d6522 amd64 [installed]
cosmic-ext-orderly/jammy,jammy 0.1.0-0pop1~1719848956~22.04~d76bd39 amd64
cosmic-files/jammy 0.1.0~1721748812~22.04~1820433 amd64 [upgradable from: 0.1.0~1721224248~22.04~ec4d734]
cosmic-greeter-daemon/jammy,now 0.1.0~1721052517~22.04~59e2eaa amd64 [installed]
cosmic-greeter/jammy,now 0.1.0~1721052517~22.04~59e2eaa amd64 [installed]
cosmic-icons/jammy,now 0.1.0~1721234019~22.04~73be037 amd64 [installed]
cosmic-launcher/jammy,now 0.1.0~1721275594~22.04~c188029 amd64 [installed]
cosmic-notifications/jammy,now 0.1.0~1721052308~22.04~2caf2fb amd64 [installed]
cosmic-osd/jammy,now 0.1.0~1721052322~22.04~27fc5e5 amd64 [installed]
cosmic-panel/jammy,now 0.1.0~1721052062~22.04~05420b2 amd64 [installed]
cosmic-randr/jammy,now 0.1.0~1721287742~22.04~e214fe9 amd64 [installed]
cosmic-screenshot/jammy,now 0.1.0~1721052047~22.04~08ac28d amd64 [installed]
cosmic-session/jammy,now 0.1.0~1721052030~22.04~577a181 amd64 [installed]
cosmic-settings-daemon/jammy,now 0.1.0~1721272193~22.04~54700df amd64 [installed]
cosmic-settings/jammy 0.1.0~1721708515~22.04~4908e38 amd64 [upgradable from: 0.1.0~1721311726~22.04~e8106a9]
cosmic-store/jammy 0.1.0~1721663818~22.04~5d73d53 amd64 [upgradable from: 0.1.0~1721657927~22.04~34050c0]
cosmic-tasks/jammy,jammy 0.1.0-0pop1~1719848956~22.04~d76bd39 amd64
cosmic-term/jammy,now 0.1.0~1721650276~22.04~0652001 amd64 [installed]
cosmic-wallpapers/jammy,jammy,jammy,jammy,now 1.0.0~1719415313~22.04~0f2f16d all [installed,automatic]
cosmic-webapps/jammy,jammy,now 0.4.0-0pop1~1715817408~22.04~afb141a amd64 [installed]
cosmic-workspaces/jammy,now 0.1.0~1721334536~22.04~2de3669 amd64 [installed]

Meta issue for new feature/plan

  • change the database to use diese (or not) (with a SQL backend probably) is it suitable for image ?
  • add a global shortcut (ctrl + v), probably need d-bus, but S76 folks should know (actually, need the global shortcut from portal, but its not currently impl in cosmic)
  • add quick settings dropdown when right click the icon
  • add a settings window to remove the clear button and store future settings (winit + applet is not a things atm)
  • add a dropdown menu on right click of entries to remove the "remove" ugly button (it would be nice if we could use the one from iced_aw, but it doesn't work for now)
  • support image, and maybe other mime type #9
  • search should works with accents
  • auto remove old entries

Change icon to symbolic

Bug Description

Expected Result

Steps to Reproduce

Possible Solutions (optional)

Possible Additional Information (optional)

Logs

Search improvment

The current search implemenation have several problem.

Ideally, we would only need an LCS algo to search the database.
With an unicode and case normalization.

Currently, only match when the full block is found, and normalization have bugs:

  • é and e will match but not the next char.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.