<commit_before>- content_for :extracss do
  = stylesheet_link_tag "users/registrations"
- content_for(:extrajs) do
  = javascript_include_tag "users/registrations"
- content_for( :content ) do
  .flexrow
    - if @observations && @observations.size > 0
      :ruby
        obs = @observations[rand(@observations.size)]
        photo = obs.observation_photos.sort_by{ |op| op.position || op.id }.first.photo
        place_guess = obs.public_places.select{|p| [Place::COUNTRY_LEVEL, Place::STATE_LEVEL].include?(p.admin_level)}.sort_by(&:admin_level).map{|p|
          t(
            p.name.parameterize.underscore,
            default: t(
              "places_name.#{p.name.parameterize.underscore}",
              default: p.name
            )
          )
        }.reverse.join( ", " )
        place_guess = obs.place_guess if place_guess.blank?
      #imgcol.hidden-xs.hidden-sm{ style: "background-image: url('#{photo.large_url}');" }
        .about-observation
          = link_to_user obs.user, style: "background-image: url('#{obs.user.icon.url(:medium)}');", class: "usericon" do
            &nbsp;
          .details
            %div
              =t :taxon_observed_by_html, taxon: render( partial: "shared/taxon", locals: { taxon: obs.taxon, one_name: true } ), url: url_for( obs )
            = link_to_user obs.user, class: "username" do
              = obs.user.published_name
            %div
              = link_to t( :in_place_x, place: place_guess ), observations_url( lat: obs.latitude, lng: obs.longitude )
    - else
      = yield :left
    #formcol
      .inner
        = yield
= render template: "layouts/bootstrap"<commit_msg>Handle case where sign in obs has no taxon<commit_after>- content_for :extracss do
  = stylesheet_link_tag "users/registrations"
- content_for(:extrajs) do
  = javascript_include_tag "users/registrations"
- content_for( :content ) do
  .flexrow
    - if @observations && @observations.size > 0
      :ruby
        obs = @observations[rand(@observations.size)]
        photo = obs.observation_photos.sort_by{ |op| op.position || op.id }.first.photo
        place_guess = obs.public_places.select{|p| [Place::COUNTRY_LEVEL, Place::STATE_LEVEL].include?(p.admin_level)}.sort_by(&:admin_level).map{|p|
          t(
            p.name.parameterize.underscore,
            default: t(
              "places_name.#{p.name.parameterize.underscore}",
              default: p.name
            )
          )
        }.reverse.join( ", " )
        place_guess = obs.place_guess if place_guess.blank?
        taxon_name = if obs.taxon
          render( partial: "shared/taxon", locals: { taxon: obs.taxon, one_name: true } )
        else
          t(:unknown)
        end
      #imgcol.hidden-xs.hidden-sm{ style: "background-image: url('#{photo.large_url}');" }
        .about-observation
          = link_to_user obs.user, style: "background-image: url('#{obs.user.icon.url(:medium)}');", class: "usericon" do
            &nbsp;
          .details
            %div
              =t :taxon_observed_by_html, taxon: taxon_name, url: url_for( obs )
            = link_to_user obs.user, class: "username" do
              = obs.user.published_name
            %div
              = link_to t( :in_place_x, place: place_guess ), observations_url( lat: obs.latitude, lng: obs.longitude )
    - else
      = yield :left
    #formcol
      .inner
        = yield
= render template: "layouts/bootstrap"
{'fraction_non_alphanumeric': 0.13078939702883774, 'fraction_numerical': 0.0005825808330905913, 'mean_word_length': 2.360078277886497, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7379094', 'n_tokens_mistral': 1127, 'n_tokens_neox': 1100, 'n_words': 212}