Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8479639
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T19:05:19+00:00 2026-06-10T19:05:19+00:00

I earlier tested Symfony’s web app on both local computer and target host in

  • 0

I earlier tested Symfony’s web app on both local computer and target host in both environments: prod and dev – both worked fine. So I finished a mile stone on my local computer, still testing only on dev. Everything works fine. However – Doctrine seems to not working on prod now – and I don’t know why and how it stopped working.

Here’s what I see – this code (from DefaultController.php) is working on both, prod and dev:

    $tags = $this->getDoctrine()
            ->getRepository("MyWebBundle:Tag");

But this (one line more) is working only on dev, but not prod:

    $tags = $this->getDoctrine()
            ->getRepository("MyWebBundle:Tag")
            ->find(1);

In prod the last line causes “die” to the webpage. There’s no doubt that an error occured, but I have no any message in log, and of course in prod env Symfony is silent. I have no idea how to approach this problem… The most weird thing is that prod worked earlier properly.

UPDATED:
Ok, I traced the part of code which makes a difference of working and not working (but in prod, in dev always works). There are some relations in database (Tag Many-to-One to Category). Here is this part of code in Entity/Tag.php:

/**
* @ORM\ManyToOne(targetEntity="Category")
* @ORM\JoinColumn(name="id_category", referencedColumnName="id_category", nullable=true)
*/
protected $category;

It’s interesting that Symfony2 is not verbose about it…
When I delete it from Tag.php, my webapp works. If I re-type it into this file, it doesn’t…

UPDATED:
After further research I can see that actually all relations are problematical (in prod, not in dev). I wrote additional “artificial” (for test purposes) queries to database – in a fashion as above, and all give one of two effects:
When table is on top of hierarchical dependencies, everything works (let’s call it A type)
*When table has relations, Symfony just stop working without any message (let’s call it B type…*

I also tried to make a test with empty table and with fulfilled one. Two cases are following in “B-type” tables:
When empty, it works
*When data are stored (with relations), it doesn’t work*

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T19:05:20+00:00Added an answer on June 10, 2026 at 7:05 pm

    In your app.php change

    $kernel = new AppKernel('prod', false);
    

    to

    $kernel = new AppKernel('prod', true);
    

    This will boot your application with prod environment and with enabled debugging

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have my app running and tested on 10.7 but later realized that I
I've just tested locally my web application, everything works fine, but after uploading to
I have problem with adding web service by add web reference button. I tested
Earlier I made an HttpWebRequest that worked perfectly fine, and my StreamReader read the
Has anyone tried new CUDA 5.0's command line profiler? In earlier version it worked
I have a fairly simple web app built with Delphi (2009) Web Broker. I
Earlier today a question was asked regarding input validation strategies in web apps .
Earlier this week, I had to do something which feels like a semantics violation.
Earlier I encountered a problem with dynamic memory in C (visual studio) . I
Earlier to deploy my dot-net project into my remote server I was using copy

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.