Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Preferences plugin not implemented error on Android #128

Closed

Conversation

deep-foundation-sweepai[bot]
Copy link

Description

This PR addresses the issue of the "Preferences" plugin not being implemented on Android in the deep-memo-app project. The error occurs when running the Android app and is caused by missing or incorrect configuration of the Preferences plugin. This PR includes the necessary changes to properly configure and use the Preferences plugin on Android.

Summary of Changes

  • Modified the package.json file to ensure that the "@capacitor/preferences" plugin is listed as a dependency.
  • Modified the android/capacitor.settings.gradle file to include the Preferences plugin in the project.
  • Modified the components/page.tsx file to import and use the Preferences plugin correctly.
  • Modified the android/app/src/main/java/com/deepfoundation/deep/MainActivity.java file to initialize the Preferences plugin for Android.

These changes ensure that the Preferences plugin is properly installed, configured, and used in the deep-memo-app project, resolving the "Preferences plugin is not implemented on android" error.

Fixes #127.


🎉 Latest improvements to Sweep:


💡 To get Sweep to edit this pull request, you can:

  • Leave a comment below to get Sweep to edit the entire PR
  • Leave a comment in the code will only modify the file
  • Edit the original issue to get Sweep to recreate the PR from scratch

@deep-foundation-sweepai
Copy link
Author

GitHub actions yielded the following error.

The command that failed is npm run build. Here are the relevant lines from the logs:

- warn Invalid next.config.js options detected:
- warn     The root value has an unexpected property, strictMode, which is not in the list of allowed properties (amp, analyticsId, assetPrefix, basePath, cleanDistDir, compiler, compress, configOrigin, crossOrigin, devIndicators, distDir, env, eslint, excludeDefaultMomentLocales, experimental, exportPathMap, generateBuildId, generateEtags, headers, httpAgentOptions, i18n, images, modularizeImports, onDemandEntries, optimizeFonts, output, outputFileTracing, pageExtensions, poweredByHeader, productionBrowserSourceMaps, publicRuntimeConfig, reactStrictMode, redirects, rewrites, sassOptions, serverRuntimeConfig, skipMiddlewareUrlNormalize, skipTrailingSlashRedirect, staticPageGenerationTimeout, swcMinify, target, trailingSlash, transpilePackages, typescript, useFileSystemPublicRoutes, webpack).
- warn See more info here: https://nextjs.org/docs/messages/invalid-next-config
- warn No build cache found. Please configure build caching for faster rebuilds. Read more: https://nextjs.org/docs/messages/no-cache

...

> Build optimization failed: found page without a React Component as default export in
pages/test

See https://nextjs.org/docs/messages/page-without-valid-component for more info.

##[error]Process completed with exit code 1.

This is likely a linting or type-checking issue with the source code. Update the code changed by the PR. Don't modify the existing tests.

I'm getting the same errors 3 times in a row, so I will stop working on fixing this PR.

@Konard Konard closed this May 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error: "Preferences" plugin is not implemented on android
1 participant