-
-
Notifications
You must be signed in to change notification settings - Fork 266
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
Error during 3.X installation #760
Comments
Hi @wasdammak, can you provide more information about how you installed farmOS? Did you use the official installation guide? Which of the recommended approaches did you use? Docker? Packaged tarball? Composer? https://farmos.org/hosting/install/ It sounds like you are experiencing this issue: https://www.drupal.org/project/entity/issues/3190436 farmOS patches the Entity module to fix that bug, as well as a number of other patches to Drupal core and contrib modules for other purposes. Depending on how you installed farmOS you may be missing these patches. I would recommend reviewing the documentation to confirm that you followed the recommended installation steps. If you can describe your setup in more detail we may be able to help figure out what went wrong. FWIW, I have heard from some in the past who use Windows with Composer that the |
@mstenta |
@mstenta |
Do you mean version 10 of Drupal? Can you describe how you are installing farmOS? If you are following the official instructions then you will not need to apply any patches yourself. farmOS comes pre-packaged with all the necessary code and patches. All you need to do is run the Docker container or download the packaged release tarball (or for advanced users who want to manage all their own dependencies with Composer see https://farmos.org/hosting/composer/) - these include everything you need. |
@mstenta PS C:\wamp64\www\farm> composer create-project farmos/project In CreateProjectCommand.php line 424: Could not find package farmos/project with stability stable. create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--no-audit] [--audit-format AUDIT-FORMAT] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--ask] [--] [ [ []]] PS C:\wamp64\www\farm> composer create-project farmos/farmos
Problem 1 Potential causes:
Read https://getcomposer.org/doc/articles/troubleshooting.md for further common problems. |
Yes that's a known issue with the docs. See farmOS/composer-project#10. We have an open pull request for it (#739), but it hasn't been approved so we may just update the docs as a temporary workaround. Can I assume that you're trying to use Composer? I'd love to help but I need answers to some of the questions I asked in order to get anywhere. :-) |
This command should work to install farmOS 3.0.0-beta3 via Composer:
|
@mstenta I installed Drupal with composer. PS C:\wamp64\www> composer create-project farmos/project:3.x-dev ./formwd
Problem 1 To enable extensions, verify that they are enabled in your .ini files: |
Ah yes - this would explain why you got the errors you did. This is not the correct way to install farmOS. farmOS is a "Drupal distribution" which means it comes with Drupal. You don't install it into an existing Drupal codebase like you would a Drupal module (technically it might be possible but it is not recommended, nor do we support that approach, because of the necessary patches, pinned package version, etc). Think of farmOS as a "pre-packaged Drupal-based application".
It looks like you need to install the PHP sodium extension. This has some instructions for Windows: https://www.php.net/manual/en/sodium.installation.php |
@mstenta sodium is installed and enabled, I'm using php 8.2.14 Another remark, why did you not opt for modules/custom to overload the modules and that way updating drupal core would be easier and stable... Well currently I am stuck in all the solutions proposed, none worked neither docker, nor composer+dursh, nor manually |
I'm not sure what problem you had - I have not experienced this. We have an automated test and build process that is working fine: https://github.com/farmOS/farmOS/actions I would bet that it is something specific to your Windows installation. We test against the official Drupal Docker images, which are built on top of the official PHP Docker images. This is a good reason to use Docker - it ensures that all of your dependencies are in place, so you don't need to manage them locally. Docker makes our jobs as maintainers a whole lot easier by providing a predictable and reproducible environment.
Great question! I would be happy to speak in more detail about this decision, but perhaps it would be better suited as a forum topic rather than a GitHub bug report. Feel free to ask this on the forum and I will describe our thought process, the tradeoffs of both approaches, and why we eventually found ourselves where we are with farmOS as a Drupal distribution. :-) https://farmOS.discourse.group
What issue did you run into with Docker? |
@mstenta For the installation documentation, it could be simpler, with 5 or 6 lines of commands without going into details on how to install drupal with composer then tell it that you should not install drupal then farmOS... I have been trying to install FramOS for 2 days without success, I like to notify this so as not to discourage many other users who wish to stay on windows/apache/mysql for several other reasons. I thank you again for the work done even if I was not able to test it. |
Thank you for the suggestions @wasdammak. We've heard from a handful of people that the Composer documentation (which is relatively new) is not as simple and straightforward as it could be. I agree! I wish more people would offer to help. If you would like to, the documentation is open source. That page is in GitHub here: https://github.com/farmOS/farmOS/blob/3.x/docs/hosting/composer.md
We use Composer to build the Docker images and packaged tarballs. So I agree! I also know that it works. Here are the logs of the automated GitHub Action that ran last night, where Composer is used to build the farmOS codebase inside the Docker image: https://github.com/farmOS/farmOS/actions/runs/7336448735/job/19975778597#step:7:727 If you are having specific issues with installing farmOS via Composer in your environment, please provide more details so we can help to figure out what your specific problem is.
Thanks! There are some forum topics from other Windows users who have figured out how to run farmOS. You might find some of them useful. Try searching here: https://farmOS.discourse.group Since farmOS is based on Drupal, it should work fine on Windows/Apache/MySQL, as long as you have the dependencies you need. Based on the limited information you provided, it sounds like a dependency issue, but it's hard to say for sure.
If you would like to test farmOS before figuring out how to host it yourself, there is a button to "Demo farmOS" in the top-right of farmOS.org. This might be worth doing first to see if farmOS will be useful to you or not, before you invest time in learning how to host it.
As a maintainer of this open source project, I wish I could understand better where expectations like this come from. farmOS is not maintained by a company or any single organization. We are individuals who volunteer our time on the project, or are sponsored by other groups/organizations to work on specific features. Progress does not happen magically. If you find it to be useful and would like to contribute, we would love to have you as part of the community! All help is welcome! And there is always more to do than we have time/resources for. That said, we have a solution to the problem of "working on various environments": Docker images! I know people who are running farmOS in Docker on Windows, Mac, and Linux. Docker images solve all the problems of dependency management in a simple and elegant way that removes all of these problems from maintainers. I understand that Docker isn't always an option, though, which is why we also provide a packaged tarball (which we build with Composer for you), or manual Composer-based installation methods for users who want more control. With more control comes more responsibility, though. It's up to you to resolve dependency issues. I hope that all makes sense. I don't mean to come off as dismissive, and I apologize if any of my comments did. It's holiday vacation here so I'm with family, but hopefully I've been able to help get through some of the hurdles you've experienced. |
@wasdammak you could also try using DDEV: https://farmos.org/blog/2023/installing-farmos-on-ddev-with-composer/ It is still a Docker and Composer based workflow, but with various helpers that have helped others who had various depdency/environment issues on Windows in particular. |
Just to inform you, after many attempts and research, currently it is impossible to install farmOS with composer on windows. :'( a list of requires that the majority are compatible with php 8 but there are conflicts with some current farmOS requires
|
Thanks for sticking with it @wasdammak! Let's figure out what's going wrong... if there is a bug with Windows installs specifically we should fix it. Can you paste your full
Unfortunately I don't think that is the problem. farmOS 2.x added support for PHP 8 in October/November when PHP 7.4 was end of life. The farmOS 3.x Docker images are built on PHP 8.2 and all tests are passing, which includes installing farmOS via Composer. So something else must be going on... your full terminal logs will help. |
PS C:\wamp64\www\farmwd> composer install --ignore-platform-req=ext-sodium Problem 1 |
@wasdammak Try this: delete your Run This will download the Please tell us what happens, including the full terminal log. |
And please install Using |
PS C:\wamp64\www> composer create-project farmos/project:3.x-dev .\farmoswd
Problem 1 To enable extensions, verify that they are enabled in your .ini files: |
@wasdammak What if you try the steps in the second part of this answer? https://stackoverflow.com/a/62348348
|
@mstenta |
In PluginManager.php(277) : eval()'d code line 331: Cannot apply patch Issue #2429699: Add Views EntityReference filter to be available for all entity reference fields create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--no-audit] [--audit-format AUDIT-FORMAT] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--ask] [--] [ [ []]] like issue farmOS/composer-project#11 |
PS C:\wamp64\www\farmwd> composer update
In Patches.php line 331: Cannot apply patch Issue #2429699: Add Views EntityReference filter to be available for all entity reference fields update [--with WITH] [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--dry-run] [--dev] [--no-dev] [--lock] [--no-install] [--no-audit] [--audit-format AUDIT-FORMAT] [--no-autoloader] [--no-suggest] [--no-progress] [-w|--with-dependencies] [-W|--with-all-dependencies] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [-i|--interactive] [--root-reqs] [--] [...] PS C:\wamp64\www\farmwd> |
I bet you don't have the This has happened to others on Windows in the past, and they've figured out how to install Also: do not run |
I am not familiar with Windows (or the various ways to run Linux commands on it), but there appear to be numerous closed issues in the cweagans/composer-patches issue queue that show people figuring out how to do it in various ways, depending on your setup: https://github.com/cweagans/composer-patches/issues?q=is%3Aissue+windows+is%3Aclosed |
Hopefully you were able to figure out your issues @wasdammak. I'm going to close this because it hasn't been determined that there is a bug. If you need more support please start a topic on the forum, and if we identify that there is a bug we will open a bug report with specific details and a plan to fix the bug specifically. |
[27-Dec-2023 12:34:03 UTC] Drupal\Core\Entity\Sql\SqlContentEntityStorageException: Column information not available for the 'location' field. in C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Entity\Sql\DefaultTableMapping.php on line 440 #0 C:\wamp64\www\farmos\web\modules\contrib\entity\src\EntityViewsData.php(389): Drupal\Core\Entity\Sql\DefaultTableMapping->getFieldColumnName(Object(Drupal\Core\Field\BaseFieldDefinition), 'target_id')
#1 C:\wamp64\www\farmos\web\modules\core\entity\modules\views\src\EntityViewsDataTaxonomyFilterTrait.php(17): Drupal\entity\EntityViewsData->addReverseRelationships(Array, Array)
#2 C:\wamp64\www\farmos\web\modules\contrib\entity\src\EntityViewsData.php(59): Drupal\farm_entity_views\FarmEntityViewsData->addReverseRelationships(Array, Array)
#3 C:\wamp64\www\farmos\web\core\modules\views\views.views.inc(180): Drupal\entity\EntityViewsData->getViewsData()
#4 C:\wamp64\www\farmos\web\core\modules\views\src\ViewsData.php(228): views_views_data()
#5 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Extension\ModuleHandler.php(388): Drupal\views\ViewsData->Drupal\views{closure}(Object(Closure), 'views')
#6 C:\wamp64\www\farmos\web\core\modules\views\src\ViewsData.php(227): Drupal\Core\Extension\ModuleHandler->invokeAllWith('views_data', Object(Closure))
#7 C:\wamp64\www\farmos\web\core\modules\views\src\ViewsData.php(151): Drupal\views\ViewsData->getData()
#8 C:\wamp64\www\farmos\web\core\modules\views\src\Entity\View.php(455): Drupal\views\ViewsData->get('asset_field_dat...')
#9 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Config\ConfigInstaller.php(388): Drupal\views\Entity\View->isInstallable()
#10 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Config\ConfigInstaller.php(260): Drupal\Core\Config\ConfigInstaller->createConfiguration('', Array)
#11 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Config\ConfigInstaller.php(164): Drupal\Core\Config\ConfigInstaller->installOptionalConfig(Object(Drupal\Core\Config\FileStorage), '')
#12 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\ProxyClass\Config\ConfigInstaller.php(75): Drupal\Core\Config\ConfigInstaller->installDefaultConfig('module', 'farm_entity_vie...')
#13 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\Extension\ModuleInstaller.php(334): Drupal\Core\ProxyClass\Config\ConfigInstaller->installDefaultConfig('module', 'farm_entity_vie...')
#14 C:\wamp64\www\farmos\web\core\lib\Drupal\Core\ProxyClass\Extension\ModuleInstaller.php(83): Drupal\Core\Extension\ModuleInstaller->install(Array, true)
#15 C:\wamp64\www\farmos\web\farm.install(145): Drupal\Core\ProxyClass\Extension\ModuleInstaller->install(Array, true)
#16 C:\wamp64\www\farmos\web\core\includes\batch.inc(296): _farm_install_module_batch('farm_ui', 'farmOS UI', Array)
#17 C:\wamp64\www\farmos\web\core\includes\batch.inc(138): _batch_process()
#18 C:\wamp64\www\farmos\web\core\includes\batch.inc(94): _batch_do()
#19 C:\wamp64\www\farmos\web\core\includes\install.core.inc(673): _batch_page(Object(Symfony\Component\HttpFoundation\Request))
#20 C:\wamp64\www\farmos\web\core\includes\install.core.inc(578): install_run_task(Array, Array)
#21 C:\wamp64\www\farmos\web\core\includes\install.core.inc(121): install_run_tasks(Array, NULL)
#22 C:\wamp64\www\farmos\web\core\install.php(48): install_drupal(Object(Composer\Autoload\ClassLoader))
#23 {main}
The text was updated successfully, but these errors were encountered: